設定 Azure Stack Hub 的時間伺服器Configure the time server for Azure Stack Hub

您可以使用具特殊權限的端點 (PEP) 來更新 Azure Stack Hub 中的時間伺服器。You can use the privileged endpoint (PEP) to update the time server in Azure Stack Hub. 請使用可解析為兩個或更多 NTP (網路時間通訊協定) 伺服器 IP 位址的主機名稱。Use a host name that resolves to two or more NTP (Network Time Protocol) server IP addresses.

Azure Stack Hub 會使用 NTP 來連線到網際網路上的時間伺服器。Azure Stack Hub uses NTP to connect to time servers on the internet. NTP 伺服器會提供精確的系統時間。NTP servers provide accurate system time. 在 Azure Stack Hub 的實體網路交換器、硬體生命週期主機、基礎結構服務和虛擬機器上,都會使用時間。Time is used across Azure Stack Hub's physical network switches, hardware lifecycle host, infrastructure service, and virtual machines. 如果時鐘不同步,Azure Stack Hub 可能會發生嚴重的網路和驗證問題。If the clock isn't synchronized, Azure Stack Hub may experience severe issues with the network and authentication. 記錄檔、文件和其他檔案可能會以不正確的時間戳記建立。Log files, documents, and other files may be created with incorrect timestamps.

需提供一部時間伺服器 (NTP) 讓 Azure Stack Hub 同步處理時間。Providing one time server (NTP) is required for Azure Stack Hub to synchronize time. 在部署 Azure Stack Hub 時,您應提供 NTP 伺服器的位址。When you deploy Azure Stack Hub, you provide the address of an NTP server. 時間是重要的資料中心基礎結構服務。Time is a critical datacenter infrastructure service. 如果服務有所變更,您就需要更新時間。If the service changes, you need to update the time.

注意

Azure Stack Hub 支援將時間與一部時間伺服器 (NTP) 進行同步處理。Azure Stack Hub supports synchronizing time with only one time server (NTP). 您無法為 Azure Stack Hub 提供多個 NTP 來同步處理時間。You can't provide multiple NTPs for Azure Stack Hub to synchronize time with.

設定時間Configure time

  1. 連線至 PEPConnect to the PEP.

    注意

    您不需要建立支援票證來解除鎖定具特殊權限的端點。It isn't necessary to unlock the privileged endpoint by opening a support ticket.

  2. 執行下列命令以檢閱目前設定的 NTP 伺服器:Run the following command to review the current configured NTP server:

    Get-AzsTimeSource
    
  3. 執行下列命令對 Azure Stack Hub 進行更新,以使用新的 NTP 伺服器並立即同步處理時間。Run the following command to update Azure Stack Hub to use the new NTP server and to immediately synchronize the time.

    注意

    此程序不會更新實體交換器上的時間伺服器。This procedure doesn't update the time server on the physical switches. 如果您的時間伺服器不是 Windows 型 NTP 伺服器,則需要新增 0x8 旗標。If your time server isn't a Windows-based NTP server, you need to add the flag 0x8.

    Set-AzsTimeSource -TimeServer NEWTIMESERVERIP -resync
    

    對於 Windows 型時間伺服器以外的伺服器:For servers other than Windows-based time servers:

    Set-AzsTimeSource -TimeServer "NEWTIMESERVERIP,0x8" -resync
    
  4. 檢查命令的輸出中是否有任何錯誤。Review the output of the command for any errors.

後續步驟Next steps

檢視整備報告View the readiness report
一般 Azure Stack Hub 整合考量General Azure Stack Hub integration considerations