我的pop os 系統和 ubuntu 系統裝在同一台電腦的不同硬碟上,每次開機目標從linux 切換回 ubuntu 的時候,都會讓 windows 的時間錯誤
- User
我的pop os 系統和 ubuntu 系統裝在同一台電腦的不同硬碟上,每次開機目標從linux 切換回 ubuntu 的時候,都會讓 windows 的時間錯誤
Assistant
這是 Windows 和 Linux 系統處理硬體時鐘方式不同造成的經典問題。Windows 預設將硬體時鐘(RTC)設為本地時間,而 Linux 預設使用 UTC 時間。當你在系統間切換時,每個系統都會按自己的方式調整硬體時鐘,導致時間錯亂。
有兩種解決方法:
方法一:讓 Linux 使用本地時間(推薦)
在 Pop!_OS 和 Ubuntu 上執行:
sudo timedatectl set-local-rtc 1 --adjust-system-clock檢查設定是否生效:
timedatectl你應該會看到
RTC in local TZ: yes方法二:讓 Windows 使用 UTC 時間
在 Windows 中以管理員身份執行:
reg add "HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\TimeZoneInformation" /v RealTimeIsUniversal /d 1 /t REG_DWORD /f如果要還原:
reg delete "HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\TimeZoneInformation" /v RealTimeIsUniversal /f方法一通常比較簡單且穩定,因為只需要在 Linux 系統上做調整。記得在兩個 Linux 系統(Pop!_OS 和 Ubuntu)上都執行相同的設定,這樣所有系統就會使用一致的時間標準了。
Other models, same or similar prompt
Responses were produced in different, uncontrolled contexts (system prompts, settings, prior turns). This is not a benchmark.