debian改时区
更改时区
设为香港
timedatectl set-timezone Asia/Hong_Kong
验证是否成功
timedatectl同步时间
#Debian 11为例
#方法1 查看 systemd-timesyncd 状态
timedatectl status
#开启同步
timedatectl set-ntp true
#手动重启同步服务
systemctl restart systemd-timesyncd
#方法2 强制手动同步
apt install -y ntpdate
ntpdate pool.ntp.org
#查看当前时间
date -R