Documentation for dhclient.
stman937-dhcp at hotmail.com
Wed May 11 19:53:21 UTC 2011
Thanks to all who explained -r -x.
> What version of dhcp do you use? Are you sure it's not some old release?
% dhclient --helpInternet Systems Consortium DHCP Client V3.1.3Copyright 2004-2009 Internet Systems Consortium.All rights reserved.For info, please visit https://www.isc.org/software/dhcp/Usage: dhclient [-1dqrx] [-nw] [-p <port>] [-s server] [-cf config-file] [-lf lease-file][-pf pid-file] [-e VAR=val] [-sf script-file] [interface]
and the man page states:
" The -r flag explicitly releases the current lease, and once the lease has been released, the client exits.
If the client is killed by a signal (for example at shutdown or reboot) it won't execute the dhclient-script (8) at exit. However if you shut the client down gracefully with -r or -x it will execute dhclient-script (8) at shutdown with the specific reason for calling the script set."
I know it is not the scope of this mailing list but here is my problem:
I was given, for my work a work-station loaded with Ubuntu 10.4. I do embedded work and I need a plain server. So I started by stopping Gnome and I switched from DHCP to static IP. I did modify the /etc/network/interfaces to switch from dynamic to static and I restarted the network. All fine I'm in static IP.After some time I notice my server is back to DHCP mode. Did some search and noted the dhclient was stillalive. On a normal Unix system restarting the network solves this problem. Not with Ubuntu! Try the man pageto stop it. Not enough info. Search the /etc/init.d scripts for clues. Nothing! Search the Ubuntu groups and found lots of people having the same problem. NO solution to the problem. The most common work-around is to uninstall dhclient or to rename it. I know Ubuntu is not Unix - but this is too much of Windoze approach.So I started to dig (on my time) for some reasonable and technically correct solution. I found the Ubuntu network-manager is the culprit for restarting dhclient. I removed it. Now I am in the phase of adding some code to /etc/init.d/networking script to properly stop the dhclient when the IP is set to static. I wasn't surewhich -r or -x to use. Hence my request.
Sorry for the long story and thanks for the lights!
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the dhcp-users