linux network commands
1,ifconfigÃüÁî
ifconfig¿ÉÉèÖÃÍøÂçÉ豸µÄ״̬£¬»òÊÇÏÔʾĿǰµÄÉèÖá£
#ifconfig [ÍøÂçÉ豸] [down|up|-allmulti|-arp|-promisc] [add<µØÖ·>] [del<µØÖ·>] [<ÍøÂçÉ豸ÀàÐÍ> <Ó²¼þµØÖ·>] [io_addr] [irq ] [media<ÍøÂçý½éÀàÐÍ>] [mem_start<ÄÚ´æµØÖ·>]
[metric<ÊýÄ¿>] [mtu<×Ö½Ú>] [netmask<×ÓÍøÑÚÂë>] [tunnel<µØÖ·>] [-broadcast<µØÖ·>] [- pointopoint<µØÖ·>] [IPµØÖ·]
add<µØÖ·> ÉèÖÃÍøÂçÉ豸IPv6µÄIPµØÖ·¡£
del<µØÖ·> ɾ³ýÍøÂçÉ豸IPv6µÄIPµØÖ·¡£
down ¹Ø±ÕÖ¸¶¨µÄÍøÂçÉ豸¡£
<ÍøÂçÉ豸ÀàÐÍ><Ó²¼þµØÖ·> ÉèÖÃÍøÂçÉ豸µÄÀàÐÍÓëÓ²¼þµØÖ·
#ifconfig eth0 hw ether XX:XX:XX:XX:XX:XX(¸ü¸Äeth0µÄmacµØÖ·)
io_addr ÉèÖÃÍøÂçÉ豸µÄI/OµØÖ·¡£
irq ÉèÖÃÍøÂçÉ豸µÄIRQ¡£
media<ÍøÂçý½éÀàÐÍ> ÉèÖÃÍøÂçÉ豸µÄý½éÀàÐÍ¡£
mem_start<ÄÚ´æµØÖ·> ÉèÖÃÍøÂçÉ豸ÔÚÖ÷ÄÚ´æËùÕ¼ÓõÄÆðʼµØÖ·¡£
metric<ÊýÄ¿> Ö¸¶¨ÔÚ¼ÆËãÊý¾Ý°üµÄתËÍ´ÎÊýʱ£¬ËùÒª¼ÓÉϵÄÊýÄ¿¡£
mtu<×Ö½Ú> ÉèÖÃÍøÂçÉ豸µÄMTU¡£
netmask<×ÓÍøÑÚÂë> ÉèÖÃÍøÂçÉ豸µÄ×ÓÍøÑÚÂë¡£
tunnel<µØÖ·> ½¨Á¢IPv4ÓëIPv6Ö®¼äµÄËíµÀͨÐŵØÖ·¡£
up Æô¶¯Ö¸¶¨µÄÍøÂçÉ豸¡£
-broadcast<µØÖ·> ½«ÒªËÍÍùÖ¸¶¨µØÖ·µÄÊý¾Ý°üµ±³É¹ã²¥Êý¾Ý°üÀ´´¦Àí¡£
-pointopoint<µØÖ·> ÓëÖ¸¶¨µØÖ·µÄÍøÂçÉ豸½¨Á¢Ö±½ÓÁ¬Ïߣ¬´Ëģʽ¾ßÓб£Ãܹ¦ÄÜ¡£
-promisc ¹Ø±Õ»òÆô¶¯Ö¸¶¨ÍøÂçÉ豸µÄ»ìÔÓ(promiscuous)ģʽ¡£
[IPµØÖ·] Ö¸¶¨ÍøÂçÉ豸µÄIPµØÖ·¡£
[ÍøÂçÉ豸] Ö¸¶¨ÍøÂçÉ豸µÄÃû³Æ¡£
ʹÓÃifconfigºÍrouteÃüÁî¸ü¸ÄIPÉèÖÃ:
#ifconfig eth0 down (¹Ø±Õeth0)
#ifconfig eth0 hw ether XX:XX:XX:XX:XX:XX(ÁÙʱ¸ü¸Äeth0µÄmacµØÖ·£¬¼´Ê±ÉúЧ)
#ifconfig eth0 192.168.161.9 netmask 255.255.252.0 up (ÁÙʱÉèÖÃIPµØÖ·£¬×ÓÍøÑÚÂ룬¼´Ê±ÉúЧ)
#route add default gw 192.168.162.1 (ÁÙʱÉèÖÃÍø¹Ø£¬¼´Ê±ÉúЧ)
#vi /etc/sysconfig/network-scripts/ifcfg-eth0 (±à¼ÅäÖÃÎļþ£¬ÓÀ¾Ã¸ü¸ÄIPÉèÖã¬ÖØÆôÉúЧ)
#vi /etc/resolv.conf £¨±à¼ÅäÖÃÎļþ£¬ÉèÖÃDNS£©
#ifconfig eth0 promisc (½«eth0ÉèÖÃΪ»ìÔÓģʽ)
#ifconfig eth0 -promisc (È¡Ïû»ìÔÓģʽ)
#ifconfig eth0 arp (´ò¿ªeth0µÄarp½âÎö)
#ifconfig eth0 -arp (¹Ø±Õarp½âÎö)
#ifconfig eth0:1 192.168.1.1 netmask 255.255.255.0
Ïà¹ØÎĵµ£º
Ç°¼¸Ìì¸üÐÂubuntuµÄʱºò£¬Í»È»Ê§°Ü£¬×Ðϸһ¿´£¬ÊÇжÔØÀÏ°æ±¾µÄgzipʱºò³öÁËÎÊÌâ¡£´íÎóÐÅÏ¢£º
install-info: No dir file specified; try --help for more information.
ÊÔÁ˶à¸ö³£ÓõÄÊÖ¶¯Ð¶ÔØ·½·¨¶¼Ã»·¨¸ã¶¨£¬ÓÚÊÇÇóÖúgoogle£¬ºÜ¿ìÕÒµ½´ð°¸¡£ÊÇGNU°æµÄinstall-info´úÌæÁËdebian°æµÄinstall-infoÔì³ÉµÄÎÊÌ⣬¸²¸Ç»ØÀ´¾ÍOK ......
ÈçºÎ±àÒëLinuxµÄÄÚºË. Äںˣ¬ÊÇÒ»¸ö²Ù×÷ϵͳµÄºËÐÄ¡£Ëü¸ºÔð¹ÜÀíϵͳµÄ½ø³Ì¡¢ÄÚ´æ¡¢ É豸Çý¶¯³ÌÐò¡¢ÎļþºÍÍøÂçϵͳ£¬¾ö¶¨×ÅϵͳµÄÐÔÄܺÍÎȶ¨ÐÔ¡£Linux×÷Ϊһ¸ö×ÔÓÉÈí¼þ£¬ ÔÚ¹ã´ó°®ºÃÕßµÄÖ§³ÖÏ£¬Äں˰汾²»¶Ï¸üС£ÐµÄÄÚºËÐÞ¶©Á˾ÉÄں˵Äbug£¬²¢Ôö¼ÓÁËÐí
http://www.phpv.net/article.php/40
ÈçºÎ±àÒëLinuxÄÚºË- Linuxer ......
µÚ¶þÕ ±äÁ¿ºÍÔËËã·û
±¾µØ±äÁ¿:¾¡¿ÉÒÔ±»±¾½ø³ÌʹÓÃ
1 ¸³Öµ
varname=varvalue
varname="varvalue"
¿ÉÒÔͨ¹ýsetÃüÁî²é¿´±¾µØ±äÁ¿
readonly varname//ÉèÖÃΪֻ¶Á
readonly varnmae=varvalue//ÉèÖò¢³õʼ»¯
readonlyÃüÁî±¾Éí¿ÉÒÔÏÔʾËùÓÐÖ»¶Á±äÁ¿
»·¾³±äÁ¿£º¿ÉÒÔ±»×Ó½ø³ÌʹÓÃ
ϵͳ³õʼ»¯µÄ»·¾³±äÁ¿ $HOME/.bash_profi ......
1. tr ÃüÁîµÄ¹¦ÄÜ
trÃüÃûÊǼò»¯Á˵ÄsedÃüÁî¡£ÆäÖ÷ÒªµÄ¹¦ÄÜ°üÀ¨£º
a. ÓÃÒ»¸ö×Ö·ûÀ´Ìæ»»ÁíÍâÒ»¸ö×Ö·û¡£
b. ɾ³ý×Ö·û´®ÖеÄÖ¸¶¨×Ó´®¡£
c. ºÏ²¢×Ö·û´®ÖÐÖظ´´®¡£
2. ³£¼ûµÄÃüÁî¸ñʽ£º
tr -c -d -s ["string1_to_translate_from"] ["string2_to_translate_to"] < input-file
-c ÓÃ×Ö·û´®1ÖÐ×Ö·û¼¯µÄ²¹¼¯Ìæ»»´Ë×Ö·û¼¯£¬ ......
ÒÔÏÂÊǾ¹ý´ÓÍøÉϻ㼯¶ø³É£¬ÏÂÃæµÄÁ¬½ÓµÄ½éÉÜÒ²ÊDZȽÏÏêϸ£º
http://linux.chinaunix.net/techdoc/net/2008/07/26/1020404.shtml
linux NFS ÅäÖò½Öè
linux NFS ÅäÖò½Öè
NFS server¿ÉÒÔ¿´×÷ÊÇÒ»¸öFILE SERVER,Ëü¿ÉÒÔÈÃÄãµÄPCͨ¹ýÍøÂ罫Զ¶ËµÃNFS SERVER¹²Ïí³öÀ´µÄµµ°¸MOUNTµ½×Ô¼ºµÄϵͳÖУ¬Ô ......