httpd.conf problems

J

jonners

Guest
Ji,

I would really appreciate your help.

I have a G4 running panther, and I have tried to install PHP and mySql, but have had problems. (The PHP installer I downloaded from www.entropy.ch, it just said there were errors at the end., then I did it manually and there was an error in line #25 of httpd.conf)

I then learned about turning on web sharing in
‘system preferences’>’sharing’

However, whenI click on it, it says ‘starting’ and just hangs and never actually starts. If I go to http://127.0.0.1/~jonD/ in a web browser, nothing happens, but if I go to my sites folder, there's the apache standard, 'Apache server is working test page'.

I have followed this tutorial:
http://docs.info.apple.com/article.html?artnum=106505

and when in the httpd.conf file, there is nothing there, not even a line.

Does this mean that apache isn't compiled?

Should I just re-boot my Mac, or can you please tell me how to re-install apache?

thanks,

Jon
 
Joined
Jun 11, 2003
Messages
4,915
Reaction score
68
Points
48
Location
Mount Vernon, WA
Your Mac's Specs
MacBook Pro 2.6 GHz Core 2 Duo 4GB RAM OS 10.5.2
It sounds like something is really wrong with your httpd.conf file.. is there a backup file in that directory? something like httpd.conf.bak
 
OP
K

katatak

Guest
A few quick hints about trouble shooting Apache:

There is a nifty controller for Apache in /usr/sbin, try this:

sudo /usr/sbin/apachectl configtest

That will parse your httpd.conf file and see if there are syntax errors.

you can use apachectl to start, stop or restart apache

also try /usr/sbin/apachectl --help

Also try checking the apache logs. tail is a usefull command for getting the last few lines of any log file:

sudo tail /var/log/httpd/access_log

will show you the last few things apache did and

sudo tail /var/log/httpd/error_log

will show you any errors Apache encountered. Also remember to use tab filename completion for long command lines

Oh! and no, you don't have to re-compile or re-install apache! You just have to figure out the problems with your config file and if PHP is involved, make sure you've added the correct lines in httpd.conf to enable the filetypes

DF
 
OP
K

katatak

Guest
Murlyn said:
It sounds like something is really wrong with your httpd.conf file.. is there a backup file in that directory? something like httpd.conf.bak

httpd.conf.default will be the original file and if Apple has updated Apache you will frequently find this:

httpd.conf.applesaved
 

Shop Amazon


Shop for your Apple, Mac, iPhone and other computer products on Amazon.
We are a participant in the Amazon Services LLC Associates Program, an affiliate program designed to provide a means for us to earn fees by linking to Amazon and affiliated sites.
Top