Note: This procedure can be performed online. In the case of the FlashGrid cluster, these steps must be performed on all database and quorum nodes.
- Remove immutable attribute for
/etc/chrony.conf
file
# chattr -i /etc/chrony.conf
- Edit /etc/chrony.conf file and change/add only in this section:
...
server <IP_or_name_NTP1> prefer iburst
server <IP_or_name_NTP2> prefer iburst
...
- Restart the chronyd service
# systemctl restart chronyd
- Check if chronyd service is running after restart:
# systemctl status chronyd
- Check if chrony is synchronized:
# chronyc tracking # chronyc sources
Example:
[root@rac1 ~]# chronyc tracking
Reference ID : D8EF2300 (time1.google.com)
Stratum : 2
Ref time (UTC) : Fri Dec 18 15:08:39 2020
System time : 0.000838298 seconds fast of NTP time
Last offset : +0.000428240 seconds
RMS offset : 0.001808627 seconds
Frequency : 22.558 ppm slow
Residual freq : -1.062 ppm
Skew : 0.054 ppm
Root delay : 0.023304883 seconds
Root dispersion : 0.001135960 seconds
Update interval : 64.1 seconds
Leap status : Normal
Fields to check in the output for these commands:
Ref time
This is the time (UTC) at which the last measurement from the reference source was processed.
[root@rac1 ~]# chronyc sources
210 Number of sources = 6
MS Name/IP address Stratum Poll Reach LastRx Last sample
===============================================================================
^+ time1.google.com 1 6 377 17 -2609us[-2609us] +/- 12ms
^+ time2.google.com 1 6 377 16 -1102us[-1102us] +/- 15ms
^* time3.google.com 1 6 377 17 -2033us[-3001us] +/- 11ms
^+ time4.google.com 1 6 377 17 -243us[ -243us] +/- 8935us
=- rac2-ext.example.com 2 6 7 71 +36us[ -905us] +/- 80ms
=- racq-ext.example.com 2 6 17 72 +2273us[+1333us] +/- 81ms
M
This indicates the source mode: '^' means a server, '=' means a peer, '#' indicates a locally connected reference clock.
S
Source state: '*' = current synced, '+' = combined , '-' = not combined, '?' = unreachable, 'x' = time may be in error, '~' = time too variable.
Note: chronyc sources -v command will provide explanatory details on all output fields.
- Add the immutable attribute for /etc/chrony.conf
# chattr +i /etc/chrony.conf
Additionally, for changing the timezone, refer to the following article: