Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations biv343 on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Linux RedHat DHCP

Status
Not open for further replies.

VieiraR

MIS
Jul 3, 2003
66
US
Hi,

I am in need of urgent help. My boss is away and he is in charge of the Linux box which is runnig as the DHCP to or windows network. There was a fire in the building and the power was lost. Know the box is not acting as a DHCP server. I logged into the serevr as root and tried to start the dhcpd service. However am having issues with the dhcpd.conf. I can view hte file but not edit this, not sure of the command. Also the dhcpd is not automatically starting up. What do I need to do to get this started up during boot. Please help no one can get onto the network and I don't want to go and make a bunch of static IP addresses.

 
ok, the first thing you should do then is to get off root, until you know what to do. Someone that doesn't know what he's doing with a unix root password is a recipe for disaster.

If you cannot configure the DHCP server yourself,ask first if anyone in the shop has unix/linux experience. If not, ask yourself if you can do a dhcp server using whatever platform you use usually. If both responses are to the negative, THEN start worrying about configuring the server yourself.

From the command line, to get information about the dhcpd.conf file.... do...
J.Random.User$man dhcpd.conf

This should drop you into the online manual for the dhcp configuration file, which should explain whatever tags and values you will need and where to put them.

... and work from there.

NOTA : IMHO, If you do not know how to edit a text document, then i'm sorry to say you do not have any business having the root password for this box.




_____________________________
when someone asks for your username and password, and much *clickely clickely* is happening in the background, know enough that you should be worried.
 
Like mentioned above, be very careful as root. You can easily wipe out the whole system with one command.

How do you know that DHCP isn't starting up? Did you see an error during the startup messages? Run 'ps -ef | grep dhcp' and see if that returns anything. If DHCP was working before the power outage, there shouldn't be any need to edit the dhcpd.conf file most likely. Its probably just not running because your boss forgot to add it to a startup script.

If DHCP isn't running, try starting it with '/sbin/service dhcpd restart'.

Good luck.

ChrisP
RHCE, LPIC-1, CCNA, CNE, MCSE, +10 others
 
Thanks fluid11,

Yes my boss did not add it to the startup script. I needed to start it manually. I know all there is to Windows and just start learning Linux... b/c my boss wants to use it. I like it but we use Text base and I am still GUI oriented. I backed-up the whole server before I did anything. This way I really can not screw it up. If so then I restore. I maybe new to Linux but not dumb. I restarted the DHCP and it seems to be working. Anyway I can add this to the startup file? Thanks for your help. I know I am a new Linux and am still learning. Maybe this will get my bosses butt in gear.

 
To add it to the startup scripts, try 'chkconfig dhcpd on'. You can check to see if it added it with 'chkconfig --list |grep dhcp'.

ChrisP
RHCE, LPIC-1, CCNA, CNE, MCSE, +10 others
 
WHen I type the command 'chkconfig --list | grep dhcp. I get:

'dhcpd 0:eek:ff 1:eek:ff 2:eek:ff 3:eek:ff 4:eek:ff 5:eek:n 6:eek:ff'

Do you know what this means? Like I said I have everything backed-up and the dhcpd up and running know. I am kindof doing this to learn. I have another machine loaded with the same software but not on the network. Thank you again for your help.

Rich
 
It means that DHCP will start when your computer enters runlevel 5 only (which most likely is what you boot into). Type 'runlevel' to see which runlevel your in (its going to be either 3 or 5). Type this too, to be safe, 'chkconfig --level 2345 dhcpd on'. That will ensure that DHCP will be started regardless of what runlevel you boot into.

ChrisP
RHCE, LPIC-1, CCNA, CNE, MCSE, +10 others
 
fluid11 you have been great. Ok I was on run level 3. Obviously he wanted it to boot into runlevel 5. Why after the power fail did it boot intto run level3 instead of 5? I also set it to be on in runlevels 2345 thanks.


Rich
 
The reason the box should be in runlevel 3 is because a gui is something that can be also exploited, like any other service out there.

When your boss comes back, tell him exactly what you did.Trust me on this. May i suggest arranging the box to run dhcp under run level 3 as default?


_____________________________
when someone asks for your username and password, and much *clickely clickely* is happening in the background, know enough that you should be worried.
 
When you boot to runlevel 3, it will bring you to a command prompt. When you boot to runlevel 5, it will automatically start the GUI. Usually servers boot to runlevel 3.

ChrisP
RHCE, LPIC-1, CCNA, CNE, MCSE, +10 others
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top