I deployed a VMware vCloud appliance and before deployment I'm asked to enter the IP addresses this appliance should use and the default gateway. This appliance has 2 IP addresses and nics by default and they should be in the same subnet.

So the info I entered was: for eth0 for eth1 Default gateway is

Now I run into a strange issue. When I ping both IP addresses from a computer in the same subnet, all is fine. When I ping from a computer in a different subnet, I only get a reply from the address (eth1). When I login to the appliance I can ping the computer in the same subnet as well as the computer in the different subnet.

The network guys have assured me there is no firewall blocking this traffic.

Not sure where it is going wrong. I was thinking maybe the routing table is incorrect? Shouldn't there be only one "default" destination? But then again, I would expect traffic coming in on eth0 or eth1, to also leave over the same interface it arrived, or is that not a correct assumption?

Kernel IP routing table
Destination     Gateway         Genmask         Flags Metric Ref    Use Iface
default         UG    0      0        0 eth1
default         UG    0      0        0 eth0      *        U     0      0        0 eth1      *        U     0      0        0 eth0

Any clues where to look for?

  • Each interface is going to have a full IP configuration, the individual interfaces don't recognize that another interface exists. So far as the interface is concerned, there is no other interface. – Davidw Jun 12 at 6:44
  • So, this config looks good? – Gabrie Jun 12 at 6:49
  • For IP addresses and with /24 the default gateway should be makes no sense for – Overmind Jun 12 at 7:20
  • 1
    @Overmind That comment doesn't make sense. The gateway can be whatever IP in the subnet you want it to be. – Frederik Nielsen Jun 12 at 7:46
  • 1
    @Overmind I have maintained many subnets over the years, also many where the gateway was on another IP than .1 and they all worked just fine so what you are saying is absolutely untrue :) – Frederik Nielsen Jun 12 at 8:13

In the same sub-net both IPs will be reachable with no routing necessary.

From a different sub-net, you will need working routing for things to work. In your case, the default routing goes through eth1.

If you want to simply make routing prioritize eth0 instead, you can use routing tables to accomplish that or simply give a lower metric to the desired interface. In both cases, you will have routing toward the desired interface.

You can also add rules to determine which table is used for what::

  • create two routing tables, one for each NIC
  • add routes for each interface to the appropriate tables
  • add rules to determine which table is used

This should keep traffic from crossing NICs internally, allowing you to preserve redundancy or use each NIC for different functionality.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.