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

Re: dhcp not starting since a couple of days



H. S. wrote:

Hi,

DHCP seems to be giving some problems since a couple of days.

The problem started when I noticed that it wasn't starting on boot up and I was getting this in my syslog file:
#--------------------------------------------
dhcpd: No subnet declaration for eth1 (192.168.1.1).
dhcpd: Please write a subnet declaration in your dhcpd.conf file for the
dhcpd: network segment to which interface eth1 is attached.
dhcpd: exiting.
#--------------------------------------------

I found that after running an update last night, my laptop network interfaces changed this morning. eth0 used to be the firewire interface, and eth1 was the network. This morning, they are the opposite.

...

So basically, if I start dhcp from it's /etc/init.d/dhcp script, it doesn't work. But if I start dhcpd from command line, it does.

The file /etc/default/dhcp has a list of interfaces in it that DHCP should run on. This file is used by /etc/init.d/dhcp. When you start dhcpd manually, it doesn't use this file, so starts and runs on all interfaces by default. When you use /etc/init.d/dhcp, it DOES use /etc/default/dhcp, so only starts on the interfaces listed there. Because the interface ordering has changed, this is probably pointing to the wrong interface. So edit /etc/default/dhcp and make sure it's pointing at the right interface.



Reply to: