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

linux½âѹtarÃüÁî


linux½âѹ tarÃüÁî
tarÃüÁî
tar [-cxtzjvfpPN] ÎļþÓëĿ¼ ....

²ÎÊý£º
-c £º½¨Á¢Ò»¸öѹËõÎļþµÄ²ÎÊýÖ¸Áî(create µÄÒâ˼)£»
-x
£º½â¿ªÒ»¸öѹËõÎļþµÄ²ÎÊýÖ¸Á
-t £º²é¿´ tarfile ÀïÃæµÄÎļþ£¡
Ìرð×¢Ò⣬ÔÚ²ÎÊýµÄÏ´ïÖУ¬ c/x/t ½öÄÜ´æÔÚÒ»¸ö£¡²»¿Éͬʱ´æÔÚ£¡
ÒòΪ²»¿ÉÄÜͬʱѹËõÓë½âѹËõ¡£
-z £ºÊÇ·ñͬʱ¾ßÓÐ gzip µÄÊôÐÔ£¿Ò༴ÊÇ·ñÐèÒªÓà gzip ѹËõ£¿
-j £ºÊÇ·ñͬʱ¾ßÓÐ bzip2
µÄÊôÐÔ£¿Ò༴ÊÇ·ñÐèÒªÓà bzip2 ѹËõ£¿
-v £ºÑ¹ËõµÄ¹ý³ÌÖÐÏÔʾÎļþ£¡Õâ¸ö³£Ó㬵«²»½¨ÒéÓÃÔÚ±³¾°Ö´Ðйý³Ì£¡
-f £ºÊ¹ÓõµÃû£¬ÇëÁôÒ⣬ÔÚ f
Ö®ºóÒªÁ¢¼´½ÓµµÃûร¡²»ÒªÔÙ¼Ó²ÎÊý£¡
¡¡¡¡¡¡ÀýÈçʹÓẠtar -zcvfP tfile sfile¡»¾ÍÊÇ´íÎóµÄд·¨£¬ÒªÐ´³É
¡¡¡¡¡¡¡º tar
-zcvPf tfile sfile¡»²Å¶Ôร¡
-p £ºÊ¹ÓÃÔ­ÎļþµÄÔ­À´ÊôÐÔ£¨ÊôÐÔ²»»áÒÀ¾ÝʹÓÃÕ߶ø±ä£©
-P £º¿ÉÒÔʹÓþø¶Ô·¾¶À´Ñ¹Ëõ£¡
-N £º±ÈºóÃæ½ÓµÄÈÕÆÚ(yyyy/mm/dd)»¹ÒªÐµIJŻᱻ´ò°ü½øн¨µÄÎļþÖУ¡
--exclude FILE£ºÔÚѹËõµÄ¹ý³ÌÖУ¬²»Òª½« FILE
´ò°ü£¡
·¶Àý£º

·¶ÀýÒ»£º½«Õû¸ö /etc Ŀ¼ÏµÄÎļþÈ«²¿´ò°ü³ÉΪ
/tmp/etc.tar

[root@linux
~]#
tar -cvf /tmp/etc.tar
/etc
<==½ö´ò°ü£¬²»Ñ¹Ëõ£¡

[root@linux ~]#
tar -zcvf /tmp/etc.tar.gz /etc
<==´ò°üºó£¬ÒÔ gzip ѹËõ

[root@linux ~]#
tar -jcvf /tmp/etc.tar.bz2 /etc
<==´ò°üºó£¬ÒÔ bzip2 ѹËõ

# Ìرð×¢Ò⣬ÔÚ²ÎÊý f Ö®ºóµÄÎļþµµÃûÊÇ×Ô¼ºÈ¡µÄ£¬ÎÒÃÇÏ°¹ßÉ϶¼Óà .tar À´×÷Ϊ±æʶ¡£
# Èç¹û¼Ó z
²ÎÊý£¬ÔòÒÔ .tar.gz »ò .tgz À´´ú±í gzip ѹËõ¹ýµÄ tar file ¡«
# Èç¹û¼Ó j ²ÎÊý£¬ÔòÒÔ .tar.bz2
À´×÷Ϊ¸½µµÃû°¡¡«
# ÉÏÊöÖ¸ÁîÔÚÖ´ÐеÄʱºò£¬»áÏÔʾһ¸ö¾¯¸æѶϢ£º
# ¡ºtar: Removing leading `/" from
member names¡»ÄÇÊǹØ춾ø¶Ô·¾¶µÄÌØÊâÉ趨¡£
·¶Àý¶þ£º²éÔÄÉÏÊö /tmp/etc.tar.gz ÎļþÄÚÓÐÄÄЩÎļþ£¿

[root@linux ~]# tar -ztvf
/tmp/etc.tar.gz

# ÓÉì¶ÎÒÃÇʹÓà gzip
ѹËõ£¬ËùÒÔÒª²éÔĸà tar file ÄÚµÄÎļþʱ£¬
# ¾ÍµÃÒª¼ÓÉÏ z Õâ¸ö²ÎÊýÁË£¡ÕâºÜÖØÒªµÄ£¡
·¶ÀýÈý£º½« /tmp/etc.tar.gz Îļþ½âѹËõÔÚ /usr/local/src
µ×ÏÂ

[root@linux ~]# cd
/usr/local/src

[root@linux src]# tar -zxvf /tmp/etc.tar.gz

# ÔÚÔ¤ÉèµÄÇé¿öÏ£¬ÎÒÃÇ¿ÉÒÔ½«Ñ¹ËõµµÔÚÈκεط½½â¿ªµÄ£¡ÒÔÕâ¸ö·¶ÀýÀ´Ëµ£¬
# ÎÒÏȽ«¹¤×÷Ŀ¼±ä»»µ½
/usr/local


Ïà¹ØÎĵµ£º

LinuxÄÚºËÅäÖÃÎĵµ(make menuconfig)

Ò»¡¢ÒýÑÔ£º
    ±¾ÎĵµµÄÄÚÈݴ󲿷ÝÄÚÈݶ¼ÊÇ´ÓÍøÉÏÊÕ¼¯¶øÀ´£¬È»ºóÅäºÏһЩеĽØͼ£¨Äں˰汾£ºV2.4.19£©¡£ÔÚÿһÅäÖÃÏîºó»áÓÐÒ»¸öÑ¡ÔñÖ¸ÄϵIJ¿·Ý£¬ÓÃÀ´Ö¸µ¼´ó¼ÒÔõôÑù¸ù¾Ý×Ô¼ºµÄÇé¿öÀ´×öÏàÓ¦µÄÑ¡Ôñ£»»¹ÓÐÔÚÿһ¸ö´óÏîºÍÎĵµµÄ×îºó»áÓÐÒ»¸ö¾­Ñé̸£¬ËüÊÇһЩ¸ßÊÖÃÇÔÚÓ¦¶ÔÎÊÌâºÍ´¦ÀíÌØÓÐÓ²¼þʱµÄһЩ¾­Ñ飨Õâ¸ö»¹µ ......

Linux¹Ø»úÃüÁîÏê½â

ÔÚlinuxÏÂһЩ³£ÓõĹػú/ÖØÆôÃüÁîÓÐshutdown¡¢halt¡¢reboot¡¢¼°init£¬ËüÃǶ¼
¡¡¡¡¿ÉÒÔ´ïµ½ÖØÆôϵͳµÄÄ¿µÄ£¬µ«Ã¿¸öÃüÁîµÄÄÚ²¿¹¤×÷¹ý³ÌÊDz»Í¬µÄ£¬Í¨¹ý±¾ÎĵĽéÉÜ£¬Ï£
¡¡¡¡ÍûÄã¿ÉÒÔ¸ü¼ÓÁé»îµÄÔËÓø÷ÖֹػúÃüÁî¡£
¡¡¡¡1.shutdown
¡¡¡¡shutdownÃüÁȫµØ½«ÏµÍ³¹Ø»ú¡£ ÓÐЩÓû§»áʹÓÃÖ±½Ó¶ÏµôµçÔ´µÄ·½Ê½À´¹Ø±Õlinux£¬
¡¡¡¡ ......

linuxϽûÖ¹ÐÞ¸ÄDNS·þÎñÆ÷µØÖ·(DNS±»×Ô¶¯ÐÞ¸ÄÎÊÌâ)

´ó¼Ò¶¼ÖªµÀÐÞ¸ÄlinuxϵÄDNS¿ÉÒÔÖ±½ÓÐÞ¸Ä/etc/resolv.conf:
root@xuanfei-desktop:~#vim /etc/resolv.conf
nameserver ip //ÌîÉÏÄãµ±µØʹÓõÄ×î¿ìDNS·þÎñÆ÷IPµØÖ·
nameserver ip   
 
µ±È»Ò²¿ÉÒÔÖ±½ÓʹÓÃÍøÂç¹ÜÀíÆ÷Ð޸ġ£
µ«ÊÇÈç¹ûÄãËùÔÚ»ú¹¹»òÕß¹¤×÷µÄµØ·½±ØÐëÒªÇóÄãÓÃDHCP»ñµÃ×Ô¼º·Ç¹Ì¶¨¶¯Ì¬IP ......

linux ѧϰ¹ý³Ì£¨1£©

                         linux»ù´¡ÖªÊ¶
General Public Licence  GPL
GNU ÏîÄ¿µÄc¿â£¬gcc£¬Emacs£¬bashµÈÒÆÖ²µ½linuxÄÚºË
linux°æ±¾ÓУºlinux   BSD unix    ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ