Community Forums
Connect with us on LinkedIn
Community Notice
+ Reply to Thread
Results 1 to 3 of 3
  1. #1
    Member
    Join Date
    Mar 2003
    Posts
    78

    Default error_log file in every directory?

    Any ideas why an error_log file would be created in any directory thats under an account that produces a Apache/PHP/MySQL error? For example, http://www.example.com/mydir/index.php has some PHP errors that display when I try to access the file through the web. In /home/mysite/public_html/mydir, an "error_log" file is created, and all the errors are in it. I don't remember seeing this on previous CPanel servers. What can I do to change this back to the "normal" way of logging?

    Thanks,

    Matthew

  2. #2
    Member serversphere's Avatar
    Join Date
    Jan 2004
    Posts
    658

    Default

    What's the normal way of logging you are familiar with? In php.ini you can control logging and error display. Look for the "Error handling and and logging" section. Most people these days (well they should anyway) leave display_errors as off and turn on log_errors. This is what you'll find yours is set to probably.

    Reason being, it doesn't show the error to people who are trying to find bad php scripts to exploit. If they don't see an error, it's harder for them to exploit it.

    Anyway, if you want to change those values then simply save the file and restart apache. You will be good to go.
    Darren Benfer | SS-Darren | AIM: serversphere
    www.serversphere.com
    Dedicated Server Solutions Have Come Full Circle

  3. #3
    Member
    Join Date
    Mar 2003
    Posts
    78

    Default

    I always thought there was a single file per domain that held the error messages for that domain, rather than an error_log file being created under each directory an error occurs.

    I agree with turning the displaying of errors off, but I'd like to keep logging on so I can see what's going on. I just don't like that a site could have 50 different error_log files throughout the site's public_html directory.

    Does that make sense?

    Thanks,

    Matthew

Similar Threads & Tags
Similar threads

  1. Whats this in error_log? ( Usage: file [-bciknsvzL] [-f namefile] )
    By konrath in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 05-05-2010, 10:12 PM
  2. 6GB error_log file not rotating!!!
    By bsasninja in forum cPanel and WHM Discussions
    Replies: 8
    Last Post: 07-11-2009, 04:53 PM
  3. error_log File
    By cancer10 in forum cPanel and WHM Discussions
    Replies: 3
    Last Post: 05-13-2008, 01:33 AM
  4. error_log in user's public_html directory
    By marius in forum cPanel and WHM Discussions
    Replies: 6
    Last Post: 05-19-2005, 10:52 AM
  5. is this normal in the error_log file ?
    By silvernetuk in forum cPanel and WHM Discussions
    Replies: 1
    Last Post: 12-11-2002, 03:31 PM
Linkedin       Facebook       Twitter       RSS       Flickr       YouTube