Ò׽ؽØͼÈí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

linux dfisk, du,df(´ÅÅÌ¿Õ¼äÐÅÏ¢)ÃüÁîÏê½â


dfÃüÁîÏêϸÓ÷¨
 
a£ºÏÔʾȫ²¿µÄµµ°¸ÏµÍ³ºÍ¸÷·Ö¸îÇøµÄ´ÅÅÌʹÓÃÇéÐÎ
i£ºÏÔʾi -nodesµÄʹÓÃÁ¿
k£º´óСÓÃkÀ´±íʾ (ĬÈÏÖµ)
t£ºÏÔʾijһ¸öµµ°¸ÏµÍ³µÄËùÓзָîÇø´ÅÅÌʹÓÃÁ¿
x£ºÏÔʾ²»ÊÇijһ¸öµµ°¸ÏµÍ³µÄËùÓзָîÇø´ÅÅÌʹÓÃÁ¿
T£ºÏÔʾÿ¸ö·Ö¸îÇøËùÊôµÄµµ°¸ÏµÍ³Ãû³Æ
³£ÓÃÃüÁdf -hi
 
²Ù×÷Ïê½â
 
ÒýÓÃ
Ö¸Áî df ¿ÉÒÔÏÔʾĿǰËùÓеµ°¸ÏµÍ³µÄ×î´ó¿ÉÓÿռ估ʹÓÃÇéÐΣ¬Çë¿´ÏÂÁÐÕâ¸öÀý×Ó£º
 
# df -h
Filesystem Size Used Avail Capacity Mounted on
/dev/ad0s1a 1.9G 389M 1.4G 21% /
devfs 1.0K 1.0K 0B 100% /dev
/dev/ad0s1d 989M 54K 910M 0% /tmp
/dev/ad0s1f 4.8G 3.8G 657M 86% /usr
/dev/ad0s1e 1.9G 149M 1.6G 8% /var
/dev/ad0s1g 26G 890K 24G 0% /volume2
/dev/da0s1d 325G 261G 38G 87% /volume1
 
ÎÒÃǼÓÁ˲ÎÊý -h ±íʾʹÓá¸Human-readable¡¹µÄÊä³ö£¬Ò²¾ÍÊÇÔÚµµ°¸ÏµÍ³´óСʹÓÃ
GB¡¢MB µÈÒ׶ÁµÄ¸ñʽ¡£
 
ÉÏÃæµÄÖ¸ÁîÊä³öµÄµÚÒ»¸ö×ֶμ°×îºóÒ»¸ö×ֶηֱðÊǵµ°¸ÏµÍ³¼°Æä¹ÒÈëµã¡£ÎÒÃÇ¿ÉÒÔ¿´µ½
/dev/ad0s1a Õâ¸ö·Ö¸îÇø±»¹ÒÔÚ¸ùĿ¼Ï¡£ÎÒÃÇÔÚÉÏһС½ÚÌáµ½¹ý ad Ëù´ú±íµÄÊÇ IDE µÄÓ²ÅÌ£¬¶ø s1
±íʾµÚÒ»¸öÖ÷ÒªÉÈÇø¡£ÎÒÁíÍâÓÐÒ»¸ö SCSI Ó²ÅÌ£¬ËüµÄ´úºÅÊÇ da£¬ËüµÄÈÝÁ¿ºÜ´ó£¬Ö÷ÒªÓÃÀ´´æ·ÅÊý¾Ý¡£devfs
ÊÇÒ»¸öÌرðµÄµµ°¸ÏµÍ³£¬¸Ãµµ°¸ÏµÍ³²¢·ÇÕæµÄ´ÅÅÌ£¬¶øÊÇ FreeBSD ÓÃÀ´¹ÜÀíϵͳӲ¼þ×°ÖõÄÐéÄâµµ°¸ÏµÍ³¡£
 
½ÓÏÂÀ´µÄËĸö×ֶΠSize¡¢Used¡¢Avail¡¢¼° Capacity
·Ö±ðÊǸ÷ָîÇøµÄÈÝÁ¿¡¢ÒÑʹÓõĴóС¡¢Ê£ÏµĴóС¡¢¼°Ê¹Óõİٷֱȡ£µ±Ó²ÅÌÈÝÁ¿ÒÑÂúʱ£¬Äú¿ÉÄܻῴµ½ÒÑʹÓõİٷֱȳ¬¹ý 100%£¬ÒòΪ FreeBSD
»áÁôһЩ¿Õ¼ä¸ø root£¬Èà root ÔÚµµ°¸ÏµÍ³Âúʱ£¬»¹ÊÇ¿ÉÒÔ䶫Î÷µ½¸Ãµµ°¸ÏµÍ³ÖУ¬ÒÔ½øÐйÜÀí¡£
 
ÁíÍ⣬ÎÒÃÇ»¹¿ÉÒÔʹÓòÎÊý -i À´²é¿´Ä¿Ç°µµ°¸ÏµÍ³ inode
µÄʹÓÃÇéÐΡ£ÓеÄʱºòËäÈ»µµ°¸ÏµÍ³»¹Óпռ䣬µ«ÈôûÓÐ×ã¹»µÄ inode À´´æ·Åµµ°¸µÄÐÅÏ¢£¬Ò»Ñù»á²»ÄÜÔö¼Óеĵµ°¸¡£
 
# df -ih
Filesystem Size Used Avail Capacity iused ifree
%iused Mounted on
/dev/ad0s1a 1.9G 389M 1.4G 21% 20495 262127 7% /
devfs 1.0K 1.0K 0B 100% 0 0 100% /dev
/dev/ad0s1d 989M 62K 910M 0% 24 141286 0% /tmp
/dev/ad0s1f 4.8G 3.8G 657M 86% 311439 348015 47%
/usr
/dev/ad0s1e 1.9G 149M 1.6G 8% 1758 280864 1% /var
/dev/ad0s1g 26G 890K 24G 0


Ïà¹ØÎĵµ£º

LinuxÏ°²×°MySQLÊý¾Ý¿â¹¥ÂÔ

1.MySQL¼ò½é
   MySQLÊÇÒ»¸ö¹ã·ºÊ¹ÓõĽṹ»¯²éѯÓïÑÔ£¨SQL£©Êý¾Ý¿â·þÎñÆ÷¡£ºÍÆäËûSQL·þÎñÆ÷Ò»Ñù£¬MySQLÌṩÁË·ÃÎʺ͹ÜÀíSQLÊý¾Ý¿âµÄ·½·¨£¬µ«ÊÇ£¬MySQLͬʱҲÌṩÁË´´½¨Êý¾Ý¿â½á¹¹ÒÔ¼°ÔÚÕâЩ½á¹¹ÖÐÌí¼Ó¡¢Ð޸ĺÍɾ³ýÕâЩ½á¹¹µÄ¹¤¾ß¡£
   MySQLÊý¾Ý¿âÏà¹ØµÄÈí¼þ°üÖ÷ÒªÓÐÒÔϼ¸ÖÖ£º
   ......

linux sedÃüÁîÏê½â


1. Sed¼ò½é
sed ÊÇÒ»ÖÖÔÚÏ߱༭Æ÷£¬ËüÒ»´Î´¦ÀíÒ»ÐÐÄÚÈÝ¡£´¦Àíʱ£¬°Ñµ±Ç°´¦ÀíµÄÐд洢ÔÚÁÙʱ»º³åÇøÖУ¬³ÆΪ“ģʽ¿Õ¼ä”£¨pattern
space£©£¬½Ó×ÅÓÃsedÃüÁî´¦Àí»º³åÇøÖеÄÄÚÈÝ£¬´¦ÀíÍê³Éºó£¬°Ñ»º³åÇøµÄÄÚÈÝËÍÍùÆÁÄ»¡£½Ó×Å´¦ÀíÏÂÒ»ÐУ¬ÕâÑù
1. Sed¼ò½é
sed ÊÇÒ»ÖÖÔÚÏ߱༭Æ÷£¬ËüÒ»´Î´¦ÀíÒ»ÐÐÄÚÈÝ¡£´¦Àíʱ£¬°Ñ ......

linux mountÃüÁîÏê½â

¹¦ÄÜ£º
¼ÓÔØÖ¸¶¨µÄÎļþϵͳ¡£
Óï·¨£º
mount [-afFhnrvVw] [-L] [-o] [-t] [É豸Ãû] [¼ÓÔصã]
Ó÷¨ËµÃ÷£º
mount¿É½«Ö¸¶¨É豸ÖÐÖ¸¶¨µÄÎļþϵͳ¼ÓÔص½LinuxĿ¼Ï£¨Ò²¾ÍÊÇ×°Ôص㣩¡£¿É½«¾­³£Ê¹ÓõÄÉ豸дÈë
Îļþ/etc/fastab,ÒÔʹϵͳÔÚÿ´ÎÆô¶¯Ê±×Ô¶¯¼ÓÔØ¡£mount¼ÓÔØÉ豸µÄÐÅÏ¢¼Ç¼ÔÚ/etc/mtabÎļþÖС£Ê¹ÓÃumountÃüÁîÐ ......

LinuxÉÏ»ñÈ¡Ö¸¶¨½ø³ÌµÄcpuʹÓÃÇé¿ö

ÕâÀï¼Ù¶¨Òª»ñÈ¡µ±Ç°µÇ¼Óû§Æô¶¯µÄtomcat½ø³ÌµÄcpuʹÓÃÇé¿ö
#!/bin/sh
_USER=`whoami`
_PS=`ps -ef | grep $_USER | grep catalina | grep tomcat`
_PID=`echo $_PS | awk '{print $2}'`
_CPUINFO=`top -b -n 1 -p $_PID | sed '$d' | sed -n '$p' | awk '{print $9}'`
echo $_CPUINFO
  ......

linux 0.11 Îļþϵͳ£¨¶þ£©

³¬¼¶¿éÃèÊöÁËÕû¸öÎļþϵͳµÄÐÅÏ¢£¬¶øÎļþ×÷Ϊ´æ´¢µÄ¶ÔÏó£¬ËüµÄÐÅÏ¢ÊÇÓÐinode½ÚµãÀ´ÃèÊöµÄ¡£i½ÚµãλͼÃèÊöÁËinodeµÄʹÓÃÇé¿ö¡£
struct m_inode{
        unsigned short i_mode; //ÎļþÀàÐÍ
        unsigned short i_uid;//ÎļþËÞÖ÷
......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ