当前位置:   article > 正文

Ubuntu 10.04中配置ip地址 .

ubuntu10.04配置ip

一、直接修改Ubuntu IP系统配置文件

Ubuntu IP的网络配置文件是:/etc/network/interfaces打开后里面可设置DHCP或手动设置静态ip。前面auto eth0,让网卡开机自动挂载。

1.以DHCP方式配置网卡

(1)打开要编辑的文件interfaces 它的的目录是/etc/network/interfaces

sudo vi /etc/network/interfaces 

或者:sudo gedit /etc/network/interfaces 此时便可以在文本编辑器中编写文件中的内容,要方便多

(2)将文件里的内容改为:

auto eth0

iface eth0 inet dhcp

(3)使用下面的命令使网络设置生效

sudo /etc/init.d/networking restart

(4)出了上面那种直接修改配置文件,如果要动态获取ip的话,还可以直接使用命令:

sudo dhclient eth0

使用了此句后,网卡eth0的ip地址被设定为10.0.2.15,此时虚拟机可以ping通主机,且可以与主机共享上网。(但是此时主机ping不通虚拟机)

 

2. 为网卡配置静态Ubuntu IP地址

(1)打开要编辑的文件interfaces 它的的目录是/etc/network/interfaces

sudo vi /etc/network/interfaces 

或者:sudo gedit /etc/networking/interfaces 此时便可以在文本编辑器中编写文件中的内容,要方便多

(2)将文件里的内容改为:

auto eth1

iface eth1 inet static

address 10.10.103.77

netmask 255.255.255.0

gateway 10.10.103.20

 

 

(3)配置DNS

sudo gedit /etc/resolv.conf //使用此语句打开配置DNS的文件,修改即可

nameserver 202.119.230.8

(4)使用下面的命令使网络设置生效

sudo /etc/init.d/networking restart

 

或者执行:sudo ifup eth1

执行此命令后,虚拟机的网卡eth1的ip地址被设定为10.10.103.77,此ip地址与主机ip地址在同一个网段中,此时主机便可以ping通虚拟机了。(执行的前提是已经给此虚拟机设置了NAT和桥接方式)

 

二、实现主机和虚拟机之间相互通信

预备知识:
host-only模式下,主机相当于一台双网卡的电脑,物理网卡是外网,vmnet1是内网,此时虚拟机和主机通信的前提就是vmnet1的ip和虚拟机的ip在同一网段。 桥接模式下,主机和虚机相当于是两台接在同一交换机上的电脑,此时,虚拟机的ip地址应该和主机的物理网卡ip在同一网段,此时就能通信,当然包括也包括ping。如果不通,可能跟防火墙有关系。 
采用的方法是:设置两个虚拟网卡,其中一个用NAT连接,以连接外网;一个用桥接,用来与主机互相通信。

步骤:

1、在启动虚拟机之前, 在“Network ”中默认设置 第一块虚拟网卡(即用NAT方式)
 
,然后切换到Adapter2启用第二块虚拟网卡,并更改为桥接连接方式:

2、启动虚拟机,编辑eth1,在里面设置以太网接口eth1的IP地址、子网掩码和网关,这一步最为重要。eth1这块网卡是桥接用的,即是与你主机互相通信用的,所以这里设置的IP要与主机的IP地址同个网段,网关和子网掩码就和主机的设置一致,然后设置IP为静态。保存退出后,执行 sudo ifup eth1 后便可以和主机互ping了。

3、使用 sudo dhclient eth0 命令来动态分配eth0网卡的地址,可以看到设置后此 IP为专有IP地址,用来NAT连接的,通过NAT转换之后就能上外网了。

 
 

4、用ifconfig查看网络接口信息,可以看到三个网卡,eth0,eth1,lo。

 

三、使用命令设置Ubuntu IP地址(未实现!!)

 

 

(1)修改配置文件blacklist.conf禁用IPV6:sudo vi /etc/modprobe.d/blacklist.conf

 

(2)在文档最后添加 blacklist ipv6,然后查看修改结果:cat /etc/modprobe.d/blacklist.conf

 

(3)设置Ubuntu IP(设置网卡eth0的IP地址和子网掩码)sudo ifconfig eth0 192.168.2.1 netmask 255.255.255.0

 

(4)Ubuntu IP设置网关sudo route add default gw 192.168.2.254     

 

(5)Ubuntu IP设置DNS修改/etc/resolv.conf,在其中加入nameserver DNS的地址1 和 nameserver DNS的地址2 完成。

(6)重启网络服务(若不行,请重启ubuntu:sudo reboot):sudo /etc/init.d/networking restart

(7)查看当前Ubuntu IP:ifconfig

 

四、ifconfig用法(未看)

 

 

无论是Linux 自动安装还是我们手工安装,Linux 都会向你询问有关网络的问题并配置相关的软件。这个用于配置网卡的基本命令就是ifconfig。
在执行ifconfig 命令后,系统将在内核表中设置必要的参数,这样Linux 就知道如何与网络上的网卡通
信。ifconfig 命令有以下两种格式:

  1. ※ifconfig <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">[</SPAN><STRONG>interface</STRONG><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">]</SPAN>  
  2. ※ifconfig <STRONG>interface</STRONG> <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">[</SPAN>aftype<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">]</SPAN> option <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">|</SPAN> address …  
  1. ※ifconfig [interface]
  2. ifconfig interface [aftype] option | address

ifconfig 的第一种格式(或使用不带任何参数的ifconfig 命令)可以用来查看当前系统的网络配置情况。
在刚刚安装完系统之后,实际上是在没有网卡或者网络连接的情况下使用Linux,但通过ifconfig 可以使用回绕方式工作,使计算机认为自己工作在网络上。
现在我们运行一下ifconfig 命令,不带参数的ifconfig 命令可以显示当前启动的网络接口,其输出结果
为:

  1. <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">[</SPAN>root<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">@</SPAN>machine1 <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">/</SPAN>sbin<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">]</SPAN><EM>#ifconfig  
  2. </EM>eth0 <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(153,0,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">Link</SPAN> encap<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>Ethernet Hwaddr <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">52</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">54</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>AB<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>DD<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>6F<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">61</SPAN>  
  3. inet addr<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>210<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>34<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>6<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>89 Bcast<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>210<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>34<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>6<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>127 Mask<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>128  
  4. UP BROADCAST RUNNING MULTICAST MTU<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">1500</SPAN> Metric<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">1</SPAN>  
  5. RX packets<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">46299</SPAN> errors<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> dropped<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> overruns<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> frame<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">189</SPAN>  
  6. TX packets<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">3057</SPAN> errors<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> dropped<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> overruns<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> carrier<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN>  
  7. collisions<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> txqueuelen<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">100</SPAN>  
  8. Interrupt<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">5</SPAN> Base address<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(32,128,128); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0xece0</SPAN>  
  9. lo <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(153,0,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">Link</SPAN> encap<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>Local Loopback  
  10. inet addr<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>127<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>0<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>0<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>1 Mask<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>0<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>0<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>0  
  11. UP LOOPBACK RUNNING MTU<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">3924</SPAN> Metric<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">1</SPAN>  
  12. RX packets<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">44</SPAN> errors<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> dropped<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> overruns<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> frame<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN>  
  13. TX packets<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">44</SPAN> errors<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> dropped<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> overruns<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> carrier<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN>  
  14. collisions<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> txqueuelen<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN>  
  1. [root@machine1 /sbin]#ifconfig
  2. eth0 Link encap:Ethernet Hwaddr 52:54:AB:DD:6F:61
  3. inet addr:210.34.6.89 Bcast:210.34.6.127 Mask:255.255.255.128
  4. UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
  5. RX packets:46299 errors:0 dropped:0 overruns:0 frame:189
  6. TX packets:3057 errors:0 dropped:0 overruns:0 carrier:0
  7. collisions:0 txqueuelen:100
  8. Interrupt:5 Base address:0xece0
  9. lo Link encap:Local Loopback
  10. inet addr:127.0.0.1 Mask:255.0.0.0
  11. UP LOOPBACK RUNNING MTU:3924 Metric:1
  12. RX packets:44 errors:0 dropped:0 overruns:0 frame:0
  13. TX packets:44 errors:0 dropped:0 overruns:0 carrier:0
  14. collisions:0 txqueuelen:0

其中以eth0 为首的部分是本机的以太网卡配置参数,这里显示了网卡在下的设备名/dev/eth0 和硬件的MAC 地址52:54:AB:DD:6F:61,MAC 地址是生产厂家定的,每个网卡拥有的唯一地址。
不过我们可以手工改动网卡的MAC 地址,只要我们在/etc/rc.d/init.d/中的network 中加入:

  1. ifconfig eth0 hw ether xx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>xx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>xx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>xx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>xx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>xx  
ifconfig eth0 hw ether xx:xx:xx:xx:xx:xx

然后重启,此时再用ifconfig 命令查看一下,我们就会发现网卡的MAC 地址已经变成xx:xx:xx:xx:xx:xx
了。
下一行显示本机的IP 地址信息,分别是本机的IP 地址,网络广播地址和子网掩码。必须确认这些信息都是正确无误的,否则Linux 服务器无法与其它网络设备建立连接。我们也可以手工实现IP 与Mac 地址的
捆绑,命令是

  1. arp <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">-</SPAN>i eth0 <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">-</SPAN>s xxx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>xxx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>xxx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>xxx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">(</SPAN>IP<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">)</SPAN> xx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>xx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>xx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>xx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>xx<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">(</SPAN>MAC<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">)</SPAN>  
arp -i eth0 -s xxx.xxx.xxx.xxx(IP) xx.xx.xx.xx.xx(MAC)

接下来显示的是设备的网络状态。MTU(最大传输单元)和Metric(度量值)字段显示的是该接口当前的
M T U 和度量值的值。按照惯例,度量值供某些操作系统所用,用于计算一条路由的成本。
再下来显示接口通信的网络统计值。RX 和TX 分别表示接收和传送的数据包。如果你的网卡已经完成配置却还是无法与其它设备通信,那么从RX 和TX 的显示数据上可以简单地分析一下故障原因。在这种情况下,如果你看到接收和传送的包的计数(packets)增加,那有可能是系统的IP 地址出现了混乱;如果你看到大量的错误(errors)和冲突(Collisions),那么这很有可能是网络的传输介质出了问题,例如网线不通或hub损坏。
再下面的Interrupt:5 Base address:0xece0 显示的是网卡的中断调用号和端口号,这是两个非常重要的硬件配置信息。如果您的网卡是PCI 的,那么Linux 在引导时有可能会自动配置这些信息(也很有可能会让您手工配置)但目前绝大多数网卡都是PnP 的,这就需要我们进行手工配置了。如果您的网卡还没有
配置好,那么运行:

  1. <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">[</SPAN>root<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">@</SPAN>machine1 <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">/</SPAN>sbin<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">]</SPAN><EM>#ifconfig</EM>  
[root@machine1 /sbin]#ifconfig

系统只会输出以lo 为首的部分。lo 是look-back 网络接口,从IP 地址127.0.0.1 就可以看出,它代表”本机”。无论系统是否接入网络,这个设备总是存在的,除非你在内核编译的时候禁止了网络支持,这是一个称为回送设备的特殊设备,它自动由Linux 配置以提供网络的自身连接。IP 地址 127.0.0.1 是一个特殊的回送地址(即默认的本机地址),您可以在自己的系统上用telnet 对IP 地址127.0.0.1 进行测试。如果有inetd进程在运行的话您会从自己的机器上获得登录提示符。Linux 可以利用这个特征在进程与仿真网络之间进行通信。(您有兴趣的话还可以试试本机的实际IP 地址,如这里的机器就是210.34.6.89,或者试试”localhost”,或者”127.0.0.1″,同样可以模拟网络通信。这可是Linux 一个非常突出的优点!)
如果你只是关心某个设备是否正常,可以在ifconfig 后面加上接口名字:

  1. <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">[</SPAN>root<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">@</SPAN>machine1 <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">/</SPAN>sbin<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(0,153,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">]</SPAN><EM># ifconfig eth0  
  2. </EM>eth0 <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(153,0,0); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">Link</SPAN> encap<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>Ethernet HWaddr <SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">52</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">54</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>AB<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>DD<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>6F<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">61</SPAN>  
  3. inet addr<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>210<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>34<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>6<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>89 Bcast<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>210<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>34<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>6<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>127 Mask<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>128  
  4. UP BROADCAST RUNNING MULTICAST MTU<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">1500</SPAN> Metric<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">1</SPAN>  
  5. RX packets<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">50568</SPAN> errors<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> dropped<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> overruns<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> frame<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">198</SPAN>  
  6. TX packets<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">3200</SPAN> errors<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> dropped<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> overruns<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> carrier<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN>  
  7. collisions<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> txqueuelen<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">100</SPAN>  
  8. Interrupt<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">5</SPAN> Base address<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(32,128,128); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0xece0</SPAN>  
  1. [root@machine1 /sbin]# ifconfig eth0
  2. eth0 Link encap:Ethernet HWaddr 52:54:AB:DD:6F:61
  3. inet addr:210.34.6.89 Bcast:210.34.6.127 Mask:255.255.255.128
  4. UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
  5. RX packets:50568 errors:0 dropped:0 overruns:0 frame:198
  6. TX packets:3200 errors:0 dropped:0 overruns:0 carrier:0
  7. collisions:0 txqueuelen:100
  8. Interrupt:5 Base address:0xece0

表示eth0 设备已经正常工作。
有时需要为某个设备接口配置多个IP 地址,办法是使用设备别名,例如,eth0 设备可以有eth0,eth0:0,
eth0:1….多个别名,每个都可以有一个独立的IP 地址:

  1. ifconfig eth0 210<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>34<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>6<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>89 netmask 255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>128 broadcast 210<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>34<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>6<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>127  
  2. ifconfig eth0<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">:</SPAN><SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(204,102,204); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">0</SPAN> 210<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>34<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>6<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>88 netmask 255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>128 broadcast 210<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>34<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>6<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>127  
  1. ifconfig eth0 210.34.6.89 netmask 255.255.255.128 broadcast 210.34.6.127
  2. ifconfig eth0:0 210.34.6.88 netmask 255.255.255.128 broadcast 210.34.6.127

这样,210.34.6.89 和210.34.6.88 都会被绑定在eth0 设备上,使用同样的网络设备,不同的IP 地址。
如果你要暂停某个网络接口的工作,使用down 参数:

  1. ifconfig eth0 down  
ifconfig eth0 down

将取消eth0 网络接口。与之对应的是有一个参数up,不过由于是缺省值,所以从来不用。
如果我们使用了带有参数的ifconfig 命令,那就可以手动设置网卡的配置参数了。有效的ifconfig 命令参数及其意义为(选项对应的特性可以打开也可以取消,只在选项名前加一个破折号(-)即可):
Interface 网络设备名,如eth0 就表示本机的第一块网卡。
up 标志接口处于” up”状态,也就是说, IP 层可以对其进行访问。这个选项用于命令行上给出一个地址之时。如果这个接口已被” down”选项临时性取消的话(与该选项对应的标记是UP RUNNING),还可以用于重新启用一个接口。down 标标志接口处于” down”状态,也就是说, IP 层不能对其进行访问。这个选项有效地禁止了IP 通信流通这个接口。注意,它并没有自动删除利用该接口的所有路由信息。如果永久性地取消了一个接口,就应该删除这些路由条目,并在可能的情况下,提供备用路由。
netmask 标分配子网掩码,供接口所用。要么给一个前面是0x 的32 位十六进制号码,要么采用只适用于两台主机所用的点分四段式号码。对SLIP 和PLIP 接口来说,这个选项是必须配置的。
address 设置指定接口设备的IP 地址。
dstaddr adderss 为PPP 设置远程IP 地址,此关键字可用pointopoint 代替。
irqaddress 设置指定接口设备使用的中断行。
pointtopoint address 该选项用于只涉及两台主机的点到点链接。对SLIP 和PLIP 接口来说,这个选项是必须配置的(如果已经设置了一个点到点地址,ifconfig 就会显示出POINTTPOINT 标记)。
broadcast address 广播地址通常源于网络编号,通过设置主机部分的所有位得来。有的I P 采用的方案有所不同:这个选项可适用于某些奇怪的环境(如果已经设置了广播地址, ifconfig 就会显示出一个BROADCAST 标记)。hw class addr 设置指定接口设备的MAC 地址,关键字的后面必须跟硬件名或者与之等价的ASCII码。目前支持的硬件类有ether, ax25, ARCnet 和netrom。
metric number 该选项可用于为接口创建的路由表分配度量值。路由信息协议( RIP)利用度量值来构建
网络路由表。ifconfig 所用的默认度量值是0。如果不运行RIP 程序,就没必要采用这个选项。如果要运行RIP 程序,就尽量不要改变这个默认的度量值。
mtu bytes 该选项用于设置最大传输单元,也就是接口一次能处理的最大字节数。对以太网接口来说, MTU的默认设置是1500 个字节;对SLIP 接口来说,则是296 个字节。
arp 标这个选项专用于以太网或包广播之类的广播网络。它启用ARP(地址解析协议)来保护网络上各台
主机的物理地址。对广播网来说,默认设置是” on”(开)。
promisc 将接口置入promiscuous(混乱)模式。广播网中,这样将导致该接口接收所有的数据包,不管其目标是不是另一台主机。该选项允许利用包过滤器和所谓的以太网窥视技术,对网络通信进行分析。通常情况下,这对揪出网络故障的元凶来说,是相当有用的。但另一方面,如果有人蓄意攻击你的网络,也可浏览到 s 通信数据,进而获得密码,破坏你的网络。一项重要的保证措施是杜绝任何人将他们的计算机接入你的以太网。另一个选项用于保护某些身份验证协议的安全,比如Kerberos 或SRA 登录套件(该选项对应的标记是PROMISC)。
traIlers 开或关闭跟踪器。目前在某些Linux 系统中还无法实现此功能。
allmulti 多播地址即是向不在同一个子网上的一组主机广播数据。多播地址尚未获得内核支持(该选项对应的标记是ALLMULTI)txqueuelen len 设置指定接口设备的发送队列长度。
由此可以看出有大量的参数可用于配置网卡,下面是在这台计算机上使用ifconfig 命令的实例:

  1. ifconfig eth0 210<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>34<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>6<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>89 netmask 255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>255<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>128 broadcast 210<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>34<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>6<SPAN style="TEXT-ALIGN: left; PADDING-BOTTOM: 0px; BORDER-RIGHT-WIDTH: 0px; FONT-STYLE: normal; MARGIN: 0px; PADDING-LEFT: 0px; PADDING-RIGHT: 0px; FONT-FAMILY: inherit; BORDER-TOP-WIDTH: 0px; BORDER-BOTTOM-WIDTH: 0px; COLOR: rgb(51,153,51); BORDER-LEFT-WIDTH: 0px; FONT-WEIGHT: normal; PADDING-TOP: 0px">.</SPAN>127  
ifconfig eth0 210.34.6.89 netmask 255.255.255.128 broadcast 210.34.6.127
  1. <SPAN style="LINE-HEIGHT: normal; FONT-FAMILY: Arial, Verdana, sans-serif; WHITE-SPACE: normal; COLOR: rgb(0,0,0)">该命令的作用是设置网卡eth0 的IP 地址,网络掩码和网络的本地广播地址。同样的方式可以用来配置eth1,eth2 等等,通常netmask 和broadcast 只要设置一个就可以了。</SPAN>  
该命令的作用是设置网卡eth0 的IP 地址,网络掩码和网络的本地广播地址。同样的方式可以用来配置eth1,eth2 等等,通常netmask 和broadcast 只要设置一个就可以了。

 

 

转自:http://linux.chinaitlab.com/command/801515.html

大幅度

转载于:https://www.cnblogs.com/xly1208/archive/2013/04/03/2997220.html

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/菜鸟追梦旅行/article/detail/479470
推荐阅读
相关标签
  

闽ICP备14008679号