You are not logged in.

#1 2009-05-29 11:30:14

slipper
Member
Registered: 2008-09-11
Posts: 28

[SOLVED] Httpd fails after reboot, not logging

Hi all

I have an issue with apache, it does not start after a reboot.

I installed apache, customized httpd.conf and then start it and it was fine.

Shut it down, then booted it up the following afternoon and httpd failed to start so I thought well, I'll just try the default config I guess.
That didn't work either. So I checked for updates, of which there were none, and then reinstalled apache.

It worked after that. So leaving everything as it was upon reinstallation, I rebooted and it has failed again.

I would have checked /var/log/httpd except I have another problem: There are none?  I tried setting httpd.conf to debug level as well and that has shown nothing.

If anybody has any idea on what is causing the problem please let me know.. sad

Last edited by slipper (2009-05-29 14:02:27)

Offline

#2 2009-05-29 11:50:02

ckristi
Member
From: Bucharest, Romania
Registered: 2006-11-21
Posts: 225

Re: [SOLVED] Httpd fails after reboot, not logging

Is httpd listed in your rc.conf startup (DAEMONS) line?

Last edited by ckristi (2009-05-29 11:50:48)


In love I believe and in Linux I trust

Offline

#3 2009-05-29 12:11:44

slipper
Member
Registered: 2008-09-11
Posts: 28

Re: [SOLVED] Httpd fails after reboot, not logging

ckristi wrote:

Is httpd listed in your rc.conf startup (DAEMONS) line?

Nope. Only daemons in there are: network, iptables, dnsmasq, sshd, openntpd

Offline

#4 2009-05-29 12:28:02

ckristi
Member
From: Bucharest, Romania
Registered: 2006-11-21
Posts: 225

Re: [SOLVED] Httpd fails after reboot, not logging

Well.. if you want to start httpd at boot-time, you should add it to that list.


In love I believe and in Linux I trust

Offline

#5 2009-05-29 12:35:02

slipper
Member
Registered: 2008-09-11
Posts: 28

Re: [SOLVED] Httpd fails after reboot, not logging

ckristi wrote:

Well.. if you want to start httpd at boot-time, you should add it to that list.

I plan to, once I get it working wink

Offline

#6 2009-05-29 13:07:53

stefanwilkens
Member
From: Enschede, the Netherlands
Registered: 2008-12-10
Posts: 624

Re: [SOLVED] Httpd fails after reboot, not logging

run a

httpd -t

to check the syntac of the config file.

*edit*

to be sure, you're saying that it will start properly after install but refuses to start after a reboot. You do not have in in rc.conf so I'm assuming you're attempting to start it with /etc/rc.d/httpd start after the reboot?

Last edited by stefanwilkens (2009-05-29 13:08:59)


Arch i686 on Phenom X4 | GTX760

Offline

#7 2009-05-29 13:12:42

slipper
Member
Registered: 2008-09-11
Posts: 28

Re: [SOLVED] Httpd fails after reboot, not logging

stefanwilkens wrote:

run a
*edit*

to be sure, you're saying that it will start properly after install but refuses to start after a reboot. You do not have in in rc.conf so I'm assuming you're attempting to start it with /etc/rc.d/httpd start after the reboot?

Yes, of course smile

Thanks for showing me that httpd -t command.. would have helped a lot before.

It returns as 'Syntax OK', so the httpd.conf is fine.

Offline

#8 2009-05-29 13:42:18

brisbin33
Member
From: boston, ma
Registered: 2008-07-24
Posts: 1,796
Website

Re: [SOLVED] Httpd fails after reboot, not logging

rc.d/httpd just calls

/usr/sbin/apachectl start

but sends errors to /dev/null

run that code directly and check for output when it fails, there's probably a verbose or debug option you can pass as well.

Offline

#9 2009-05-29 14:02:09

slipper
Member
Registered: 2008-09-11
Posts: 28

Re: [SOLVED] Httpd fails after reboot, not logging

brisbin33 wrote:

rc.d/httpd just calls

/usr/sbin/apachectl start

but sends errors to /dev/null

run that code directly and check for output when it fails, there's probably a verbose or debug option you can pass as well.

Thankyou! big_smile

It returned:

(2)No such file or directory: httpd: could not open error log file /var/log/httpd/error_log.
Unable to open logs

By default my logfiles were in /var/log/httpd
There was no /httpd dir...

mkdir /var/log/httpd fixed both of my problems... Thanks smile

Offline

Board footer

Powered by FluxBB