Find the answer to your Linux question:
Results 1 to 5 of 5
Hi, I have a Debian computer with 2 network interfaces. Ath0 for wifi and eth0 for cable. They're configured as dhcp and are getting their ip from different routers. When ...
Enjoy an ad free experience by logging in. Not a member yet? Register.
  1. #1
    Just Joined!
    Join Date
    May 2009
    Posts
    72

    Debian networking disabling interface when router is down


    Hi,

    I have a Debian computer with 2 network interfaces. Ath0 for wifi and eth0 for cable.
    They're configured as dhcp and are getting their ip from different routers.
    When I shut down one of the router, it takes 5 minutes for the ip address to "Go away". I would like this to take a shorter time. I figured it must be a setting, but my attempts so far have been unsuccessfull. Is there a way to do this?

    I'm using dhcp3-client (dhclient) as my client.

    Thanks.

  2. #2
    Just Joined!
    Join Date
    Mar 2009
    Location
    Norway
    Posts
    67
    Look at the ttl in the DHCP-offer from the router. If your system does not need to renew the IP, it won't "go away" before the lease expires and it tries to renew it.

    See if you can access the admin-console on the router and change the lease-time there.

  3. #3
    Just Joined!
    Join Date
    May 2009
    Posts
    72
    Don't see any ttl mention on my system.
    According to the lease file the lease time is 24 hours and the renew time is about 13 hours from now.

    I'll see if I can change the lease time on the router.

    Thanks for the help.

  4. #4
    Just Joined!
    Join Date
    Aug 2006
    Posts
    3
    Most routers do have a setting for the DHCP lease time, but another possible way to do it is to go to the DHCP table on the router that talks to that particular interface and remove the entry for the computer in question, then try to renew the lease on the interface.

    Hope that helps

  5. #5
    Just Joined!
    Join Date
    May 2009
    Posts
    72
    Thanks for the info, I'll see if it helps.
    I most likely won't have access to the router settings on my live environment, but at least now I'll know how it works. It's not really that big of a deal. I just wanted the routes to go away when an Interface is not in a network range but I'll reconfigure my routes so that it won't be a problem.

    Thanks all for your help.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •