LinuxQuestions.org
Visit Jeremy's Blog.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices


Reply
  Search this Thread
Old 10-12-2020, 03:26 AM   #1
anctop
Member
 
Registered: Feb 2010
Posts: 101

Rep: Reputation: Disabled
config problem with dual NIC mainboard


Hi,

I encounter a problem in network configuration for an Intel S3420GPV mainboard.
The board is equipped with two NIC's.
Logically they should work independent of each other, but I find that it is indeed not the case.

Here are the steps I've followed:

1. Before starting, all patch cables are disconnected.

2. Booting system with Slackware64-14.2 distribution (huge.s/bzImage + initrd.img).
The devices "eth0" (MAC xx:xx:xx:xx:xx:47) & "eth1" (MAC xx:xx:xx:xx:xx:46) are up.

3. At the root prompt, configure "eth1" with the command
Code:
ifconfig -v eth1 aaa.bbb.ccc.29 broadcast aaa.bbb.ccc.255 netmask 255.255.255.0
Code:
eth1      Link encap:Ethernet  HWaddr xx:xx:xx:xx:xx:46
          inet addr:aaa.bbb.ccc.29  Bcast:aaa.bbb.ccc.255  Mask:255.255.255.0
          UP BROADCAST MULTICAST  MTU:1500  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:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:16 Memory:b1100000-b1120000
4. Connect system to network via the external connector corresponding to "eth1".
Ping from another node on the same subnet has no problem :
Code:
PING aaa.bbb.ccc.29 (aaa.bbb.ccc.29): 56 data bytes
64 bytes from aaa.bbb.ccc.29: icmp_seq=0 ttl=64 time=0.372 ms
5. Detach the patch cable from "eth1".

6. Configure "eth0" with the command
Code:
ifconfig -v eth0 aaa.bbb.ccc.129 broadcast aaa.bbb.ccc.255 netmask 255.255.255.0
Code:
eth0      Link encap:Ethernet  HWaddr xx:xx:xx:xx:xx:47
          inet addr:aaa.bbb.ccc.129  Bcast:aaa.bbb.ccc.255  Mask:255.255.255.0
          UP BROADCAST MULTICAST  MTU:1500  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:1000
          RX bytes:0 (0.0 B)  TX bytes:0 (0.0 B)
          Interrupt:16 Memory:b1100000-b1120000
7. Connect system to network via the external connector corresponding to "eth0".
Ping from another node on the same subnet fails :
Code:
PING aaa.bbb.ccc.129 (aaa.bbb.ccc.129): 56 data bytes
--- aaa.bbb.ccc.129 ping statistics ---
158 packets transmitted, 0 packets received, 100% packet loss
8. Detach cable from "eth0" and insert it to "eth1", then ping both IP's are successful.

The experiment has been repeated with the order of configuration reversed, the result is reversed accordingly.

It seems that only the interface configured first is functional, the functionality of the other interface is somehow bound to the first one.

I don't think this is normal, but can't find a fix from web search.

Could someone kindly help ?
 
Old 10-12-2020, 09:57 PM   #2
computersavvy
Senior Member
 
Registered: Aug 2016
Posts: 3,345

Rep: Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486
Quote:
Originally Posted by anctop View Post
Hi,

I encounter a problem in network configuration for an Intel S3420GPV mainboard.
The board is equipped with two NIC's.
Logically they should work independent of each other, but I find that it is indeed not the case.

.......

8. Detach cable from "eth0" and insert it to "eth1", then ping both IP's are successful.

The experiment has been repeated with the order of configuration reversed, the result is reversed accordingly.

It seems that only the interface configured first is functional, the functionality of the other interface is somehow bound to the first one.

I don't think this is normal, but can't find a fix from web search.

Could someone kindly help ?
This doesn't seem right. You just said that the cable is detached from eth0 and attached to eth1 and both IPs are available ????
That would imply that eth0 is configured as an alias for eth1 and both are on the same physical nic.

At some time in the past I used aliases on single nics to have multiple IPs and it seems you may be doing the same unintentionally.

Last edited by computersavvy; 10-12-2020 at 09:59 PM.
 
Old 10-13-2020, 07:27 PM   #3
anctop
Member
 
Registered: Feb 2010
Posts: 101

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by computersavvy View Post
This doesn't seem right. You just said that the cable is detached from eth0 and attached to eth1 and both IPs are available ????
That would imply that eth0 is configured as an alias for eth1 and both are on the same physical nic.

At some time in the past I used aliases on single nics to have multiple IPs and it seems you may be doing the same unintentionally.
I understand this possibility, therefore I performed the experiment in a "live-cd" environment such that all network configurations are empty.

When the patch cable is inserted into a connector, the status of the corresponding interface changes to "RUNNING" and "RX packets" starts counting. Everything works as expected until it is pinged.

I have also reloaded BIOS to system defaults, but it does not help either.
 
Old 10-14-2020, 04:43 PM   #4
computersavvy
Senior Member
 
Registered: Aug 2016
Posts: 3,345

Rep: Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486
Quote:
Originally Posted by anctop View Post
I understand this possibility, therefore I performed the experiment in a "live-cd" environment such that all network configurations are empty.

When the patch cable is inserted into a connector, the status of the corresponding interface changes to "RUNNING" and "RX packets" starts counting. Everything works as expected until it is pinged.

I have also reloaded BIOS to system defaults, but it does not help either.
So have you tried the ping with only one cable attached, both from the local machine and from outside? if that works then the interface is functioning.

repeat the test with the other interface.

I guess it might be possible that the mobo is designed such that those ports are actually a single interface with 2 physical connections but that does not seem a reasonable design.

You might try looking at the ifcfg file for each port in /etc/sysconfig/network-scripts (that is the path for fedora) and see what is there. Each interface should have its own independent ifcfg-interfacename file and each should point to the appropriate interface in the line that begins with DEVICE=. Another thing you might check (since I am just thinking and getting ideas out of the blue) would be how the interface gets its address. Is it DHCP? or static. That would also show in the ifcfg file as BOOTPROTO=?

My wifi shows as
Code:
wlo1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST>  mtu 1500
        inet 192.168.2.112  netmask 255.255.255.0  broadcast 192.168.2.255
        inet6 fe80::82a7:aca4:2078:a619  prefixlen 64  scopeid 0x20<link>
        ether 48:89:e7:c7:51:ff  txqueuelen 1000  (Ethernet)
        RX packets 490853  bytes 660343920 (629.7 MiB)
        RX errors 0  dropped 0  overruns 0  frame 0
        TX packets 218834  bytes 23352390 (22.2 MiB)
        TX errors 0  dropped 0 overruns 0  carrier 0  collisions 0
and I can see the IP config (inet) as well as the associated MAC (ether) address. Wired connections show similarly.

Try ifconfig with both interfaces connected and active. Each interface should have a stanza similar to the above. If both interfaces show as discrete interfaces with the appropriate MAC addresses and IPs, and they are both active then I can see no reason for the behavior you describe.

Last edited by computersavvy; 10-14-2020 at 04:47 PM.
 
Old 10-14-2020, 09:54 PM   #5
anctop
Member
 
Registered: Feb 2010
Posts: 101

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by computersavvy View Post
So have you tried the ping with only one cable attached, both from the local machine and from outside? if that works then the interface is functioning.

repeat the test with the other interface.

I guess it might be possible that the mobo is designed such that those ports are actually a single interface with 2 physical connections but that does not seem a reasonable design.

You might try looking at the ifcfg file for each port in /etc/sysconfig/network-scripts (that is the path for fedora) and see what is there. Each interface should have its own independent ifcfg-interfacename file and each should point to the appropriate interface in the line that begins with DEVICE=. Another thing you might check (since I am just thinking and getting ideas out of the blue) would be how the interface gets its address. Is it DHCP? or static. That would also show in the ifcfg file as BOOTPROTO=?

My wifi shows as
....
and I can see the IP config (inet) as well as the associated MAC (ether) address. Wired connections show similarly.

Try ifconfig with both interfaces connected and active. Each interface should have a stanza similar to the above. If both interfaces show as discrete interfaces with the appropriate MAC addresses and IPs, and they are both active then I can see no reason for the behavior you describe.
From the very beginning, only one cable is used.

As shown in my original post, the interfaces are configured with static IP addresses in the same subnet.

The outputs of "ifconfig" show correct MAC & IP values. The weirdness appears when the interfaces are pinged.

In the mainboard reference manual, the NIC's are described as :
  • Gigabit Ethernet device 82574L connect to PCI-E x1 interfaces on the PCH
  • Gigabit Ethernet PHY 82578DM connected to PCH through PCI-E x1 interface
Both use the "e1000e" kernel driver.
 
Old 10-15-2020, 03:40 AM   #6
Shadow_7
Senior Member
 
Registered: Feb 2003
Distribution: debian
Posts: 4,137
Blog Entries: 1

Rep: Reputation: 875Reputation: 875Reputation: 875Reputation: 875Reputation: 875Reputation: 875Reputation: 875
$ ip link show
$ ip addr show
$ ip route show

The ifconfig route has kind of been deprecated a while now. You might need a second route for the other port. I tend to put multiple ethernets on separate subnets. With a router or bridge computer to make them communicate.

# ip route add 192.168.7.0/24 via 192.168.2.5 dev eth0

In my case to make that bridge happen. In addition to the default route for interwebs.

# ip route add default via 192.168.2.1 dev eth0

In my case I have switches/routers with only 5 ports, and I wanted my pulseaudio/storage networking on an interface other than that that goes to the internet. The internet switch is 10/100, the storage one is gigabit.
 
Old 10-16-2020, 01:56 AM   #7
anctop
Member
 
Registered: Feb 2010
Posts: 101

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by Shadow_7 View Post
$ ip link show
$ ip addr show
$ ip route show

The ifconfig route has kind of been deprecated a while now. You might need a second route for the other port. I tend to put multiple ethernets on separate subnets. With a router or bridge computer to make them communicate.

# ip route add 192.168.7.0/24 via 192.168.2.5 dev eth0

In my case to make that bridge happen. In addition to the default route for interwebs.

# ip route add default via 192.168.2.1 dev eth0

In my case I have switches/routers with only 5 ports, and I wanted my pulseaudio/storage networking on an interface other than that that goes to the internet. The internet switch is 10/100, the storage one is gigabit.
Having executed the "ifconfig" commands as described in my original post, the patch cable is inserted in the connector of "eth1" only.

"ip addr show" outputs
Code:
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue qlen 1
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
2: eth0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc pfifo_fast qlen 1000
    link/ether xx:xx:xx:xx:xx:47 brd ff:ff:ff:ff:ff:ff
    inet aaa.bbb.ccc.129/24 brd aaa.bbb.ccc.255 scope global eth0
       valid_lft forever preferred_lft forever
3: eth1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast qlen 1000
    link/ether xx:xx:xx:xx:xx:46 brd ff:ff:ff:ff:ff:ff
    inet aaa.bbb.ccc.29/24 brd aaa.bbb.ccc.255 scope global eth1
       valid_lft forever preferred_lft forever
"ip route show" outputs
Code:
127.0.0.0/8 dev lo
aaa.bbb.ccc.0/24 dev eth1  src aaa.bbb.ccc.29
aaa.bbb.ccc.0/24 dev eth0  src aaa.bbb.ccc.129
 
Old 10-16-2020, 04:34 AM   #8
Shadow_7
Senior Member
 
Registered: Feb 2003
Distribution: debian
Posts: 4,137
Blog Entries: 1

Rep: Reputation: 875Reputation: 875Reputation: 875Reputation: 875Reputation: 875Reputation: 875Reputation: 875
assuming aaa.bbb.ccc are the same for both nics. It could be that one IP is already in use by another machine, if only in passing and that has locked it's use. Until one or both machines have been rebooted, or the offending NIC up/down via modprobe or otherwise. Or you use a different IP not previously used by any other NICs.
 
Old 10-16-2020, 04:13 PM   #9
computersavvy
Senior Member
 
Registered: Aug 2016
Posts: 3,345

Rep: Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486
Ah, this is a major issue

Code:
"ip route show" outputs

aaa.bbb.ccc.0/24 dev eth1  src aaa.bbb.ccc.29
aaa.bbb.ccc.0/24 dev eth0  src aaa.bbb.ccc.129
The route from the machine to the local LAN can go via either port so what goes in one port/address can be sent back on the other port where there is no established connection and the reply is lost. This is one of the reasons having 2 nics on the same machine on the same subnet is discouraged if not totally banned by most admins.

In detail, what this means is that the remote host sends a ping (UDP) to a specific IP (MAC address). That machine is allowed to send the reply via the other interface with a different IP & MAC so the originating host does not recognize the reply. It is even worse with attempting to establish TCP communications.

I would bet your issue goes away if you delete the config on one of the ports (or disable that port) so only one has an address on the local subnet. If you definitely need two addresses on the same subnet then using an alias so you have 2 IPs on one port and careful configurations would work.
When I worked at an ISP our web server had multiple local IPs on one port with each hosted web domain listening on its own IP so the reply hostname matched the expected domain name.

Using the second port on a different subnet and judiciously establishing routing would also work nicely.

Last edited by computersavvy; 10-16-2020 at 04:25 PM.
 
1 members found this post helpful.
Old 10-18-2020, 08:30 PM   #10
anctop
Member
 
Registered: Feb 2010
Posts: 101

Original Poster
Rep: Reputation: Disabled
Quote:
Originally Posted by computersavvy View Post
Ah, this is a major issue

Code:
"ip route show" outputs

aaa.bbb.ccc.0/24 dev eth1  src aaa.bbb.ccc.29
aaa.bbb.ccc.0/24 dev eth0  src aaa.bbb.ccc.129
The route from the machine to the local LAN can go via either port so what goes in one port/address can be sent back on the other port where there is no established connection and the reply is lost. This is one of the reasons having 2 nics on the same machine on the same subnet is discouraged if not totally banned by most admins.

In detail, what this means is that the remote host sends a ping (UDP) to a specific IP (MAC address). That machine is allowed to send the reply via the other interface with a different IP & MAC so the originating host does not recognize the reply. It is even worse with attempting to establish TCP communications.

I would bet your issue goes away if you delete the config on one of the ports (or disable that port) so only one has an address on the local subnet. If you definitely need two addresses on the same subnet then using an alias so you have 2 IPs on one port and careful configurations would work.
When I worked at an ISP our web server had multiple local IPs on one port with each hosted web domain listening on its own IP so the reply hostname matched the expected domain name.

Using the second port on a different subnet and judiciously establishing routing would also work nicely.
Thank you computersavvy for your exposition.

When the patch cable is at "eth1", "ping aaa.bbb.ccc.29" is successful.
When the patch cable is switched to "eth0", "ping aaa.bbb.ccc.129" fails.
After "ifconfig eth1 down", then "ping aaa.bbb.ccc.129" works immediately.

I think the abnormality should have been explained adequately.

Thanks again for all replies.
 
Old 10-18-2020, 08:43 PM   #11
computersavvy
Senior Member
 
Registered: Aug 2016
Posts: 3,345

Rep: Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486Reputation: 1486
Quote:
Originally Posted by anctop View Post
Thank you computersavvy for your exposition.

When the patch cable is at "eth1", "ping aaa.bbb.ccc.29" is successful.
When the patch cable is switched to "eth0", "ping aaa.bbb.ccc.129" fails.
After "ifconfig eth1 down", then "ping aaa.bbb.ccc.129" works immediately.

I think the abnormality should have been explained adequately.

Thanks again for all replies.
My reply above still is valid and your response bears it out. As soon as you no longer have 2 distinct NICs active on the same subnet ping works as expected.

Glad to be of assistance.

Last edited by computersavvy; 10-18-2020 at 08:47 PM.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Which config: config.amd64-none_amd64 OR config.amd64_rt_amd64 mzsade Debian 2 11-27-2016 09:19 PM
[SOLVED] NVidia problem on P4I45GV mainboard dracuss Linux - Hardware 13 05-29-2009 01:25 PM
Problem after changing Mainboard quanbn Linux - Server 1 12-11-2008 08:36 AM
VMware server - Virtual NIC wont work after mainboard has been replaced dbmacartney Linux - Server 1 04-15-2008 04:49 AM
Binding named to only one NIC of a dual NIC machine - possible? Paul_Randle Linux - Networking 3 08-24-2005 08:44 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware

All times are GMT -5. The time now is 04:40 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Open Source Consulting | Domain Registration