Cloudera Enterprise 6.3.x | Other versions

Enable an NTP Service

CDH requires that you configure a Network Time Protocol (NTP) service on each machine in your cluster. Most operating systems include the ntpd service for time synchronization.

RHEL 7 compatible operating systems use chronyd by default instead of ntpd. If chronyd is running (on any OS), Cloudera Manager uses it to determine whether the host clock is synchronized. Otherwise, Cloudera Manager uses ntpd.

  Note: If you are using ntpd to synchronize your host clocks, but chronyd is also running, Cloudera Manager relies on chronyd to verify time synchronization, even if it is not synchronizing properly. This can result in Cloudera Manager reporting clock offset errors, even though the time is correct.

To fix this, either configure and use chronyd or disable it and remove it from the hosts.

To use ntpd for time synchronization:

  1. Install the ntp package:
    • RHEL compatible:
      yum install ntp
    • SLES:
      zypper install ntp
    • Ubuntu:
      apt-get install ntp
  2. Edit the /etc/ntp.conf file to add NTP servers, as in the following example.
    server 0.pool.ntp.org
    server 1.pool.ntp.org
    server 2.pool.ntp.org
  3. Start the ntpd service:
    • RHEL 7 Compatible:
      sudo systemctl start ntpd
    • RHEL 6 Compatible, SLES, Ubuntu:
      sudo service ntpd start
  4. Configure the ntpd service to run at boot:
    • RHEL 7 Compatible:
      sudo systemctl enable ntpd
    • RHEL 6 Compatible, SLES, Ubuntu:
      chkconfig ntpd on
  5. Synchronize the system clock to the NTP server:
    ntpdate -u <ntp_server>
  6. Synchronize the hardware clock to the system clock:
    hwclock --systohc
Page generated August 29, 2019.