[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: nslu2: two devices: one by default

En/na Lennart Sorensen ha escrit:
On Mon, Nov 02, 2009 at 09:56:10PM +0100, Xan wrote:
En/na Lennart Sorensen ha escrit:

Other than patching the kernel to change the behaviour to be more router
like though, about the best you can do is have a cron job or daemon
check the link state, and delete the route if the link goes down, and
add it back when the link returns.  I consider that ugly and fragile
How to do this script? How to test if one device is down?

'ethtool' or 'ip link' should be able to tell you if a link is up or down.
A clever tool would subscribe to netlink and get notifications of link
state changes, but that probably isn't necesary.

Thanks a lot. I have enougth with ip link ;-)


Reply to: