免费注册 查看新帖 |

Chinaunix

  平台 论坛 博客 文库
最近访问板块 发新帖
查看: 2887 | 回复: 9
打印 上一主题 下一主题

双网卡问题 [复制链接]

论坛徽章:
0
跳转到指定楼层
1 [收藏(0)] [报告]
发表于 2007-12-19 16:18 |只看该作者 |倒序浏览
10可用积分
OS : fedora 7  ||  CentOS 5.   
两块网卡 eth0  192.168.1.114           eth1 192.168.1.115        接在同一交换机上,gateway  192.168.1.1
Settings for eth0:
        Supported ports: [ TP MII ]
        Supported link modes:   10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
        Supports auto-negotiation: Yes
        Advertised link modes:  10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
        Advertised auto-negotiation: Yes
        Speed: 100Mb/s
        Duplex: Full
        Port: MII
        PHYAD: 32
        Transceiver: internal
        Auto-negotiation: on
        Supports Wake-on: pumbg
        Wake-on: d
        Current message level: 0x00000007 (7)
        Link detected: yes

Settings for eth1:
        Supported ports: [ TP MII ]
        Supported link modes:   10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
        Supports auto-negotiation: Yes
        Advertised link modes:  10baseT/Half 10baseT/Full
                                100baseT/Half 100baseT/Full
        Advertised auto-negotiation: Yes
        Speed: 100Mb/s
        Duplex: Full
        Port: MII
        PHYAD: 32
        Transceiver: internal
        Auto-negotiation: on
        Supports Wake-on: pumbg
        Wake-on: d
        Current message level: 0x00000007 (7)
        Link detected: yes

route  显示如下:
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.1.0     *               255.255.255.0   U     0      0        0 eth0
192.168.1.0     *               255.255.255.0   U     0      0        0 eth1
169.254.0.0     *               255.255.0.0     U     0      0        0 eth1
default         bogon           0.0.0.0         UG    0      0        0 eth0

发生现象如下:
拨网线:
        如果拨掉 eth1 的网线,局域网内的其它机器,仍然可以ping 通 eth0 ,eth1;
        如果拨掉的是eth0 的网线,则eth0,eth1,都ping 不通。
如果route显示顺序,eth1在最上面的话,则拨线 结果 刚好相反。

ifconfig XX down:
       如果将eth0 down掉,两块网卡 都可以 ping 通;
route如下:
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.1.0     *               255.255.255.0   U     0      0        0 eth1
169.254.0.0     *               255.255.0.0     U     0      0        0 eth1

    如果将 eth1 down掉,两块网卡都可以ping 通;
route 如下:
Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
192.168.1.0     *               255.255.255.0   U     0      0        0 eth0
default         bogon           0.0.0.0         UG    0      0        0 eth0


不解,谁给指条明路 ?

最佳答案

查看完整内容

关于这个问题的讨论在LINUX板块的网络问题版有很多讨论,自己搜一下吧。解决这个问题的方法就是BOND

论坛徽章:
5
IT运维版块每日发帖之星
日期:2015-08-06 06:20:00IT运维版块每日发帖之星
日期:2015-08-10 06:20:00IT运维版块每日发帖之星
日期:2015-08-23 06:20:00IT运维版块每日发帖之星
日期:2015-08-24 06:20:00IT运维版块每日发帖之星
日期:2015-11-12 06:20:00
2 [报告]
发表于 2007-12-19 16:18 |只看该作者
关于这个问题的讨论在LINUX板块的网络问题版有很多讨论,自己搜一下吧。
解决这个问题的方法就是BOND

论坛徽章:
0
3 [报告]
发表于 2007-12-19 20:26 |只看该作者
有巨侠没有

论坛徽章:
0
4 [报告]
发表于 2007-12-19 20:52 |只看该作者
正常模式下两块网卡配置相同的网段,就可能发生很多异常问题。。。

好像你作的正是这么做的。。。

论坛徽章:
0
5 [报告]
发表于 2007-12-19 23:07 |只看该作者
太神了吧~~
你把eth1的网线拔了~那eth1的端口都是down的啊~根本就没起来
会不会不是网络方面的问题 是系统的某种机制导致的?

论坛徽章:
0
6 [报告]
发表于 2007-12-19 23:20 |只看该作者
其实我想知道你要达到的是什么效果呢!?

论坛徽章:
0
7 [报告]
发表于 2007-12-20 00:27 |只看该作者
想达到两块负载均衡,和冗余。如果一块 拨了,由程序切换到另一块执行。
结果出了这样的事,我很苦恼。

论坛徽章:
0
8 [报告]
发表于 2007-12-20 13:23 |只看该作者
提示: 作者被禁止或删除 内容自动屏蔽

论坛徽章:
0
9 [报告]
发表于 2007-12-20 14:34 |只看该作者
谢谢大家关注 ,找到办法了。可以把两块网卡绑定。

论坛徽章:
0
10 [报告]
发表于 2007-12-20 14:37 |只看该作者
就此结贴
您需要登录后才可以回帖 登录 | 注册

本版积分规则 发表回复

  

北京盛拓优讯信息技术有限公司. 版权所有 京ICP备16024965号-6 北京市公安局海淀分局网监中心备案编号:11010802020122 niuxiaotong@pcpop.com 17352615567
未成年举报专区
中国互联网协会会员  联系我们:huangweiwei@itpub.net
感谢所有关心和支持过ChinaUnix的朋友们 转载本站内容请注明原作者名及出处

清除 Cookies - ChinaUnix - Archiver - WAP - TOP