sun's longitude:08 24 43 
¡¤ ÀÚÀ¯°Ô½ÃÆÇ ¡¤ ¹¯°í´äÇϱ⠡¤ ¾ËÆĹ®¼­ ¡¤ RPMS list
¡¤ »ç¿ëÀÚ¹®¼­ ¡¤ ÆÁ/FAQ¸ðÀ½ ¡¤ ¸®´ª½ºLinks ¡¤ ÀÚ·á½Ç
¡¤ ¼­¹öÁ¤º¸ ¡¤ ¿î¿µÀÚ ¡¤ Books/FAQ ¡¤ FreeBSD
 
/board/read.php:¼Ò½ºº¸±â   
 
FreeBSD
FreeBSD study ....
[*** ¾²±â ±ÝÁö´Ü¾î ÆÐÅÏ ***]
±Û º»¹® Áß°£¿¡ ¾÷·ÎµåÇÒ À̹ÌÁö¸¦ Ãß°¡ÇÏ´Â ¹æ¹ý : @@À̹ÌÁöÀ̸§@@
ex) @@foo.gif@@
26 ¹ø ±Û: [shell]¸Þ¸ð¸® »ç¿ë·® °è»ê
±Û¾´ÀÌ: »êÀÌ [ȨÆäÀÌÁö] ±Û¾´³¯: 2004³â 11¿ù 11ÀÏ 19:55:39 ¸ñ(Àú³á) Á¶È¸: 5316
-------------------------------
#!/bin/sh
#
# -- san2(at)linuxchannel.net
# -- 2004.11.11
# -- FreeBSD memory information(in vmstat)

count2size()
{
  ACTIVE=$1; WIRE=$2; INACTIVE=$3
  CACHE=$4; FREE=$5; TOTAL=$6

  TOTAL=`perl -e "printf('%.2f',$TOTAL/$UNIT)"`
  _FREE=`perl -e "printf('%.2f',($INACTIVE+$CACHE+$FREE)/$UNIT)"`
  _USED=`perl -e "printf('%.2f',$TOTAL-$_FREE)"`
  _ETC=`perl -e "printf('%.2f',$_USED-($ACTIVE+$WIRE)/$UNIT)"`

  ACTIVE=`perl -e "printf('%.2f',$ACTIVE/$UNIT)"`
  WIRE=`perl -e "printf('%.2f',$WIRE/$UNIT)"`
  INACTIVE=`perl -e "printf('%.2f',$INACTIVE/$UNIT)"`
  CACHE=`perl -e "printf('%.2f',$CACHE/$UNIT)"`
  FREE=`perl -e "printf('%.2f',$FREE/$UNIT)"`
}

PAGE=4096
UNIT=`perl -e "printf('%.2f',1048576/$PAGE)"`

ARGS=`sysctl -n vm.stats.vm.v_active_count vm.stats.vm.v_wire_count \
  vm.stats.vm.v_inactive_count vm.stats.vm.v_cache_count \
  vm.stats.vm.v_free_count vm.stats.vm.v_page_count`

count2size $ARGS

cat <<__END__
memory information(in vmstat)
_USED: $_USED MB = ACTIVE($ACTIVE MB) + WIRE($WIRE MB) + ETC($_ETC MB)
_FREE: $_FREE MB = INACTIVE($INACTIVE MB) + CACHE($CACHE MB) + FREE($FREE MB)
TOTAL: $TOTAL MB = _USED($_USED MB) + _FREE($_FREE MB)
__END__

exit 0
---------------------------------------

 
ÀÌÀü±Û : porters handbook
´ÙÀ½±Û : ½Ç½Ã°£ ½Ã½ºÅÛ »óÅÂ(command)  
 from 211.44.63.181
JS(Redhands)Board 0.4 +@

|±Û¾²±â| |´äÀå¾²±â| |¼öÁ¤| |»èÁ¦|
|ÀÌÀü±Û| |´ÙÀ½±Û| |¸ñ·Ïº¸±â|
Àμâ¿ë 

apache lighttpd linuxchannel.net 
Copyright 1997-2024. linuxchannel.net. All rights reserved.

Page loading: 0.05(server) + (network) + (browser) seconds