(E-Mail Removed) (David) writes:
>Is it possible to have a second default route in linux? We are
>looking to have a backup default gateway (with another internet
>service) just in case the first fails.
>However, I am unsure if the use of metrics would work as a secondary
>gateway, and what would tell the unix box the first gateway was down?
>Is there a script that would ping the first gateway, then switch to
>the new gateway? If so, does it exist now and where so that I may
>modify it for our purposes?
Look at the Advanced Routing HowTo.
Particularly about "ip route equalize".
I used this to split bandwidth by round-robin on two
separate DSL lines. Very cool.
HOWEVER, true failover would involve having agreed upon
protocols for the routers to heartbeat each other. Which does
not currently exist AFAIK in a standardized protocol. If you
are going Cisco-to-Cisco or Linux-to-Linux fine, otherwise SOL.
You can kludge something together with a cron job that pings
the nearest gateways, but it's a kludge. And when your cron
job mistakenly shuts both down you will be SOL.
I was happy enough just doing it manually. They would call me
that "somethings' wrong with the net!" and I'd login remotely to
the Linux gateway via whichever DSL was still up, and do an
ifconfig down on the other/dead one. That's really all you have to
do is down the dead interface and ip route will then send all
traffic to the remaining one that is up.
--
Vincent Fox
Georgia Institute of Technology, Atlanta Georgia, 30332
uucp: ...!{decvax,hplabs,ncar,purdue,rutgers}!gatech!pri sm!vf5
Internet:
(E-Mail Removed)