Hi all, I have a site with two Internet connections, each with it's own leaf router. One of the routers is the default gateway and provides dns and dhcp services, the other just provides external dns and port forwarding for incoming email mainly. What I'd like to do is set something up so if the main router goes down, the other one will detect it and activate dhcp and dns services and make itself the default gateway.
I've been thinking about a script that will use ping to detect if the main router goes down, and automatically start the needed services. That part should be trivial, but what I need is a way to detect that the main router came back online and shutdown these services. Or perhaps even better, have the main router detect that the other router is now the default gateway and not start it's dhcp/dns services. I'm not quite sure how to go about doing this. Has someone already set something like this up? Is there a way to provide some sort of communications between routers? I'm thinking all that would be needed is a way to get each router to ask the other if it's the 'master' periodically (and during boot). If it doesn't get an answer or if it gets an answer indicating it is the master, then it could run a script to make it the master, if it isn't already. Otherwise it would make sure it wasn't running the dhcp/dns services. Of course, an even better solution would be to have both routers running dhcp/dns that work together and sync their data. Is there a way to get dnsmasq to communicate with a peer? Any thoughts on either solution? ...Izzy ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ ------------------------------------------------------------------------ leaf-user mailing list: leaf-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/leaf-user Support Request -- http://leaf-project.org/