2

I would like to test 10Gig Ethernet serial interface by installing two NICs(Network Interface Cards) on a pc and pinging. I have the following questions:

1- Can two separate NICs be installed in one PC and have separate IP addresses (for pinging)?

2- Does this seem like a sensible approach to generate/check the data transferred over this interface?

[NIC card[1]

Hennes
  • 65,804
  • 7
  • 115
  • 169
Arash
  • 123

3 Answers3

4
  1. Yes

  2. Maybe. Depends on whether you get outsmarted by the OS. I have had issues in the past when trying to test FPGA designs that are connected via 10G ethernet to multiple NICs in one computer, and having all of my test packets get routed by the OS instead of going out on the wire (why is netperf going at 40G on a 10G NIC?!?).

alex.forencich
  • 649
  • 4
  • 7
3

1- Can two separate NICs be installed in one PC and have separate IPs

Yes. There is nothing special about multiple NICs in one system. I suspect it is even standard on allmost all servers, and both desktops setting next to me also have dual NICs (and soon a third, a pair of 10GBit NICs have been ordered).

The term for a computer with multiple NICs/IPs is "Multihomed"

2- Does this seem like a sensible approach to generate/check the data transferred over this interface?

No, dor several reasons.

  1. ICMP echo request (aka ping) is not a good test. Try to use something like iperf.
  2. Routing can get tricky. As can CPU usage. Best to split that cleanly into two systems.
  3. And, as Alex already mentioned. Sometimes the OS tries to be very smart. It is easier and more foolproof to test with two different computers.
Hennes
  • 65,804
  • 7
  • 115
  • 169
1

The problem is that the IP stacks in operating systems aren't designed to do this.

They are designed to support multiple adaptors to allow them to route between networks and/or to have a presense on multiple networks. Binding happens to addresses NOT to adaptors. If you bind to one local IP and try to ping another then the packets will never go out on the wire.

It may be possible to work around this with virtual machines or network namespaces or something but I expect it will be far easier to just use two seperate machines.

plugwash
  • 6,719