PDA

View Full Version : SLES 11 SP4 Adding NICs / Default Gateway



duwallace
01-Nov-2016, 13:23
SLES 11 SP4

Currently only have 1 NIC defined to my server and doing a route command shows that Default Gateway is associated with eth0. I configured 2 additional NICs with IPs in the same subnet as eth0, though when doing this the Default Gateway became associated with eth2. Is there a way like editing routes in /etc/sysconfig/network to indicatre eth0 is to be used for the Default Gateway?

All IPs use the same Gateway as they are in the same subnet and I do need traffic in and out for the IP on eth0 to use eth0 and the same for the other interfaces eth1 and eth2. Will this require "Split Access" setup with routing table and rules?

Thanks,
Duane

ab
01-Nov-2016, 14:12
Could you help me understand why you have multiple IPs on the same network
using different devices? There may be a great reason, but, in my
experience, it is usually not needed, or can be done better ways using
other technologies (bonding) to achieve business goals (higher throughput
to a box).

Other than that, you could use policy-based routing, I believe, to force
one NIC over another, but I think that's probably overkill. Linux is
pretty clever, so you may even find that if one NIC is down, another on
the same network will magically/automatically be used for data to the
target network. This gets really interesting in case like yours when the
kernel sees any addresses for the entire system as being on whatever
network device, though the details of that mess are eluding me right now.
Anyway, knowing more details of your business goals may help.

--
Good luck.

If you find this post helpful and are logged into the web interface,
show your appreciation and click on the star below...

duwallace
02-Nov-2016, 13:03
Could you help me understand why you have multiple IPs on the same network
using different devices?

The initial request was to have eth1 with an IP on a different subnet, the same as a group of print devices that this server will communicate with. eth2 was another interface for another server to communication on.

Master Server A is talking to Client A on eth0. Adding another NIC interfaces to Client A so that eth1 can be used so that Client A can talk to the print devices on eth1 and the Master Server A on etho to separate traffic.

So primarily trying to insure that Master Server talks to Client A on eth0 at IP of 10.0.0.19 and that printers and Client A communicate on eth1 at 10.0.0.82.Would add a route for printer network 10.10.10.0 /24 to use eth1.

Just when adding that next NIC the default gateway move to eth1 and I can no longer ping 10.0.0.19 from the Master A.

ab
02-Nov-2016, 14:04
I'm not positive, but I think I am correct in believing you can work
around this with the rp_filter (reverse path filter) setting via sysctl or
the /proc filesystem. See TID# 7007649
(https://www.suse.com/support/kb/doc?id=7007649) or RFC 3704
(https://www.ietf.org/rfc/rfc3704.txt) for more information.

--
Good luck.

If you find this post helpful and are logged into the web interface,
show your appreciation and click on the star below...