共計 1062 個字符,預(yù)計需要花費 3 分鐘才能閱讀完成。
本篇內(nèi)容介紹了“ubuntu 下怎么禁用 utc 時間”的有關(guān)知識,在實際案例的操作過程中,不少人都會遇到這樣的困境,接下來就讓丸趣 TV 小編帶領(lǐng)大家學(xué)習(xí)一下如何處理這些情況吧!希望大家仔細閱讀,能夠?qū)W有所成!
前言
大家在安裝雙系統(tǒng)以后,發(fā)現(xiàn)進入 win7 和 ubuntu 系統(tǒng)以后,顯示的時間不一致,后來發(fā)現(xiàn)是兩個系統(tǒng)對硬件時間的看法不一致
原因如下
1、Windows 會認(rèn)為 BIOS 時間就是你的本地時間
2、ubuntu 默認(rèn)時間是把 BIOS 時間當(dāng)成 GMT+ 0 時間,也就是世界標(biāo)準(zhǔn)時,而我國在東八區(qū)(GMT+8),所以如果你的 Ubuntu 位置是中國的話你系統(tǒng)顯示的時間就是 BIOS 時間 + 8 小時。假如現(xiàn)在是早上 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 .
“ubuntu 下怎么禁用 utc 時間”的內(nèi)容就介紹到這里了,感謝大家的閱讀。如果想了解更多行業(yè)相關(guān)的知識可以關(guān)注丸趣 TV 網(wǎng)站,丸趣 TV 小編將為大家輸出更多高質(zhì)量的實用文章!