Routing table per NIC on a multihomed linux host

routing

I have a client application, that needs 5 9's availability. To provide redundancy at the NIC level, it sounds good in theory if the linux host can have 2 NIC cards, both configured to use different gateways. Thus in a diagram it would look like

Client A->NIC1————->Gateway1————> Server

Client A->NIC2————->Gateway2————->Server

This would ensure that if Gateway 1 crashes, client A can still reach Server via Gateway 2

My questions are:-

Can the 2 NICs on the same host be configured with different gateways?
Can NIC1 in the above diagram be configured with a backup gateway2, so that if gateway 1 crashes, NIC1 can use backup gateway2.
If above are possible, what would the configuration within linux files look like?

Best Answer

Nope, bad idea. Provide redundancy at each level. Use LACP/Aggregation at the NIC level. Use HSRP or CARP at the gateway. Each gateway should have it's own set of redundant NICs. The network in between should have redudant segments (switches or whatever your network is composed of). Each piece along the way should have redundancy, not just two redundant paths.

High availability like you're requesting is extremely difficult. Get someone who knows this stuff inside and out or you'll never hit 5 nines. That's ~5 minutes of downtime per year. It's much harder than it sounds.

Related Topic