Two Networks, Two NICs, Two Gateways...howto?
by JamesGT from LinuxQuestions.org on (#5AQ3E)
I have a server that has 2 network cards connected to two different networks.
I've configured rc.inet1.conf to have eth0 on a private network, and eth1 to be on a public network.
There is only one line "Default Gateway IP Address". Each network card has it's own gateway however.
How do I configure each card for each network?
I tried just adding lines to each card eth0 and eth1 as :
GATEWAY[0]="X.X.X.X" and GATEWAY[1]="1.1.1.1" but that doesn't seem to work.
If I change the default gateway line to the gateway IP for the public network, the public network works, but private does not.
If I change the default gateway line to the gateway IP for the private network, the public network does not work, but the private does.
How do you set up separate gateways for each network?
James


I've configured rc.inet1.conf to have eth0 on a private network, and eth1 to be on a public network.
There is only one line "Default Gateway IP Address". Each network card has it's own gateway however.
How do I configure each card for each network?
I tried just adding lines to each card eth0 and eth1 as :
GATEWAY[0]="X.X.X.X" and GATEWAY[1]="1.1.1.1" but that doesn't seem to work.
If I change the default gateway line to the gateway IP for the public network, the public network works, but private does not.
If I change the default gateway line to the gateway IP for the private network, the public network does not work, but the private does.
How do you set up separate gateways for each network?
James