Windows XP Windows 7 Windows 2003 Windows Vista Windows 綜合教學 Linux 系統教學
Windows 10 Windows 8 Windows 2008 Windows NT Windows Server 電腦軟體教學
您现在的位置: Windows教程網 >> Windows教程 >  >> Linux 系統教學 >> Linux 教學

Linux 手動調整日期時間

編輯:Linux 教學

示範環境

  • 系統:CentOS 6.4
  • 適用:所有 Linux 發行版

修改日期

date -s 07/11/98

將系統日期設為 1998 年 7 月 11 日。

修改時間

date -s 22:40:00

將系統時間設為 22:40:00。

注意事項:同步至 CMOS

Linux 開機時從 CMOS 讀取時間到系統變數,修改僅影響系統時間。系統約每 11 分鐘同步一次至 CMOS。若同步前重開機,修改可能失效。為確保生效,請執行:

clock -w

此指令將系統時間強制寫入 CMOS。

Copyright © Windows教程網 All Rights Reserved