The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

How to reset Error Log?

Discussion in 'General Discussion' started by SuperBaby, Feb 25, 2004.

  1. SuperBaby

    SuperBaby Well-Known Member

    Joined:
    Nov 27, 2003
    Messages:
    331
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Thailand
    cPanel Access Level:
    Website Owner
    Twitter:
    I have been searching for the answer but could not find the answer to this simple question.

    How do I reset Error Log?
     
  2. PWSowner

    PWSowner Well-Known Member

    Joined:
    Nov 10, 2001
    Messages:
    2,948
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    ON, Canada
    in shell
    echo > /path/to/file
    clears the contents of the file
     
  3. SuperBaby

    SuperBaby Well-Known Member

    Joined:
    Nov 27, 2003
    Messages:
    331
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Thailand
    cPanel Access Level:
    Website Owner
    Twitter:
    Yes, but what is the path. I used "locate' to look for errlog.html but it is pulling the content from somewhere else.
     
  4. PWSowner

    PWSowner Well-Known Member

    Joined:
    Nov 10, 2001
    Messages:
    2,948
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    ON, Canada
    The apache or cpanel error log?

    Apache is at /usr/local/apache/logs/error_log

    Cpanel is at /usr/local/cpanel/logs/error_log
     
  5. chirpy

    chirpy Well-Known Member

    Joined:
    Jun 15, 2002
    Messages:
    13,475
    Likes Received:
    20
    Trophy Points:
    38
    Location:
    Go on, have a guess
    If you zero either of those logs, you must restart the service, otherwise it won't really zero it (as the files are open). So, if you zero out the Apache error log, be sure to:
    /etc/init.d/apache restart
     
  6. SuperBaby

    SuperBaby Well-Known Member

    Joined:
    Nov 27, 2003
    Messages:
    331
    Likes Received:
    0
    Trophy Points:
    16
    Location:
    Thailand
    cPanel Access Level:
    Website Owner
    Twitter:
    Doesn't seem like what I am looking for. I am trying to clear the error log that I see under:
    cPanel >> Error Log

    When I opened the two files above, the content was not the same as the one I saw under "Error Log".
     
  7. rogcan

    rogcan Well-Known Member

    Joined:
    Jun 7, 2004
    Messages:
    48
    Likes Received:
    0
    Trophy Points:
    6
    He's referring to each clients "error log" that they can see in there cpanel by clicking on "Web/Ftp Stats" button then clicking on "Error Log" button

    Example: http://domainname.com:2082/frontend/x2/stats/errlog.html

    I'd like to know where these logs are kept as well if anyone is kind enough to tell us :)
     
  8. PWSowner

    PWSowner Well-Known Member

    Joined:
    Nov 10, 2001
    Messages:
    2,948
    Likes Received:
    3
    Trophy Points:
    38
    Location:
    ON, Canada
    They are in /usr/local/apache/logs/error_log. Cpanel just reads that file and gathers the data relevant to that site. They don't each have their own error logs.

    Take a look at that error_log file and you will see the same lines cpanel shows.

    You can't clear just one sites error logs.
     
  9. rogcan

    rogcan Well-Known Member

    Joined:
    Jun 7, 2004
    Messages:
    48
    Likes Received:
    0
    Trophy Points:
    6
    thank you PWSowner !
     
Loading...

Share This Page