|
Ãâó:
target=_blank>http://blog.daum.net/_blog/BlogView.do?blogid=09qfM&articleno=1299903
¹®) top¿¡¼ memory valueÀÇ ÀÇ¹Ì ¼³¸í
Top¿¡¼ memory informationÀ» pstat()¸¦ ÀÌ¿ëÇؼ °ªÀ» º¸¿©ÁÖ°Ô µË´Ï´Ù.
´Ü, ÁÖÀÇÇÏ¼Å¾ß ÇÒ Á¡Àº topÀº °í°´ÀÇ system¿¡¼ »ç¿ë°¡´ÉÇÑ °ªÀ» º¸¿©ÁÖ´Â °ÍÀÌ ¾Æ´Ï¶ó´Â °ÍÀÔ´Ï´Ù.
¿ÀÈ÷·Á »ç¿ëµÇ°í ÀÖ´Â °ªÀ» º¸¿©ÁÝ´Ï´Ù.
¿©±â¼ ¾Æ·¡¿¡¼ º¸¿©ÁÖ´Â ÀÏ·Ê´Â 2080K°¡ ½ÇÁ¦·Î total physical memoryÀÇ ¾çÀÌ ¾Æ´Ï¶ó ½ÇÁ¦·Î process memory
structure¿¡¼ »ç¿ëµÇ°í ÀÖ´Â ¾çÀ» ÀǹÌÇÕ´Ï´Ù.
top¿¡¼ outputÀ» º¸°í ¼³¸íÀ» ÇÏ°Ô µÈ´Ù¸é ..
| Memory: 2080K (1672K) real, 5564K (3044K) virtual, 696K free
| ^ ^ ^ ^ ^
| | | | | |
| 1 2 3 4 5
1. system¿¡ ÀÖ´Â ¸ðµç process¿¡ ÇÒ´çµÈ text,data ¶Ç´Â stack segmentÀÇ total physcial memory°ªÀ» ÀǹÌÇÕ´Ï´Ù.
2. sleeping process¸¦ Á¦¿ÜÇÑ runnable processes¿¡ ´ëÇÑ total physical memory°ªÀ» ÀÇ¹Ì ÇÕ´Ï´Ù.
3. system¿¡¼ text,data ¶Ç´Â stack segments¿¡ ÇÒ´çµÈ ÃÑ memory°ªÀ» ÀǹÌÇÕ´Ï´Ù.
¿©±â¼ disk·Î paged outµÈ processµµ Æ÷ÇÔÀ» ÇÏ°Ô µË´Ï´Ù. ( ´Ù½Ã¸»Çϸé physical memory¿¡ Á¸ÀçÇÏÁö ¾Ê´Â °ÍÀ» ¸»ÇÕ´Ï´Ù.)
4. sleepÀ̳ª stoppedµÈ process¸¦ Á¦¿ÜÇÑ runnable processÀÇ total memory
5. »õ·Î¿î process¿¡ »ç¿ëµÇÁö ¾Ê°Å³ª »ç¿ë°¡´ÉÇϵµ·Ï °£ÁֵǴ physical memory¸¦ ÀÇ¹Ì ÇÕ´Ï´Ù.
¿©±â¼ ÀÌ°ªÀÌ ³·´Ù´Â °ÍÀº swappingÀÌ ÀϾ °¡´É¼ºÀÌ ³ô´Ù´Â °ÍÀ» ÀǹÌÇÕ´Ï´Ù.
¹®) Top¿¡¼ load averageÀÇ ÀÇ¹Ì (#uptime command ¼öÇà )
ÃÖÁ¾ 1ºÐ, 5ºÐ, 15ºÐÀÇ CPU time over¸¦ ´ë±âÇÏ´Â executable processesÀÇ ¼ö¸¦ ¶æÇÕ´Ï´Ù.
high average load (6-7) ¿Í low cpu usage (20%)¸¦ º¼ ¼ö ÀÖÀ¸¸ç,
ÀϹÝÀûÀÎ ·®¿¡ »ç¿ëµÉ ¶§´Â fast I/O°¡ ready to run »óÅ·ΠÀÎ½ÄµÇ¾î ¾î¶² ¾÷¹«°¡ ¿¬±âµÇ´Â °æ¿ì¿¡ ¹ß»ýÇÒ ¼ö ÀÖ½À´Ï´Ù.
Fast I/O´Â ¿¹Ãø°¡´ÉÇÏ°í, Á¤È®ÇÑ completion timeÀ» °®°í ÀÖ´Â I/O ÀÔ´Ï´Ù.
¿¹: disc I/O´Â milliseconds¾È¿¡ ³¡³ª¸ç, ±×·¯ÇÑ I/O´Â average load ¿¬»êÀ» À§ÇÑ ready to runÀ¸·Î °£Áֵ˴ϴÙ.
¿¹Á¦ ) sample ÀÔ´Ï´Ù.
top(1) ¸í·ÉÀÇ ¸Þ¸ð¸®(Memory) Á¤º¸ÀÇ °¢ Ç׸ñ¿¡ ´ëÇÑ ¼³¸íÀÔ´Ï´Ù.
ANSWER:
´ÙÀ½Àº top(1)ÀÇ ¸Þ¸ð¸®(Memory) Ç׸ñ¿¡ ´ëÇÑ ¿¹Á¦¼³¸íÀÔ´Ï´Ù.
=====================================================================
Memory: 60496K (29536K) real, 69892K (32096K) virtual, 19272K free
=====================================================================
60496K : ½Ã½ºÅÛÀÇ ¸ðµç ÇÁ·Î¼¼½º¿¡ ´ëÇÑ text(code), data ¶Ç´Â stack segment
¿¡ ÀÇÇØ »ç¿ëµÇ´Â physical memory ÀÇ total size.
(29536K) : runnable processµé¿¡ ´ëÇÑ physical memory ÀÇ total size.
(sleep ÁßÀÎ process Á¦¿Ü)
69892K : ½Ã½ºÅÛÀÇ ¸ðµç ÇÁ·Î¼¼½º¿¡ ´ëÇÑ text(code), data ¶Ç´Â stack segment
¿¡ ÀÇÇØ »ç¿ëµÇ´Â memory(physical+swap)ÀÇ total size.
(physical memory + swap = virtual memory)
(32096K) : runnable processµé¿¡ ´ëÇÑ memory(physical+swap)ÀÇ total size.
(sleep ÁßÀÎ process Á¦¿Ü, physical memory + swap = virtual memory)
19272K : »õ·Î¿î ÇÁ·Î¼¼½ºµé¿¡ ÀÇÇØ »ç¿ë °¡´ÉÇÑ physical memoryÀÇ ³²Àº °ø°£.
(»ç¿ë ¾ÈµÈ °ø°£, free ¿µ¿ª)
À§ÀÇ ¼³¸í¿¡¼ ¾Ë ¼ö ÀÖµíÀÌ, real, virtual, free °¢ Ç׸ñÀº ´ÙÀ½ÀÇ Àǹ̸¦ °¡Áý´Ï´Ù.
real =======> physical memory Á¤º¸
virtual =======> virtual memory (physical + swap) Á¤º¸
free =======> available physical memory
[Ãâó] HP-UX (top ¸í·É¾îÀÇ ÀǹÌ)|ÀÛ¼ºÀÚ Á¤±¼
|