what is NTP

Description of your first forum.
Post Reply
evanisaac982
Posts: 9
Joined: Thu Jan 22, 2015 4:40 pm

what is NTP

Post by evanisaac982 » Thu Aug 27, 2015 2:46 pm

Hello Everyone,

Any one know about NTP what is it and how to install it.

Thanks.

kevinchristian381
Posts: 11
Joined: Thu Jan 22, 2015 4:33 pm

Re: what is NTP

Post by kevinchristian381 » Wed Sep 02, 2015 5:36 pm

NTP stands for Network Time Protocol and is a service that runs on the Linux operating system that synchronizes the system time with with a centralized NTP server.

Configure NTP server

1. Install NTP Server

First, install NTP package on server using the appropriate package tool that is available on Linux.

For example, on RedHat or CentOS, use yum to install ntp as shown below:

yum install ntp

2. Restrict values in ntp.conf

Modify the /etc/ntp.conf file to make sure it has the following two restrict lines.

# Permit time synchronization with our time source, but do not
# Permit the source to query or modify the service on this system.
restrict default kod nomodify notrap nopeer noquery
restrict -6 default kod nomodify notrap nopeer noquery


The first restrict line allows other clients to query your time server.

This restrict line has the following parameters
noquery -prevents dumping status data from ntpd.
notrap -prevents control message trap service.
nomodify -prevents all ntpq queries that attempts to modify the server.
nopeer -prevents all packets that attempts to establish a peer association.
Kod – Kiss-o-death packet is to be sent to reduce unwanted queries
The value -6 in the second line allows forces the DNS resolution to the IPV6 address resolution.


3. Allow Only Specific Clients

Add the following restrict line to your /etc/ntp.conf file:

Restrict 192.168.1.0 mask 255.255.255.0 nomodify notrap
If the localhost needs to have the full access to query or modify, add the following line to /etc/ntp.conf
Restrict 127.0.0.1

4. Add Local Clock as Backup

Add the local clock to the ntp.conf file so that if the NTP server is disconnected from the internet, NTP server provides time from its local system clock.

server 127.127.1.0 # local clock
fudge 127.127.1.0 stratum 10



Stratum is used to synchronize the time with the server based on distance.
A stratum-1 time server acts as a primary network time standard.
A stratum-2 server is connected to the stratum-1 server over the network.


5. Setup NTP Log Parameters

Identify the drift file and the log file location in your ntp.conf file

driftfile /var/lib/ntp/ntp.drift
logfile /var/log/ntp.log



6. Start the NTP Serrver

After setting up proper values in the ntp.conf file, start the ntp service:

service ntpd start

II. Configure NTP Client to Synchronize with NTP Server

7. Modify ntp.conf on NTP Client

This setup should be done on NTP Client (Not on NTP-server)

To synchronize the time of local Linux client machine with NTP server,
edit the /etc/ntp.conf file on the client side.

server 0.rhel.pool.ntp.org iburst
server 1.rhel.pool.ntp.org iburst


iburst: After every poll, a burst of eight packets is sent instead of one. When the server is not responding, packets are sent 16s interval. When the server responds, packets are sent every 2s.

Edit your NTP.conf to reflect appropriate entries for NTP server.

server 19.168.1.1 prefer
prefer: If this option is specified that server is preferred over other servers.

8. Start the NTP Daemon

start the ntp daemon.

/etc/init.d/ntp start

9. Check the NTP Status

Check the status of NTP using the ntpq command.

10. Set Local Date and Time

The ntpdate command can be used to set the local date and time by polling the NTP server.

bakerashley127
Posts: 10
Joined: Thu Jan 22, 2015 4:17 pm

Re: what is NTP

Post by bakerashley127 » Wed Sep 30, 2015 8:38 pm

NTP (Network Time Protocol) an Internet protocol that used to assures correct synchronization to the millisecond of computer clock times in a network of computers

NTP uses UTC as reference time.

NTP is a fault-tolerant protocol that will automatically select the best of several available time sources to synchronize to. Multiple candidates can be combined to minimize the accumulated error. Temporarily or permanently insane time sources will be detected and avoided.

Even when a network connection is temporarily unavailable, NTP can use measurements from the past to estimate current time and error.

For formal reasons NTP will also maintain estimates for the accuracy of the local time

aaliyahmerilaht
Posts: 9
Joined: Wed Jan 21, 2015 4:31 pm

Re: what is NTP

Post by aaliyahmerilaht » Sat Oct 30, 2021 10:33 am

"Network Time Protocol" is the abbreviation for "Network Time Protocol." NTP (Network Time Mechanism) is a protocol for synchronising computer clocks on various platforms. It allows for synchronisation through both local and wide area networks as well as the Internet.

jacobwallace800
Posts: 8
Joined: Wed Jan 21, 2015 4:59 pm

Re: what is NTP

Post by jacobwallace800 » Sat Dec 11, 2021 5:03 am

The Network Time Protocol (NTP) is a networking protocol that allows computer systems to synchronise their clocks over packet-switched, variable-latency data networks. NTP is one of the earliest Internet protocols still in use, having been in use since before 1985. David L. Mills of the University of Delaware created NTP.

Post Reply