Posted on 2015/12/03 17:00
Filed Under 리눅스기술문서/팁앤테크 조회수: view 11569

  1. uptime
16:10:22 up 2 days, 32 min, 7 users, load average: 16.14, 16.07, 16.18

서버 부팅 후 운영 시간과 시스템의 Load average 파악

  1. dmesg | tail

nfsd: last server has exited, flushing export cache NFSD: Using /var/lib/nfs/v4recovery as the NFSv4 state recovery directory NFSD: starting 90-second grace period jobUpdater50988: segfault at 0 ip 0000000000452672 sp 00007fff2ecf4208 error 4 in jobUpdater[400000+10a000] wait_sessionid74297 trap stack segment ip:401a68 sp:7fffec26d950 error:0 setAliasJob2282: segfault at 0 ip (null) sp 00007fff55d47238 error 14 in setAliasJob[400000+10d000] setXHost2283: segfault at 0 ip (null) sp 00007fff8c275808 error 14 in setXHost[400000+10d000] wait_sessionid40210 trap stack segment ip:401a68 sp:7fffc882d790 error:0

동작하는 실행 파일의 비정상 종료 현상 및 기타 시스템 장치나 커널의 이상 증후를 감지할 수 있음.

  1. vmstat 1
procs ———–memory———- —swap– —–io—- –system– —–cpu—–
r b swpd free buff cache si so bi bo in cs us sy id wa st 16 0 15604 704392 525820 120808952 0 0 1 158 3 2 13 0 86 0 0 16 0 15604 703012 525836 120808976 0 0 0 312 17839 1237 40 0 60 0 0 34 0 15552 698096 525960 120808912 32 0 32 516 21874 2054 40 8 52 0 0 34 0 15540 697104 525980 120809424 32 0 32 328 38836 1169 40 45 15 0 0 34 0 15540 696940 526004 120809456 0 0 0 396 38132 1150 40 45 15 0 0

시스템의 주요 프로세스 현황, 메모리사용량, Swap, io, cpu 등의 사용량을 파악할 수 있음.

  1. mpstat -P ALL 1
Linux 2.6.32-431.el6.x86_64 (RNTSMP01) 2015년 12월 03일 _x86_64_ (40 CPU)

�a CPU %usr %nice %sys %iowait %irq %soft %steal %guest %idle all 40.05 0.00 0.10 0.00 0.00 0.00 0.00 0.00 59.85 0 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 1 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 2 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 3 2.00 0.00 3.00 0.00 0.00 0.00 0.00 0.00 95.00 4 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 5 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 6 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 7 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 8 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 9 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 10 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 11 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 12 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 13 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 14 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 15 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 16 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 17 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 18 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 19 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 20 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 21 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 22 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 23 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 24 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 25 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 26 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 27 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 28 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 29 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 30 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 31 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 32 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 33 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 34 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 35 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 36 100.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 37 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 38 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00 39 0.00 0.00 0.00 0.00 0.00 0.00 0.00 0.00 100.00

CPU core 별 이용률 현황을 파악할 수 있음.

  1. pidstat 1

현재 실행 중인 프로세스 별 시스템 이용률을 모니터링

  1. iostat -xz 1

하드디스크별 IO 이용률 모니터링

  1. sar -n DEV 1
NIC 장치별 네트워크 패킷 처리 상태 모니터링

  1. sar -n TCP,ETCP 1
TCP 연결 세션 수 모니터링

Writer profile
author image
-아랑 -
2015/12/03 17:00 2015/12/03 17:00

트랙백 주소 : 이 글에는 트랙백을 보낼 수 없습니다

About

by 서진우
Twitter :@muchunalang

Counter

• Total
: 4125856
• Today
: 125
• Yesterday
: 1375