ubuntu16禁用utc时间

安装双系统以后,发现进入win7和ubuntu系统以后,显示的时间不一致,后来发现是两个系统对硬件时间的看法不一致

1、Windows会认为BIOS时间就是你的本地时间

2、ubuntu默认时间是把BIOS时间当成GMT+0时间,也就是世界标准时,而我国在东八区(GMT+8),所以如果你的Ubuntu位置是中国的话你系统显示的时间就是BIOS时间+8小时。假如现在是早上8点,那么你Ubuntu会显示8点,这时BIOS中的时间是0点。


更正方法:将ubuntu对待bios时间的方法改为和windows一致。

代码:
sudo timedatectl set-local-rtc 1

代码:
$ timedatectl               
      Local time: 六 2016-04-23 09:05:54 CST
  Universal time: 六 2016-04-23 01:05:54 UTC
        RTC time: 六 2016-04-23 09:05:54
       Time zone: Asia/Shanghai (CST, +0800)
 Network time on: yes
NTP synchronized: no
 RTC in local TZ: yes

Warning: The system is configured to read the RTC time in the local time zone.
         This mode can not be fully supported. It will create various problems
         with time zone changes and daylight saving time adjustments. The RTC
         time is never updated, it relies on external facilities to maintain it.
         If at all possible, use RTC in UTC by calling
         'timedatectl set-local-rtc 0'.


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值