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.

/usr/local/cpanel/logs/access_log deleted by mistake

Discussion in 'General Discussion' started by simpliq, Nov 11, 2014.

  1. simpliq

    simpliq Registered

    Joined:
    Nov 11, 2014
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    cPanel Access Level:
    Root Administrator
    Hello,

    I've deleted by mistake the access_log file on my number 1 server.
    I noticed on server number 2 that the file has " ASCII text, with very long lines " encoding.
    How to fix this ?

    Regards,
    Razvan Vlaicu
     
  2. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    648
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
    Hello :)

    You can re-create this log file via:

    Code:
    touch /usr/local/cpanel/logs/access_log
    By default, ownership is set to "root:root" and permissions are set to 0600.

    Thank you.
     
  3. sarhosting

    sarhosting Well-Known Member

    Joined:
    Oct 1, 2007
    Messages:
    164
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    United States
    cPanel Access Level:
    Root Administrator
    Twitter:
    Hi cPanelMichael. Two questions for you.
    1. Do you have to restart the cPanel Service once the file is recreated?
    2. Is the old information reimported into the log or does it start anew?

    Thanks alot.
     
  4. paknode

    paknode Registered

    Joined:
    Aug 10, 2015
    Messages:
    4
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Pakistan
    cPanel Access Level:
    Root Administrator
    1. Do you have to restart the cPanel Service once the file is recreated?
    No way it doesn't need to restart your server as it just create a file so file creation is not like updating kernel on kvm server.

    2. Is the old information reimported into the log or does it start anew?
    The log starts with fresh content.
     
  5. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    30,678
    Likes Received:
    648
    Trophy Points:
    113
    cPanel Access Level:
    Root Administrator
  6. sarhosting

    sarhosting Well-Known Member

    Joined:
    Oct 1, 2007
    Messages:
    164
    Likes Received:
    2
    Trophy Points:
    18
    Location:
    United States
    cPanel Access Level:
    Root Administrator
    Twitter:
Loading...

Share This Page