Review your favorite Linux distribution.
Go Back > Forums > Linux Forums > Linux - Software
User Name
Linux - Software This forum is for Software issues.
Having a problem installing a new program? Want to know which application is best for the job? Post your question in this forum.


  Search this Thread
Old 09-22-2003, 09:08 PM   #1
Citizen Bleys
Registered: Mar 2001
Location: Moncton, NB
Distribution: Gentoo 2006.0
Posts: 181

Rep: Reputation: 30
httpd and dhcp won't play nice

Alright...I have a fresh install of RedHat 8.0. The machine it's on is utter garbage, such that if I go into X at all, it starts crashing worse than Windows 95, so I need to be able to do everything from the command line. That's OK, because the machine's a server.

Now, httpd will run fine as long as eth1 (the NIC that goes out to the internet) is not plugged in. Since the server is doing NAT for me, I pretty much need eth1 to be active.

As soon as I get a dhcp lease from my ISP, though, it changes my hostname, and httpd won't start. It says "http: could not determine the server's fully qualified domain name, using for ServerName"

I went and edited /etc/httpd/conf/httpd.conf and uncommented the ServerName line and set it to (That's the IP address bound to eth0, the internal interface). Now when I try to do httpd -k restart, all it says is "httpd not running, trying to start"

It fails, because httpd isn't running afterwards, but it won't give me any error messages. I try httpd -k start, and I get no messages whatsoever.

I'm pretty sure it's the dhcp-set hostname that is frigging up apache, but I need to be able to do NAT and httpd at the same time.

I don't particularly care if clients out on the web can see what's on my web server, as long as Windows clients on my LAN can.
Old 09-23-2003, 12:36 AM   #2
Registered: Aug 2003
Location: Seattle, Wa
Distribution: Fedora,Trustix,Debian
Posts: 290

Rep: Reputation: 30
change the listen line on your httpd.conf files to reflect the ip address
safe and exit
edit the /etc/hosts file
and add this line localhost.localdomain localhost
safe and exit

then type
service httpd stop
service httpd start
Old 11-17-2003, 07:44 AM   #3
Citizen Bleys
Registered: Mar 2001
Location: Moncton, NB
Distribution: Gentoo 2006.0
Posts: 181

Original Poster
Rep: Reputation: 30
I hit the same problem on a different machine; Going through those steps eliminates error messages when I try /usr/sbin/httpd -k start, but it still doesn't work.

if I try /usr/sbin/httpd -k restart, I get "httpd not running, trying to start"

I'm sure there's got to be a log somewhere that tells me what happened, but I don't know where it is.


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
Why can't Flash play nice with aRts like everything else? squirrels Linux - Software 13 10-17-2005 10:11 AM
Ubuntu and Xorg don't play nice adamb10 Ubuntu 9 07-07-2005 12:25 AM
do fc2 and nforce2 play nice together? Motown Fedora 8 01-28-2005 07:29 AM
Anyone getting Suse 9.0 and Vmware to play nice? Caeda Linux - Software 1 12-10-2003 08:35 PM
RedHat 8.0 is nice!BUT i can't play mp3 in it... Leonadia Linux - Software 3 10-12-2002 05:03 AM

All times are GMT -5. The time now is 07:24 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