LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   I have a problem to start my dhcp server in ubuntu 12.04 (https://www.linuxquestions.org/questions/linux-newbie-8/i-have-a-problem-to-start-my-dhcp-server-in-ubuntu-12-04-a-4175601562/)

agnes222 03-11-2017 05:27 PM

I have a problem to start my dhcp server in ubuntu 12.04
 
There are my configuration:

sudo apt-get install isc-dhcp-server
// The installation is successfull
nano /etc/network/interfaces
auto eth0
iface eth0 inet static
address 192.168.21.2
netmask 255.255.255.0
network 192.168.21.0
gateway 192.168.21.254
nano /etc/dhcp/dhcpd.conf
authoritative;
ddns-update-style none;
default-lease-time 240;
max-lease-time 380;
subnet 192.168.21.0 netmask 255.255.255.0 {
range 192.168.21.30 192.168.21.70
option routers 192.168.21.1}
When i write "service isc-dhcp-server start" in "/etc/init.d", i have this error: "start: job failed to start" PLEASE HELP ME!!!!!

Turbocapitalist 03-12-2017 10:55 AM

Welcome to the forum.

It will help if you can put the configuration material inside [code] [/code] tags so that the whitespace is preserved. For what it's worth, it's possible for you to edit your post and add them in.

Running the DHCP daemon directly will give more information because the startup scripts will eat the error messages.
Try running it in the foreground while sending error information to stdout:

Code:

sudo /usr/sbin/dhcpd -df
That way you'll see the specific complaints it has with the configuration file.

See the manual page for the details of -d and -f

Code:

man dhcpd


All times are GMT -5. The time now is 07:17 PM.