· KLDP.org · KLDP.net · KLDP Wiki · KLDP BBS ·
proc ³ª snmp ÀÇ °ªÀ» ÀÌ¿ëÇÏ¿©, cpu counter ¸¦ ±¸ÇÏ´Â °ø½Ä



1. Count ¹æ½ÄÀ¸·Î CPU¸¦ ÃøÁ¤ÇØ¾ß ÇÏ´Â ÀÌÀ¯

  • LinuxÀÇ °æ¿ì snmp¿¡¼­ º¸¿©ÁÖ´Â CPU »ç¿ë·®Àº ºÎÆÃ½Ã ºÎÅÍÀÇ Æò±Õ°ªÀ̹ǷΠ¼º´É ÃøÁ¤½Ã °í·Á´ë»óÀÌ ¾ÈµÊ.
  • º¸Åë Linux ÀÇ °æ¿ì cronjob ¿¡ ÀÇÇÑ °á°ú¹°À» ÀÌ¿ëÇÏ¿© guage ·Î cpu usage ¸¦ ±×¸®´Â °æ¿ì°¡ ¸¹À½
  • guage °ªÀº rrd database ¸¦ update ÇÒ ´ç½ÃÀÇ °ªÀ̹ǷÎ, ÀÌÀü°ªÀ» ¾÷µ¥ÀÌÆ® ÇÏ´Â ¼ø°£ ºÎÅÍ ÇöÀç°ªÀ» ¾÷µ¥ÀÌÆ® ÇÏ´Â ½Ã°£»çÀÌÀÇ »ç¿ë·üÀº ÀüÇô ¹Ý¿µµÇÁö ¸øÇÔ.

2. ÇØ°á¹æ¹ý

  • UCD-SNMP-MIB (.1.3.6.1.4.1.2021) ÀÇ CPU °ü·Ã Counter ¸¦ ÀÌ¿ëÇÏ¿© °ªÀ» ±¸ÇÔ
    • user => UCD-SNMP-MIB::ssCpuRawUser.0
    • nice => UCD-SNMP-MIB::ssCpuRawNice.0
    • sys => UCD-SNMP-MIB::ssCpuRawSystem.0
    • idle => UCD-SNMP-MIB::ssCpuRawIdle.0
    • wait => UCD-SNMP-MIB::ssCpuRawWait.0
    • intr => UCD-SNMP-MIB::ssCpuRawInterrupt.0
    • irqt => UCD-SNMP-MIB::ssCpuRawSoftIRQ.0

  • counter ¹æ½ÄÀ̱⠶§¹®¿¡ °¢ °ªÀÇ 2 ÁöÁ¡(½Ã°£»ó) ÀÇ Â÷À̸¦ ±¸Çϵµ·Ï ÇÑ´Ù.
    • ¿¹) user = userpost - userpref

  • scale = 100.0 / (user + nice + sys + idle + wait + intr + irqt)
  • user = (user + nice) * scale
  • sys = (sys + intr + irqt) * scale
  • idle *= scale
  • idwait *= scale

3. Âü°í

  • linux kernel 2.4 ¿¡¼­´Â ¶Ç´Â (´Ù¸¥ OS ¿¡¼­´Â) IOWAIT/Interrupt/SoftIRQ ¿¡ ´ëÇÑ Counter °¡ ¾øÀ» ¼öµµ ÀÖÀ¸¹Ç·Î ¿¹¿Ü 󸮸¦ ¿°µÎ¿¡ µÎ¾î¾ß ÇÑ´Ù.


ID
Password
Join
Promptness is its own reward, if one lives by the clock instead of the sword.


sponsored by andamiro
sponsored by cdnetworks
sponsored by HP

Valid XHTML 1.0! Valid CSS! powered by MoniWiki
last modified 2011-06-01 13:08:01
Processing time 0.0068 sec