Ticket ID #195 ‐ Applying NTP Server to Clients - GriffinKat/group-a GitHub Wiki

Applying the NTP module to the nodes.

  • To apply the module to your nodes, add the following line to each node definition in(Management Server) /etc/puppetlabs/code/environment/production/manifests/site.pp:

    include ntp_service

    image

    Then, run the Puppet agent on each machine using the command:

    sudo /opt/puppetlabs/puppet/bin/puppet agent --server=mgmt-a --no-daemonize --verbose --onetime

    Below is the screenshot of the application of the module on all the servers.

    image

    image

    image

  • Testing the NTP Configuration

    To verify that your NTP configuration is working, follow these steps:

  1. Verify the NTP Service is Running

    Check the status of the NTP service on both the server and clients:

    sudo systemctl status ntp

    image

    image

    image

  2. Check NTP Synchronization

    Use the ntpq -p command to check synchronization:

    ntpq -p

    image

    image

    image

    Use the following command to check the synchronization status:

    ntpstat

    image

    image

    image

  3. Verify Time Accuracy

    Check the system time on both the server and clients: date

    Management Server(Master)

    image

    Apps Server(Node)

    image

    Backup Server(Node)

    image

    Database Server(Node)

    image

    NOTE: Ensure the times are consistent (within milliseconds).