sudo rm localtime
sudo ln -s /usr/share/zoneinfo/Asia/Chongqing localtime
sudo hwclock –hctosys
这步可能会报错
select() to /dev/rtc to wait for clock tick timed out
解决办法: 加参数 –directisa
sudo hwclock –hctosys –directisa
以上方法重启后无效,还是超时
要彻底如下:
打开/etc/init.d/hwclock.sh,找到HWCLOCKPARS=,在后面添 加”–directisa“
解释:
hwclock
–hctosys set the system time from the hardware clock
–directisa access the ISA bus directly instead of /dev/rtc
环境:Debian40r3 testing i686