Please find the steps for modifying NTP settings of vCloud Director Appliance.
Change NTP Servers
- SSH to vCloud Director appliance as root.
- Configure the NTP source for the virtual appliance.
- Open the /etc/systemd/timesyncd.conf file to edit, such as vi.
- Remove the comment for the NTP configuration, add the NTP settings, and save the changes. Please note that you’ve to leave a space between NTP server FQDNs. NTP=<FQDN of NTP Server1> <FQDN of NTP Server>
For example,
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 |
root@pingforinfovcd01 [ ~ ]# cat /etc/systemd/timesyncd.conf # This file is part of systemd. # # systemd is free software; you can redistribute it and/or modify it # under the terms of the GNU Lesser General Public License as published by # the Free Software Foundation; either version 2.1 of the License, or # (at your option) any later version. # # Entries in this file show the compile time defaults. # You can change settings by editing this file. # Defaults can be restored by simply deleting this file. # # See timesyncd.conf(5) for details. [Time] #FallbackNTP=time1.google.com time2.google.com time3.google.com time4.google.com NTP=ntp1.local.com ntp2.local.com root@pingforinfovcd01 [ ~ ]# |
Verify the status
- Enable the systemd-timesyncd service and verify the status.
- Run the timedatectl set-ntp true command to enable the network time synchronization.
- Run the systemctl restart systemd-timesyncd to enable the NTP synchronization
- Run the timedatectl status and systemctl status systemd-timesyncd.service to verify the status of the service.
1 2 3 4 5 6 7 8 |
root@pingforinfovcd01 [ ~ ]# timedatectl status Local time: Tue 2020-08-04 14:13:43 +04 Universal time: Tue 2020-08-04 10:13:43 UTC RTC time: Tue 2020-08-04 10:13:43 Time zone: Asia/Oman (+04, +0400) Network time on: yes NTP synchronized: yes RTC in local TZ: no |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 |
root@pingforinfovcd01 [ ~ ]# systemctl status systemd-timesyncd.service * systemd-timesyncd.service - Network Time Synchronization Loaded: loaded (/lib/systemd/system/systemd-timesyncd.service; enabled; vendor preset: enabled) Active: active (running) since Tue 2020-08-04 13:32:18 +04; 23min ago Docs: man:systemd-timesyncd.service(8) Main PID: 4012 (systemd-timesyn) Status: "Synchronized to time server 10.10.12.10:123 (ntp1.local.com)." Tasks: 2 (limit: 4915) CGroup: /system.slice/systemd-timesyncd.service `-4012 /lib/systemd/systemd-timesyncd Aug 04 13:32:18 pingforinfovcd01.local.com systemd[1]: Starting Network Time Synchronization... Aug 04 13:32:18 pingforinfovcd01.local.com systemd[1]: Started Network Time Synchronization. Aug 04 13:32:18 pingforinfovcd01.local.com systemd-timesyncd[4012]: Synchronized to time server 10.10.12.10:123 (ntp1.local.com). root@pingforinfovcd01 [ ~ ]# |
Change Time Zone
After you deploy successfully the vCloud Director appliance, you can change the system time zone of the appliance. All vCloud Director appliance instances in the server group must use the same settings.
Please find the steps to change the timezone of vCD appliances here.