PDA

View Full Version : HTTPD won't start



Patriot85
24th May 2006, 07:08 PM
I've got a box that I want to use as an INTRANET server. The httpd service is checked to run at start up but doesn't. When I try to start it manually the 'busy' cursor just runs a very long time and then stops. The service is still not running.

Any ideas on this? I've tried to stop and start, reboot and what have you but the service simply will not start.

Thanks for any info.

pete_1967
24th May 2006, 07:24 PM
check apache logs at /var/log/httpd/

Also, as a root, try launching Apache from command line:


~/su
passwd
/sbin/service httpd start

And check for any error messages.

smfinley
24th May 2006, 07:26 PM
Have you done the appropriate operations to accommodate SELinux? See the web server, php and perl, and mysql sections of Fedora Core 5 Installation Notes (http://stanton-finley.net/fedora_core_5_installation_notes.html) for instructions.

Patriot85
24th May 2006, 09:19 PM
There were entries in two different logs. Here is what was in the ssl_error_log.1:
"[warn] RSA server certificate is a CA certificate (BasicConstraints: CA == TRUE !?)"

Under the other log is just error_log.1:
"[notice] suEXEC mechanism enabled (wrapper: /usr/sbin/suexec)
[Wed May 17 13:20:51 2006] [notice] Digest: generating secret for digest authentication ...
[Wed May 17 13:20:51 2006] [notice] Digest: done
[Wed May 17 13:20:52 2006] [notice] mod_python: Creating 4 session mutexes based on 256 max processes and 0 max threads.
[notice] Apache/2.2.0 (Fedora) configured -- resuming normal operations
[notice] Apache/2.2.0 (Fedora) configured -- resuming normal operations

When I attempted to start the service from the command line it immediatly failed.

Patriot85
24th May 2006, 09:26 PM
Sorry I didn't reply to smfinley: Yes I did make sure that was all done. But all to no avail.

Patriot85
24th May 2006, 09:42 PM
Okay now I'm getting something new when I attempt to start the service from the command line:

[root@Pierre-SD sbin]# service httpd start
Starting httpd: Syntax error on line 354 of /etc/httpd/conf/httpd.conf:
Invalid command ';', perhaps misspelled or defined by a module not included in t he server configuration
[FAILED]

Does this mean I'm missing a package? I can't tell what it is by this if I am.

ccrvic
24th May 2006, 09:55 PM
Starting httpd: Syntax error on line 354 of /etc/httpd/conf/httpd.conf:

It's more likely you've got a simple syntactical error in your config file.

What does line 354 contain?

Vic.

Patriot85
25th May 2006, 01:51 PM
Okay I found that line 354 of the config just had a ; in front of the line and removing that cured that issue. Now when I attempt to start the service it says I have an error on line 133 which simply states "Listen 80". The error claims that port 80 is already in use by another service so I tried several other ports and each time I get the message that "permission is denied" on those other ports.

So, I can either attmept to determine what is using port 80 and get it to use a different port, or figure out why root is getting permissin denied on the other ports.

Any suggestions?

sentry
25th May 2006, 02:59 PM
Do you have any other webservers installed that are binding to port 80? Or any other services for that matter that would bind to port 80?

Patriot85
25th May 2006, 04:31 PM
When I do a netstat -an it tells me that tcp has port 80. I have no idea why or how to get it loose.

smfinley
25th May 2006, 04:57 PM
Did you go to "System" > "Administration" > "Server Settings" > "Services", type in your root password in the dialog box that appears and click on "OK", scroll down the list and untick the check box for "thttpd" if it is ticked as described in the web server section of the Notes (http://stanton-finley.net/fedora_core_5_installation_notes.html)?

Patriot85
25th May 2006, 07:36 PM
Yes I did. But there is no "thttpd" service listed. Checking the "httpd" service and then rebooting you can see the service fails to start. The reason is that a specific line says "Listen 80" and the error claims that port 80 is already in use by another process.

Patriot85
25th May 2006, 08:37 PM
Okay I finally just changed the port in the config file to 8080 instead of just 80 and that seemed to work. Other lower port numbers wouldn't allow me to use them.

I'm unsure what eles has to happen but at the moment I still can't connect to it via a web browser. But this is progress anyway.

Thanks for all the help.

Northern
25th May 2006, 10:18 PM
Hi Partrio85,

try this as root
lsof -i TCP:80
and it should tell you what is listening on port 80

Patriot85
26th May 2006, 09:00 PM
Well I still can't get port 80 released but I have successfully connected from a Windows computer on my network and pulled up the main page of the website so I'm having some success. I have a lot of work to do on the website itself as a couple of clerks and secrateries who are non technical have been doing the upkeep.

I plan on putting this box in producetion in two to three weeks, depending on how much time I can put into it and if I run into too many other issues. One thing that I have wondered about is the lack of a GUI program for Fedora for creating and maintaining web sites. I understand that with some work it can be configured so that Front Page will work which what I need because of the aformentioned keeper of the web site. Yet I was a bit disappointed not to see something included here as it seems that Fedora is pretty popular for use as a web server.

Thanks for all the help, I do appreciate it.

ccrvic
27th May 2006, 12:44 AM
Well I still can't get port 80

What do you get from :

lsof | grep ":http"


One thing that I have wondered about is the lack of a GUI program for Fedora for creating and maintaining web sites.

Have a play with nvu. It's rather good.

Once you're done with that, get back to vi, which is the only way to do web programming :-)

Vic.