2

new Mac (Yosemite) and setting up a new dev environment. At the moment cannot find any error_log folder at the following paths:

/var/log/apache2/error_log
/private/var/log/apache2/error_log
/var/log/httpd/error_log

Any thoughts on where that folder may be?

enter image description here

5
  • Is apache running at all? – nohillside Mar 12 '15 at 19:43
  • @patrix I did sudo apachectl restart and didn't see anything come up, so tried to check the sudo tail -f /var/log/apache2/error_log and that's where I went down this path of trying to figure out if it's running or not – Leon Gaban Mar 12 '15 at 19:46
  • Try to connect to the websever at localhost and/or run ps aux|grep http to see whether apache is running at all. – nohillside Mar 12 '15 at 19:49
  • Nothing is running at localhost or localhost/app and this is what I see after running ps: leongaban 10849 0.0 0.0 2432772 672 s006 S+ 2:56PM 0:00.00 grep --color=auto --exclude-dir=.bzr --exclude-dir=.cvs --exclude-dir=.git --exclude-dir=.hg --exclude-dir=.svn http – Leon Gaban Mar 12 '15 at 19:56
  • No running apache, no error log :-/ – nohillside Mar 12 '15 at 20:00
5

The location of error_log is defined in /etc/apache2/httpd.conf. Run

grep '^ErrorLog' /etc/apache2/httpd.conf

to see the definition.

4
  • Thanks! yeah it says /private/var/log/apache2/error_log which I checked, and there was no error_log folder in there. So I went ahead and made one... fingers crossed – Leon Gaban Mar 12 '15 at 19:49
  • 1
    It's a file, not a folder! Creating a folder with the same name may cause problems, and apache should definitively create the file itself if needed. – nohillside Mar 12 '15 at 19:50
  • 1
    Thx, ok so I removed that folder I made, still no error_log, I guess I have to post a new question about how to run Apache on OSX – Leon Gaban Mar 12 '15 at 19:58
  • 1
    Found the location but no error log in here. – Chucky Jan 23 '16 at 23:04

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .