You have been asked to update the Azure Stack Hub Integrated System to utilize a non-window based NTP (Network Time Protocol) Server with hostname ntp2.contoso.com.
Which of the following is the right command that you would run for the purpose?
Click on the arrows to vote for the correct answer
A. B. C. D. E.Correct Answer: C
For updating Azure Stack Hub to utilize the new window based NTP server along with the immediate synchronization of the time, run the following command:
Set-AzsTimeSource -TimeServer NEWTIMESERVERIP -resync
For other than window based time servers, there is a need to add the flag 0x8 and the command would be:
Set-AzsTimeSource -TimeServer "NEWTIMESERVERIP,0x8" -resync.
Option A is incorrect.
As the server is non-window based, flag 0x8 needs to be added with the hostname.
Option B is incorrect.
As the server is non-window based, flag 0x8 needs to be added with the hostname.
Also, the command needs to use Set-AzsTimeSource instead of Get-AzsTimeSource.
Option C is correct.
Set-AzsTimeSource -TimeServer “ntp2.contoso.com,0x8” -resync is the right answer.
Option D is incorrect.
The right command needs to use Set-AzsTimeSource instead of Get-AzsTimeSource.
Option E is incorrect.
The right flag to be added with hostname is 0x8, not 0xx8.
To know more about configuring the time server for Azure Stack Hub, please visit the below-given link:
The correct command to update the Azure Stack Hub Integrated System to use a non-Windows based NTP server with hostname "ntp2.contoso.com" is option C, "Set-AzsTimeSource -TimeServer “ntp2.contoso.com,0x8” -resync".
Explanation: Azure Stack Hub uses Network Time Protocol (NTP) to synchronize time across its different components. By default, it uses the Windows Time Service as the time source. However, you can update the time source to use a non-Windows based NTP server.
The command "Set-AzsTimeSource" is used to set the NTP time source for Azure Stack Hub, and the parameter "-TimeServer" is used to specify the NTP server hostname. The hostname "ntp2.contoso.com" is provided in all options, but the correct syntax for specifying a non-Windows based NTP server is to include the ",0x8" option. The ",0x8" option specifies the time source as a non-Windows based NTP server.
Option A, "Set-AzsTimeSource -TimeServer “ntp2.contoso.com” -resync", is incorrect because it does not include the ",0x8" option to specify a non-Windows based NTP server.
Option B, "Get-AzsTimeSource -TimeServer “ntp2.contoso.com” -resync", is incorrect because it retrieves the current NTP time source for Azure Stack Hub, but it does not set a new NTP time source.
Option D, "Get-AzsTimeSource -TimeServer “ntp2.contoso.com,0x8” -resync", is incorrect because it uses the "Get-AzsTimeSource" command instead of "Set-AzsTimeSource" to retrieve the current NTP time source, and it includes the "-resync" option which is not needed for a "Get" command.
Option E, "Set-AzsTimeSource -TimeServer “ntp2.contoso.com,0xx8” -resync", is incorrect because it includes an extra "x" in the ",0xx8" option which is invalid syntax. The correct syntax is ",0x8".
Therefore, the correct command to update the Azure Stack Hub Integrated System to utilize a non-Windows based NTP server with hostname "ntp2.contoso.com" is option C, "Set-AzsTimeSource -TimeServer “ntp2.contoso.com,0x8” -resync".