NTP: Synchronize time using other NTP peers

Share this link

If you didn’t already set up a time server, learn how to configure a NTP server.

Install the NTP package:

# yum install -y ntpd

Edit the /etc/ntp.conf file and comment the following lines if you don’t want to use the default timeservers:

#server 0.centos.pool.ntp.org
#server 1.centos.pool.ntp.org
#server 2.centos.pool.ntp.org

In the same file, add the name (or IP address) of your time server:

server timeserver

Check the system date:

# date

If the system date is more than 15 minutes away from real time, set up the date from your time server:

# ntpdate timeserver

Activate the NTP service:

# chkconfig ntpd on

Start the NTP service:

# service ntpd start

Check that the service is working properly:

# ntpq -p
1 Star2 Stars3 Stars4 Stars5 Stars (No Ratings Yet)

Leave a Reply

Please Login to comment
1 Comment threads
1 Thread replies
Most reacted comment
Hottest comment thread
2 Comment authors
CertDepotansuya Recent comment authors
newest oldest
Notify of


I applied this configuration of NTP in my RHCSA exam.
But in RHCE exam requirements we are asking for “peers sychronizing”.
Where is the peer sychronizing in your post?
The line in ntpd.conf, like this:
peer address

Can you explain clearly difference of this 2 directives:
peer address
## and
server address

Upcoming Events (Local Time)

  1. Jan

    1. 9:00 am - View Details
      CentOS: Dojo, Brussels, Belgium.

RHCSA7: Task of the day

Allowed time: 5 minutes.
Configure a cron task to write the uptime at 2PM every day.

RHCE7: Task of the day

Allowed time: 8 minutes.
Set up an iScsi target based on a block backstore of 100MB called lv_iscsi with basic authentication, ext4 filesystem and standard firewall configuration.

Follow me on Twitter

Poll for favorite RHEL 7 book

What is your favorite RHEL 7 book to prepare RHCSA & RHCE exams?

View Results

Loading ... Loading ...

Poll for most difficult RHCSA 7 topic

What do you think is the most difficult RHCSA 7 topic?

View Results

Loading ... Loading ...

Poll for most difficult RHCE 7 topic

What do you think is the most difficult RHCE 7 topic?

View Results

Loading ... Loading ...