ubuntu系统更改时区

版本:Ubuntu 20.04.3 LTS

先查看当前时区配置:

timedatectl status

显示为:

               Local time: Fri 2021-12-31 07:20:54 UTC
           Universal time: Fri 2021-12-31 07:20:54 UTC
                 RTC time: Fri 2021-12-31 07:20:55
                Time zone: Etc/UTC (UTC, +0000)
System clock synchronized: yes
              NTP service: active
          RTC in local TZ: no

可以看到时区是 Etc/UTC,如果要改为东八区,最简单的方法只需一行命令:

timedatectl set-timezone Asia/Shanghai
posted @ 2021-12-03 16:56  seaof  阅读(1079)  评论(0编辑  收藏  举报