FAQ Search Today's Posts Mark Forums Read
» Video Reviews

» Linux Archive

Linux-archive is a website aiming to archive linux email lists and to make them easily accessible for linux users/developers.


» Sponsor

» Partners

» Sponsor

Go Back   Linux Archive > Debian > Debian User

 
 
LinkBack Thread Tools
 
Old 10-06-2010, 02:10 PM
Camaleón
 
Default Setting up "dhclient" to get a fallback configuration

Hello,

I'm trying to setup a fallback configuration for "eth0" device when no
DHCP server is available in the local network. But I can't :-)

By reading the manual ("man dhclient"), it seems to be possible to define
an optional setup for that precise purpose:

***
(...) A mobile host which may sometimes need to access a network on which
no DHCP server exists may be preloaded with a lease for a fixed address
on that network. When all attempts to contact a DHCP server have
failed, dhclient will try to validate the static lease, and if it
succeeds, will use that lease until it is restarted.
***

So I edited "/etc/dhclient/dhclient.conf" and added:

***
lease {
interface "eth0";
fixed-address 172.16.0.66;
option subnet-mask 255.255.255.0;
option routers 172.16.0.1;
option domain-name-servers 80.58.0.33;
}
***

After restarting the network service, eth0 is not configured (it
defaults to APIPA address 169.254.x.x) and "syslog" tells:

***
Oct 6 07:24:29 debian dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 8
Oct 6 07:24:37 debian dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 16
Oct 6 07:24:53 debian dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 14
Oct 6 07:25:07 debian dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 21
Oct 6 07:25:28 debian dhclient: DHCPDISCOVER on eth0 to 255.255.255.255 port 67 interval 2
Oct 6 07:25:30 debian dhclient: No DHCPOFFERS received.
Oct 6 07:25:30 debian dhclient: No working leases in persistent database - sleeping.
***

What I am missing here?

Also, I turned on debugging in "/etc/dhcp/dhclient-enter-hooks.d/debug"
to gather additional data but I can only see a "FAIL" message and none
of the variables defined in the lease section of "dhclient.conf" are
being applied at all.

Any clue about how to get this working?

P.S. I'm running an up-to-date Squeeze but I've also tested within Lenny
and got the same results.

Greetings,

--
Camaleón


--
To UNSUBSCRIBE, email to debian-user-REQUEST@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster@lists.debian.org
Archive: pan.2010.10.06.14.10.39@gmail.com">http://lists.debian.org/pan.2010.10.06.14.10.39@gmail.com
 

Thread Tools




All times are GMT. The time now is 04:23 PM.

VBulletin, Copyright ©2000 - 2014, Jelsoft Enterprises Ltd.
Content Relevant URLs by vBSEO ©2007, Crawlability, Inc.
Copyright ©2007 - 2008, www.linux-archive.org