LinuxSir.cn,穿越时空的Linuxsir!

 找回密码
 注册
搜索
热搜: shell linux mysql
查看: 837|回复: 9

双网卡问题?烦我好久了!!!

[复制链接]
发表于 2004-10-27 16:01:41 | 显示全部楼层 |阅读模式
我有两台机子a和b。a上装有xp和fc2,并装双网卡。b机上系统是rh9,只装一网卡直接与a机相连。若a机上只装其中任一网卡时都可正常与b机互连;但在a机是同时装上两个网卡后问题就出现了:插在里面ide糟上(相对于另外那个网卡)的那个网卡可正常与b机互连,这时把网线换插在外面点的那个网卡上,就不能与b机正常互连了,我把a机上的两个网卡互换后问题还是一样的,还是里面点的那个网卡可正常连接,外面的那个还是不行的。
但在xp系统上一切都是正常的。
那位高人能帮在下解决这个问题,那真是感激不尽!!!
 楼主| 发表于 2004-10-28 02:29:55 | 显示全部楼层
自己再顶一下。
发表于 2004-10-28 03:04:50 | 显示全部楼层
ide糟???
应该是pci槽吧?
我看应该是route的问题,linux通过网卡不同的位置识别为eth0和eth1
在你的路由表里,应该有default路由,使用#route列一下。
发表于 2004-10-28 08:34:54 | 显示全部楼层
首先确认是否已经识别出第二块网卡:
ifconfig -a
 楼主| 发表于 2004-10-29 00:32:22 | 显示全部楼层
#route后的是这样的:
[root@localhost root]# route
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
10.0.0.0        *               255.255.255.0   U     0      0        0 eth1
192.168.10.0    *               255.255.255.0   U     0      0        0 eth0
169.254.0.0     *               255.255.0.0     U     0      0        0 eth1
default         192.168.10.200  0.0.0.0         UG    0      0        0 eth0
 楼主| 发表于 2004-10-29 00:34:30 | 显示全部楼层
[root@localhost root]# ifconfig -a
eth0      Link encap:Ethernet  HWaddr 00:0A:EB:07:78:5E
          inet addr:192.168.10.111  Bcast:192.168.10.255  Mask:255.255.255.0
          inet6 addr: fe80::20a:ebff:fe07:785e/64 Scopeink
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:366 errors:0 dropped:0 overruns:0 frame:0
          TX packets:2604 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:203503 (198.7 Kb)  TX bytes:176857 (172.7 Kb)
          Interrupt:11 Base address:0xc000

eth1      Link encap:Ethernet  HWaddr 00:50:BF:62:4B:60
          inet addr:10.0.0.1  Bcast:10.0.0.255  Mask:255.255.255.0
          inet6 addr: fe80::250:bfff:fe62:4b60/64 Scopeink
          UP BROADCAST RUNNING MULTICAST  MTU:1500  Metric:1
          RX packets:1776 errors:0 dropped:0 overruns:0 frame:0
          TX packets:1709 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:1000
          RX bytes:109416 (106.8 Kb)  TX bytes:103748 (101.3 Kb)
          Interrupt:5 Base address:0xc400

lo        Link encapocal Loopback
          inet addr:127.0.0.1  Mask:255.0.0.0
          inet6 addr: ::1/128 Scope:Host
          UP LOOPBACK RUNNING  MTU:16436  Metric:1
          RX packets:2627 errors:0 dropped:0 overruns:0 frame:0
          TX packets:2627 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:2997784 (2.8 Mb)  TX bytes:2997784 (2.8 Mb)

sit0      Link encap:IPv6-in-IPv4
          NOARP  MTU:1480  Metric:1
          RX packets:0 errors:0 dropped:0 overruns:0 frame:0
          TX packets:0 errors:0 dropped:0 overruns:0 carrier:0
          collisions:0 txqueuelen:0
          RX bytes:0 (0.0 b)  TX bytes:0 (0.0 b)
发表于 2004-10-29 08:34:29 | 显示全部楼层
路由表有些问题:
169。。。那行,接口卡应该是lo
删除它:route del -net 169。。。

其它看起来很正常呀!
如果还不行,有能你把接口卡搞错了,把b机接到另一块网卡上试一试。
另:你b机ip是什么呀?
 楼主| 发表于 2004-10-29 13:36:38 | 显示全部楼层
b机的ip是10.0.0.9;a机另外一个网卡现接在交换机上,可正常上英特网。我试过,如果另外的网卡ip改成10.0.0.1的话是可以正常和b机互连的。
[root@localhost root]# route del -net 169.254.0.0
SIOCDELRT: 鏃犳晥鐨勫?傛?
好像无法删除。
 楼主| 发表于 2004-11-24 22:19:39 | 显示全部楼层
问题解决一半了,在把“安全级别”重设了一下(什么都没改),就可以用第二个网卡了,ping得到另外一台机子了!!!但总这样也太麻烦了啊!?因为重启一次机子就得重做这个步骤一下啊!因为我以为把防火墙关掉就可了,没想到还是不行。
发表于 2004-11-24 23:00:25 | 显示全部楼层
用iptables-save命令检查防火墙规则。或者用:
service iptables stop
关掉防火墙试一试。
您需要登录后才可以回帖 登录 | 注册

本版积分规则

快速回复 返回顶部 返回列表