BACKRUSH  À¯´Ð½º¸í·É  ´ÙÀ½  ÀÚ·á½Ç  Ascii Table   ¿ø°ÝÁ¢¼Ó  ´Þ·Â,½Ã°£   ÇÁ·Î¼¼½º   ½©
ÁöÇÏö³ë¼±   RFC¹®¼­   SUN FAQ   SUN FAQ1   C¸Þ´º¾ó   PHP¸Þ´º¾ó   ³Ê±¸¸®   ¾Æ½ºÅ°¿ùµå ¾ÆÀÌÇǼ­Ä¡

±Û¾´ÀÌ: sys ½Ã½ºÅÛ ºÎÇÏ ÃøÁ¤ Á¶È¸¼ö: 7752


1. ¿ë·® È®ÀÎ

1.1 Sun O/S ÀÏ °æ¿ì

# df

1.2 SolarisÀÏ °æ¿ì

# df -k

(Âü°í)¸¸¾à root filesystemÀÌ 90% ÀÌ»óÀÏ °æ¿ì ȨÆäÀÌÁö¿¡ÀÖ´Â find ¸í·É¾î »ç¿ë¹ýÀ» ÂüÁ¶ÇÏ¿©

ºñÁ¤»óÀûÀ¸·Î »ý¼ºµÈ fileÀ» »èÁ¦Ç϶ó. ±×¸®°í root filesystem¿¡ userÀÇ directory°¡ ÀÖ´ÂÁö

»ìÆì º¸¾Æ¶ó. ƯÈ÷ backup ½Ã device ¸íÀ» À߸ø Á־ file·Î ÀúÀåµÇ¾î¼­ ½Ã½ºÅÛÀÌ full µÇ´Â

°æ¿ì°¡ ¸¹À½

(Âü°í) Find ¸í·É¾î »ç¿ë¹ý

1. /usr¿¡ 50,000 charactersº¸´Ù Å« È­ÀÏ Ã£¾Æ¶ó.

# find /usr -type f -size +50000c -print

2. core fileÀ» »èÁ¦Ç϶ó.

# find / -name core -type f -exec rm {} \;

3. /usr/src¿¡¼­ À̸§ÀÌ mem*.cÀΰÍÀ» ã¾Æ¶ó.

# find /usr/src -type f -name "mem*.c" -print

4. owner°¡ rootÀÌ°í set-user-ID¸¦ °¡Áö´Â ¸ðµç È­ÀÏÀ» ã¾Æ¶ó.

# find / -perm -04000 -user root -type f -exec ls -l {} \;

5. ÃÖ±Ù ÀÌƲ³»¿¡ ¾²¿©Áø È­ÀÏÀ» ã¾Æ¶ó.

# find /usr -ctime -2 -print

6. ÃÖ±Ù ÀÌƲ³»¿¡ ¾²¿©Áö°í Å©±â°¡ 10,000byteÀÌ»óÀÎ È­ÀÏÀ̳ª µð·ºÅ丮¸¦ ã¾Æ¶ó.

# find /usr -ctime -2 -size +10000c -exec ls -l {} \;





2. CPU ¿ë·® check

2.1 MP Control and Monitoring

* Processor control and information

* psrinfo - »ç¿ë°¡´ÉÇÑ CPU¸¦ º¸¿©ÁØ´Ù.

# psrinfo

0 on-line since 09/05/97 10:49:27

2 on-line since 09/05/97 10:49:31

* psradm - Enable or disable CPUs

# psradm -f 2 -> 2¹ø CPU¸¦ off-line

# psrinfo

0 on-line since 09/05/97 11:16:04

2 off-line since 09/05/97 11:18:34

# psradm -n -a -> ¸ðµç process¸¦ on-line

2.2 CPU Rules for the SOlaris 2.x Operating Environment

- vmstat 30 or mpstat 30
condition
Conclusion

0 == r
CPU idle

0 < r / ncpus < 3.0
No problem

3.0 <= r / ncpus <= 5
CPU busy

5.0 <= r /ncpus
CPU very busy

smtx < 200
No problem

200 <= smtx < 400
Mutex stall

400 <= smtx
Mutex stall





- psrinfo | grep -c on (CPU ÀÇ °³¼ö)

5. Swap space check

# vmstat 30
Condition
Conclusion

100,000K <= swap
Swap waste

10,000K <= swap < 100,000K
No problem

4,000K <= swap < 10,000K
Swap low

1,000K <= swap < 4,000K
Swap very low

swap < 1,000K
No swap



Action to Take

* Swap Low - ½ÇÇàµÇ´Â ÇÁ·Î±×·¥ ¼ö¸¦ ÁÙÀÌ°í, swap space¸¦ ´Ã·Á¶ó.

* No Swap - ÇÁ·Î±×·¥ÀÌ ¸ØÃâ °ÍÀÌ´Ù. Áï½Ã swap space¸¦ ´Ã·Á¶ó.

(Âü°í)¡¡Swap space ¸¦ ´Ã¸®·Á¸é

1. Sun O/S 4.x ÀÏ°æ¿ì

# mkfile 40m /user/swap¡¡ (40mb size)

# swapon /user/swap

# pstat -T¡¡¡¡¡¡ (swap size È®ÀÎ)

# vi /etc/fstab
/usr/swap¡¡¡¡ swap¡¡¡¡ swap¡¡¡¡ rw 0¡¡ 0

- swap file »èÁ¦

# rm /user/swap

# vi /etc/fstab - addÇÑ entry ¸¦ »èÁ¦ ¡¡

¡¡

2. Solaris 2.x ÀÏ °æ¿ì

# /usr/sbin/mkfile 40m /user/swapfile¡¡

# swap -a /user/swapfile (O/S¿¡ swap fileÀ» Ãß°¡ÇÔ)¡¡

# swap -l¡¡

# vi /etc/vfstab¡¡
/user/swapfile - - swap - no - ( À̶óÀÎÀ» Ãß°¡)

# swap -s
total : 5828kbytes allocated + 2456k reserved = 8284k used, 103792k available
( allocated : ÇöÀç »ç¿ë, reserved : kernelÀÌ Àâ¾Æ³õÀ½ , available : »ç¿ëÇÒ¼ö Àִ¾ç)

# swap -d /user/swapfile (swap addÇÑ fileÀ» »èÁ¦)
¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡¡ .¡¡


6. Memory ¿ë·® check

# vmstat 30
Condition
Conclusion

sr == 0
RAM waste

0 < sr < 200
No problem

200 <= sr < 300
Low RAM

300 <= sr
Very low RAM





* Low RAM - ¸Þ¸ð¸®¸¦ Áõ¼³ÇؾßÇÑ´Ù.

7. Disk ºÎÇÏ check

# iostat -x 30

* svc_t (avque + avwait) : disk ÀÀ´ä½Ã°£

* 10 - 50 acceptable

* 100 - 1500 not acceptable

* %b : µð½ºÅ©¸¦ ¾ó¸¶³ª ¸¹ÀÌ ¾²´Â°¡?

* 5% ÀÌÇÏ´Â ¹«½Ã

* 60% ÀÌ»óÀ̸é Á¶Á¤ÇÒ ÇÊ¿ä°¡ÀÖ´Ù.

8. Network ºÎÇÏ Check

# netstat -i 30
Condition
Conclusion

(0<output packets<10)&&(100*output colls/(output packets)<0.5%)&&(other nets OK)
Inactive network

(0<output packets<10)&&(100*output.colls/(output packets)<1.5%)&&(other nets busy)
Unbalanced

(10<=output packets)&&(0.5%<=100*output colls/output packets <2.0%)
No problem

(10 <= output packets)&&(2.0%<=100*output colls/output packets<5.0%)
Busy network

(10<=output packets)&&(5.0%<=100*output colls/output packets)
Very Busy Net

network type is not ie,le,ne or qe;it is bf or nf
Not Ethernet





* Busy Network - ³×Æ®¿÷¿¡ ³Ê¹«³ª ¸¹Àº Ãæµ¹ÀÌ »ý°Ü¼­ »ç¿ëÀÚµéÀÌ ÀÀ´äÀ» ±â´Ù¸®´Â ´Ã¾î³ª °í throughputÀÌ °¨¼ÒÇÑ´Ù. ¸¸¾à ´Ù¸¥ ³×Æ®¿÷ÀÌ ÀÖ´Ù¸é ºÎÇϸ¦ ÁÖ´Â °ÍÀ» ºÎÇÏ°¡¾ø´Â ³×Æ®¿÷ À¸·Î ¿Å°Ü¶ó. ¶Ç´Â ATM À̳ª 100-MB Ethernet, FDDI°°Àº ºü¸¥ ³×Æ®¿÷À¸·Î upgradeÇ϶ó.

9. System error messages check

# vi /var/adm/messages

# cd /var/adm

# grep panic *

# grep error *

# grep warning *

10. system Á¤º¸ Ãâ·Â

# /usr/platform/'uname -i'/sbin/prtdiag (this show usefull hardware information and failures of system)

# /etc/prtvtoc (show the detail information of disk slice ex) prtvtoc /dev/dsk/c0t0d0s2)

# /usr/sbin/eeprom (user can set some of variables of NVRAM via this command ex) eeprom boot-device=disk3)

# /usr/sbin/prtconf -vp ( Shows device configuration )

# devinfo -vp (Shows device configuration for Solaris 1.x)

# /usr/sbin/sysdef ( Shows software configuration )

# /usr/bin/dmesg | more ( collect system diagnostic messages to form error log

# /usr/proc/bin/ptree (Process trees that contain the process)

# /usr/proc/bin/pwdx pid ( Current working directory for a process)

# /usr/proc/bin/pldd pid ( Dynamic libraries linked into a process)

# /usr/proc/bin/pmap pid ( Address space map)


11. Performance gathering script

date >> /sunsolv/hangdata/vmstat.out
vmstat 30 10 >> /sunsolv/hangdata/vmstat.out
date >> /sunsolv/hangdata/iostat.out
iostat -xtc 30 10 >> /sunsolv/hangdata/iostat.out
date >> /sunsolv/hangdata/ps.out
/usr/ucb/ps -aux >> /sunsolv/hangdata/ps.out
date >> /sunsolv/hangdata/kmstat.out
echo kmastat | crash >> /sunsolv/hangdata/kmstat.out
date >> /sunsolv/hangdata/kernelmap.out
echo "map kernelmap" | crash >> /sunsolv/hangdata/kernelmap.out

À§ ¸í·É¾î¸¦ ¸Å 15ºÐ ¸¶´Ù ½ÇÇà Çϵµ·Ï crontab¿¡ µî·ÏÇسõ´Â´Ù.



°ü·Ã±Û : ¾øÀ½ ±Û¾´½Ã°£ : 2002/04/25 16:55 from 210.121.188.5

  Çϵåµð½ºÅ© º¹¿ø ¹æ¹ý ¸ñ·Ïº¸±â »õ±Û ¾²±â Áö¿ì±â ÀÀ´ä±Û ¾²±â ±Û ¼öÁ¤ quanta_spam-killer_REGEX.m4  
BACKRUSH  À¯´Ð½º¸í·É  ´ÙÀ½  ÀÚ·á½Ç  Ascii Table   ¿ø°ÝÁ¢¼Ó  ´Þ·Â,½Ã°£   ÇÁ·Î¼¼½º   ½©
ÁöÇÏö³ë¼±   RFC¹®¼­   SUN FAQ   SUN FAQ1   C¸Þ´º¾ó   PHP¸Þ´º¾ó   ³Ê±¸¸®   ¾Æ½ºÅ°¿ùµå ¾ÆÀÌÇǼ­Ä¡