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 change time logs

Discussion in 'General Discussion' started by Tonus Sebastian, Nov 23, 2016.

Tags:
  1. Tonus Sebastian

    Tonus Sebastian Registered

    Joined:
    Nov 23, 2016
    Messages:
    1
    Likes Received:
    0
    Trophy Points:
    1
    Location:
    Indonesia
    cPanel Access Level:
    DataCenter Provider
    hello,

    how to change time logs access, i try change in "whm >> server time "but not work

    time my server this correct
    Thu Nov 24 10:17:22 WIB 2016 GMT+7

    if i try test change password account logs

    Code:
    #cat /usr/local/cpanel/logs/access_log  |grep demo |grep "POST"
    
    xxx.xxx.xx.xxx - root [11/24/2016:02:24:28 -0000] "POST /cpsess4875413777/json-api/has_mycnf_for_cpuser HTTP/1.1" 200 0 "http://xxx.xxxx.xxx:2086/cpsess4875413777/scripts4/listaccts?search=demo&searchtype=domain_and_user&acctp=30" "Mozilla/5.0 (Windows NT 6.1; rv:50.0) Gecko/20100101 Firefox/50.0" "s" "-" 2086
    
    please give me advise

    thanks
     
    #1 Tonus Sebastian, Nov 23, 2016
    Last edited by a moderator: Nov 24, 2016
  2. NOC_Serverpoint

    NOC_Serverpoint Well-Known Member

    Joined:
    Jul 3, 2016
    Messages:
    102
    Likes Received:
    6
    Trophy Points:
    18
    cPanel Access Level:
    Website Owner
    Hi,

    The system to reflect the change in the cPanel and WHM interfaces, you must restart the cpservd daemon. To do this, run the following command as the root user:

    service cpservd restart

    Or else you can try this from command line:

    ls /usr/share/zoneinfo/

    Linking your desired time zone:

    ln -s /usr/share/zoneinfo/Etc/GMT+8 /etc/localtime

    Then check :
    date -u
    date

    Thanks,
     
  3. cPanelMichael

    cPanelMichael Forums Analyst
    Staff Member

    Joined:
    Apr 11, 2011
    Messages:
    37,086
    Likes Received:
    1,288
    Trophy Points:
    363
    cPanel Access Level:
    Root Administrator
    Hello,

    It's by design /usr/local/cpanel/logs/access_log uses UTC and it's not possible to override that behavior. Logging UTC timestamps prevents several potential issues that come with logging in local time (e.g. Daylight savings, time zone shifts, etc). It also saves memory on the system, as using local times would require additional functionality added to cpsrvd. Other cPanel log files (e.g. stats_log, login_log) will use the local time zone configured on the system.

    Thank you.
     
Loading...

Share This Page