[¾«²Ê] ÈçºÎ¸ølinuxÌí¼ÓÐÂÓ²ÅÌ
×÷Õߣºhaohaoo
À´×Ô£ºCnLinux.net¹¤×÷±Ê¼Ç
תÔØÇë±£ÁôÒÔÉÏÐÅÏ¢£¬Ð»Ð»
ÔÚ·þÎñÆ÷ÉÏ°ÑÓ²Å̽Ӻã¬Æô¶¯linux£¬ÒÔrootµÇ½¡£
±ÈÈçÎÒмÓÒ»¿éSCSIÓ²ÅÌ£¬ÐèÒª½«Æä·Ö³ÉÈý¸öÇø£º
#fdisk /dev/sdb
½øÈëfdiskģʽ£º
Command (m for help):p //²é¿´ÐÂÓ²Å̵ķÖÇø
Command (m for help):n //´´½¨Ð·ÖÇø
¿ÉÒÔÓÃmÃüÁîÀ´¿´fdiskÃüÁîµÄÄÚ²¿ÃüÁnÃüÁî´´½¨Ò»¸öзÖÇø£»dÃüÁîɾ³ýÒ»¸ö´æÔڵķÖÇø£»pÃüÁîÏÔʾ·ÖÇøÁÐ±í£»tÃüÁîÐ޸ķÖÇøµÄÀàÐÍIDºÅ£»lÃüÁîÏÔʾ·ÖÇøIDºÅµÄÁÐ±í£»aÃüÁîÖ¸¶¨Æô¶¯·ÖÇø£»wÃüÁîÊǽ«¶Ô·ÖÇø±íµÄÐ޸ĴæÅÌÈÃËü·¢Éú×÷Óá£
Command action
e extended //ÊäÈëeΪ´´½¨À©Õ¹·ÖÇø
p primary partition (1-4) //ÊäÈëpΪ´´½¨Ö÷·ÖÇø£¬ÕâÀïÎÒÃÇÑ¡Ôñp
Partion number(1-4)£º1 //µÚÒ»¸öÀ©Õ¹·ÖÇø£¬°´ÄãÐèÇó¿ÉÒÔ×î¶à·Ö4¸öÖ÷·ÖÇø
First Cylinder(1-1014,default 1): 1 //µÚÒ»¸öÖ÷·ÖÇøÆðʼµÄ´ÅÅÌ¿éÊý
Last cylindet or +siza or +sizeM or +sizeK: +1024MB //¿ÉÒÔÊÇÒÔMBΪµ¥Î»µÄÊý×Ö»òÕßÒÔ
´ÅÅÌ¿éÊý£¬ÕâÀïÎÒÃÇÊäÈë+1024MB±íʾ·ÖÇø´óСΪ1G¡£
ÕâÑùÎÒÃǾʹ´½¨ÍêÒ»¸ö·ÖÇø£¬Èç¹ûÒª´´½¨¸ü¶à·ÖÇø¿ÉÒÔÕÕÉÏÃæµÄ²½Öè¼ÌÐø´´½¨¡£
´´½¨ÍêºóÓÃw±£´æ·ÖÇø¡£
Command (m for help): w
The partition table has been altered!
Calling ioctl() to re-read partition table.
Syncing disks.
ÕâÑù¾Í·ÖÇøÍ꣬ÎÒÃÇ»¹Òª½øÐиñʽ»¯
#mkfs -t ext3 -c /dev/sdb1 //Èç¹ûÓжà¸ö·ÖÇø£¬Ôò·ÖÇøÐÞ¸ÄΪsdb2ÕâÑù
¸ñʽ»¯ÍêºóÎÒÃÇÐèÒª½øÐйÒÔØ·ÖÇø£¬
#mkdir www //´´½¨/wwwĿ¼£¬ÎÒÃǽ«°ÑеķÖÇø¹Òµ½wwwÏÂ
#mount /dev/sdb1 /www //½«/dev/sdb1¹ÒÔص½/www
# df //ÓÃdfÃüÁî½øÐв鿴
Filesystem 1K-blocks Used Available Use% Mounted on
/dev/sda2 3771316 1388956 2190788 39% /
/dev/sda1 101089 9463 86407 10% /boot
none &
Ïà¹ØÎĵµ£º
ÔÚlinuxµÄprocÎļþϵͳÖУ¬Í¨¹ý²é¿´/proc/net/devÎļþ
¿ÉÒԵõ½Ã¿¸öÍøÂç½Ó¿ÚµÄÍÌÍÂÁ¿£¬µ«ÊÇÎÞ·¨»ñµÃʵʱ´ø¿í
×î½ü·¢ÏÖÁËÒ»ÖÖ»ùÓÚncurses¿âµÄС³ÌÐòbmon£¬¿ÉÒÔ»ñµÃʵʱ´ø¿í
Example:
Ö´ÐÐ
[root@debian ~]# bmon -o ascii -p eth0
Interface RX Rate RX # TX Rate TX #
eth0 0.00B 0.0 0.00B 0.0
eth0 0.00B 0.0 ......
´ó¼Ò¶¼ÖªµÀ£¬ÎϾÓÀïС±´ÊǸãc++µÄ£¬½á¹û×îºóÀÏÆŸøÈ˵±ÁËСÈý
¾ÍΪÁËÕâ¸öÒýÆð¹ã´óÍøÓѵÄÈÈÒ飬µ«±È½ÏÒ»ÏÂÎÒÃÇ»¹ÊǺܲ»´íµÎ¡£ÔÚÈÕ±¾£¬¸ãLinuxµÄÒ²µÃÅÄAV¡£ÓÐͼÓÐÕæÏà
³ÌÐòÔ±ÐÖµÜÃÇ£¬²»Òª±§Ô¹ÁË£¬±È±ÈСÈÕ±¾£¬ÎÒÃǵĴ¦¾³ºÃ¶àÁËO(∩_∩)O¹þ¹þ~ ......
LinuxÏÂcoreÎļþµ÷ÊÔ·½·¨
ÔÚ³ÌÐò²»Ñ°³£Í˳öʱ£¬Äں˻áÔÚµ±Ç°¹¤×÷Ŀ¼ÏÂÉú³ÉÒ»¸öcoreÎļþ£¨ÊÇÒ»¸öÄÚ´æÓ³Ïñ£¬Í¬Ê±¼ÓÉϵ÷ÊÔÐÅÏ¢£©¡£Ê¹ÓÃgdbÀ´²é¿´coreÎļþ£¬¿ÉÒÔָʾ³öµ¼Ö³ÌÐò³ö´íµÄ´úÂëËùÔÚÎļþºÍÐÐÊý¡£
1.coreÎļþµÄÉú³É¿ª¹ØºÍ´óСÏÞÖÆ
1£©Ê¹ÓÃul ......
Ãû³Æ : crontab
¡¡¡¡Ê¹ÓÃȨÏÞ : rootÓû§ºÍcrontabÎļþµÄËùÓÐÕß
¡¡¡¡Óï·¨ :
¡¡¡¡crontab [-e [UserName]|-l [UserName]|-r [UserName]|-v [UserName]|File ]
ÖØÆô£ºsudo /etc/init.d/cron restart
¡¡¡¡ËµÃ÷ :
¡¡¡¡crontab ÊÇÓÃÀ´ÈÃʹÓÃÕßÔڹ̶¨Ê±¼ä»ò¹Ì¶¨¼ä¸ôÖ´ÐгÌʽ֮Ó㬻»¾ä»°Ëµ£ ......
Tar
¡¡¡¡Ó¢ÎÄÔÒ壺Tape ARchive
¡¡¡¡ÖÐÎÄÊÍÒ壺´Å´ø¹éµµ
¡¡¡¡×¢ ½â£ºUNIX/LinuxÖеÄÒ»¸öÎļþ´ò°ü¹¤¾ß£¬ÓÃÓÚ½«Ðí¶àÎļþÒ»Æð´ò°ü£¬ÐγÉÒ»¸öµµ°¸Îļþ£¬ÒÔ±ã¹éµµ¡£Ëü×î³õÉè¼ÆÓÃÓÚ´Å´ø±¸·Ý£¬ÏÖÔÚÒ²¿ÉÓÃÓÚÆäËü´æ´¢½éÖÊ¡£µ¥¶ÀʹÓÃʱ£¬Éú³É¾ßÓÐ.tarÀ©Õ¹ÃûµÄÎļþ¡£µ±ÓëGzip½áºÏÓÃÓÚÊý¾ÝѹËõʱ£¬Éú³ÉµÄÎļþÀ©Õ¹Ãû¿ÉÄÜÊÇ.tgz¡¢.t ......