Fedora 19 Linux OS: Time And Date Synchronization with NTP

Fedora 19 Linux based operating system distribution can be network-synchronized for time and date over Internet by using NTP (Network Time Protocol) protocol. For more information about NTP, one may read over here: http://www.ntp.org/ . However, I found that the open source software (or package) named ntp, that provides NTP functionality, is not installed on my Fedora 19 system by default. So any changes to Date and Time settings by going through gnome settings panel was not working.  To address this, I installed and enabled NTP as follows:

Run the following command as the root user to install ntp software:

$yum install ntp

yum is the package manager and one may read about it over here https://fedoraproject.org/wiki/Yum to understand more about it.

If you are not the root user, but have sudo permission (more on sudo : http://www.linux.com/learn/tutorials/306766:linux-101-introduction-to-sudo) , run the following command to install ntp software:

$sudo yum install ntp

This command with sudo will prompt for your password.

Once the ntp software is installed, enable this software as follows:

$systemctl enable ntpd.service

This command will run NTP daemon (or background process) always whenever the system boots. systemctl command is part of an open source software named systemd which acts as an init (PID 1) process on Linux based systems. In other words, systemd is the first user space process that is the parent of all other processes on systemd-enabled Linux based systems. systemd manages other processes in Fedora (and many other Linux based distributions) in addition to starting them at the system boot time. More on systemd may be read over here: http://en.wikipedia.org/wiki/Systemd . ntpd.service is a systemd service file which is used by systemd to start the ntp process at boot time. systemd also uses this service file to manage ntp process at other times after the system has booted.

Now to run the ntp process, please run the following command:

$systemctl start ntpd.service

This will start ntp process (or service) in the background.  Please note that this command is only run once. This command is not to be run in future after system reboots, as systemd will take care of starting this ntp process.

This entry was posted in Technology and tagged . Bookmark the permalink.

Leave a Reply

Your email address will not be published.