The macosxhints Forums

The macosxhints Forums (http://hintsforums.macworld.com/index.php)
-   UNIX - Newcomers (http://hintsforums.macworld.com/forumdisplay.php?f=15)
-   -   Apache won't start (http://hintsforums.macworld.com/showthread.php?t=27330)

hayne 08-27-2004 06:09 PM

Quote:

Originally Posted by DJ_Max
When I go to Disk Utility ->First Aid; while my drive is selected, the sections are grayed out. If I can get a screenshot, i will...
Link

Oops - my mistake. I forgot that you are running 10.1 and in that ancient version of the OS, there is no "repair permissions" feature in Disk Utility. At that time, it was a separate utility and it might not have even come standard with the OS - you might have to download it separately. You can read about it and download it via this page:
http://docs.info.apple.com/article.html?artnum=106900

DJ_Max 08-27-2004 06:15 PM

Quote:

Originally Posted by hayne
Oops - my mistake. I forgot that you are running 10.1 and in that ancient version of the OS, there is no "repair permissions" feature in Disk Utility. At that time, it was a separate utility and it might not have even come standard with the OS - you might have to download it separately. You can read about it and download it via this page:
http://docs.info.apple.com/article.html?artnum=106900

Yeah, that must be the reason I couldn't find the button you were talking aboutr, I knew I wasn't going crazy. I'll download after this post.

Arg!!, I ran the program, and it went through my 23k+ files, and said everything went ok.
Code:

2004-08-27 17:30:52 -0500 - The privileges have been repaired on the volume 'Macintosh HD'
But I still get the same error:
Code:

/usr/sbin/apachectl: permission denied: /etc/httpd [71]
/usr/sbin/apachectl start: httpd could not be started
 [71]

I have to look at that shell file, and try to make sense of it.

hayne 08-27-2004 07:17 PM

Quote:

Originally Posted by DJ_Max
I still get the same error:
Code:

/usr/sbin/apachectl: permission denied: /etc/httpd [71]
/usr/sbin/apachectl start: httpd could not be started
 [71]

I have to look at that shell file, and try to make sense of it.

The version I have is the one that shipped with Panther, so it may have changed from what you have, but here are the relevant bits:
Code:

# the path to your httpd binary, including options if necessary
HTTPD=/usr/sbin/httpd

....

    case $ARG in
    start)
        if [ $RUNNING -eq 1 ]; then
            echo "$0 $ARG: httpd (pid $PID) already running"
            continue
        fi
        if $HTTPD ; then
            echo "$0 $ARG: httpd started"
        else
            echo "$0 $ARG: httpd could not be started"
            ERROR=3
        fi
        ;;

From this, it seems that you are getting the error message of the last "echo" line. And this, together with the "permission denied" error you get, seems to indicate that the variable $HTTPD is wrongly defined in your version of the apachectl script. It seems that $HTTPD is defined as /etc/httpd instead of /usr/sbin/httpd as in my version of apachectl.
Have a look and see what is different in your version of the apachectl script.

kfaulhaber 08-27-2004 11:13 PM

My mistake on the error log path.

My memory does not go back to 10.1, but just for fun, which httpd should give you the path to your apache binary, and if it does, sudo httpd should start it since httpd -t gave you a clean bill of health. You will want to fix the errors with apachectl to make life easier.

DJ_Max 08-27-2004 11:43 PM

Quote:

Originally Posted by kfaulhaber
My mistake on the error log path.

My memory does not go back to 10.1, but just for fun, which httpd should give you the path to your apache binary, and if it does, sudo httpd should start it since httpd -t gave you a clean bill of health. You will want to fix the errors with apachectl to make life easier.

Thanks, that worked and got apache running.

Quote:

From this, it seems that you are getting the error message of the last "echo" line. And this, together with the "permission denied" error you get, seems to indicate that the variable $HTTPD is wrongly defined in your version of the apachectl script. It seems that $HTTPD is defined as /etc/httpd instead of /usr/sbin/httpd as in my version of apachectl.
Have a look and see what is different in your version of the apachectl script.
Yeah, I just figured that out. I have to look into what happend, and how to fix it.

BTW, I wanna thank everyone for their help. :cool:

EDIT:
Yeah, you were right on the mark.
I had
Code:

HTTPD=/etc/httpd
When it should have been:
Code:

HTTPD=/usr/sbin/httpd


All times are GMT -5. The time now is 10:36 PM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.
Site design © IDG Consumer & SMB; individuals retain copyright of their postings
but consent to the possible use of their material in other areas of IDG Consumer & SMB.