how to change server time in cyberpanel — CyberPanel - WebHosting Control Panel for OpenLiteSpeed
CyberLoader

how to change server time in cyberpanel

how to change server time in cyberpanel

Comments

  • Decide on timezone
    https://en.wikipedia.org/wiki/List_of_tz_database_time_zones

    command replace "America/Detroit" with your Timezone
    echo "Before: $(date)" && export TZ="/usr/share/zoneinfo/America/Detroit" && echo 'export TZ="/usr/share/zoneinfo/America/Detroit"' >> ~/.bashrc && echo "After: $(date)"

    [[email protected] ~]# echo "Before: $(date)" && export TZ="/usr/share/zoneinfo/America/Detroit" && echo 'export TZ="/usr/share/zoneinfo/America/Detroit"' >> ~/.bashrc && echo "After: $(date)"
    Before: Thu Sep 19 07:57:32 UTC 2019
    After: Thu Sep 19 03:57:32 EDT 2019
    [[email protected] ~]#
  • The simple answer:

    To see current timezone:
    >> timedatectl

    To list all possible timezones:
    >> timedatectl list-timezones

    To set your specific timezone:
    >> timedatectl set-timezone America/Sao_Paulo

    To verify if the changes were applied:
    >> timedatectl

    Then:
    >> reboot
  • Type your comment> @webmasterpm said:
    > The simple answer:
    >
    > To see current timezone:
    > >> timedatectl
    >
    > To list all possible timezones:
    > >> timedatectl list-timezones
    >
    > To set your specific timezone:
    > >> timedatectl set-timezone America/Sao_Paulo
    >
    > To verify if the changes were applied:
    > >> timedatectl
    >
    > Then:
    > >> reboot

    I got the output this:
    Local time: Tue 2021-06-01 20:40:00 HKT
    Universal time: Tue 2021-06-01 12:40:00 UTC
    RTC time: Tue 2021-06-01 12:40:01
    Time zone: Asia/Hong_Kong (HKT, +0800)
    System clock synchronized: yes
    NTP service: active
    RTC in local TZ: no

    The Cyberpanel backup file name still in UTC, not UTC+8. How can I fix it to UTC+8 ?
Sign In or Register to comment.
CyberPanel Discord

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!