Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 08-24-2011, 09:58 AM   #1
LQ Newbie
Registered: Feb 2008
Posts: 14

Rep: Reputation: 0
DHCP server failed to start


My linux server is running Fedora Core 14 x64.

I installed DHCP server by doing yum install dhcp
I also configured /etc/dhcp/dhcpd.conf
Where starting manually by doing /usr/sbin/dhcpd start. It works.
However, when I tried to run "service dhcpd start" it failed.
So, when I tried to add "/usr/sbin/dhcpd &" into /etc/rc.local hoping that when the system reboots, it'll start automatically, this doesn't work.
So at this point, I'm stuck and not sure how to automate it so that my DHCP server will start automatically every time the system boots.

Any advises to resolve this is greatly appreciated.

Old 08-25-2011, 05:57 AM   #2
Registered: Aug 2011
Posts: 47

Rep: Reputation: Disabled
check /var/log/messages or any other log file related to the dhcp server (all log files are into /var/log/) to know what's wrong.

spring logout

Last edited by allwimb; 12-12-2011 at 06:48 AM.
Old 08-25-2011, 07:40 AM   #3
Registered: Apr 2007
Distribution: centos,rhel, solaris
Posts: 239

Rep: Reputation: 30
you can also use:

chkconfig --level <runlevel/s you want it to start on> dhcpd on

ex: chkconfig --level 345 dhcpd on
chkconfig will allow you to start or stop the service on a per runlevel basis. Whilst editing the /etc/rc.local will start dhcpd when starting ALL runlevels.
Old 08-26-2011, 09:23 AM   #4
LQ Newbie
Registered: Feb 2008
Posts: 14

Original Poster
Rep: Reputation: 0


This is what I got inside /var/log/messages
dhcpd: Can't open /etc/dhcp/dhcpd.conf: Permission denied

So looks like the dhcpd can't access the configuration file. But shouldn't the system have root access when start up ?
This is the permission on the file
-rw-r--r--. 1 root root 15535 Aug 24 08:46 /etc/dhcp/dhcpd.conf

Old 08-26-2011, 04:21 PM   #5
LQ Newbie
Registered: Feb 2008
Posts: 14

Original Poster
Rep: Reputation: 0
Solution found

I finally figured out what went wrong.

It's SELINUX that caused this. /etc/dhcp/dhcpd.conf label isn't correct so DHCPD daemon can't start it.

To fix this issue with SELINUX enable, issue the command:
/sbin/restorecon -v /etc/dhcp/dhcpd.conf

Done .


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Dhcp server does not start venkatmvc Linux - Networking 2 08-02-2011 08:55 PM
dnsmasq: failed to bind DHCP server socket: Address already in use taske Linux - Networking 2 11-08-2009 06:40 PM
Dhcp failed to start perfectpol7 Linux - Server 3 07-09-2009 09:44 AM
Failed to start the X server jilloper Linux - Newbie 6 09-21-2007 09:09 PM
Failed to start FTP server - server daemon when in inetd mode. pujakofriendly Slackware 2 11-30-2006 02:58 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 01:02 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration