top of page

Mr. Torvald, do you have the system time?

  • Anne Shroble
  • Apr 24, 2016
  • 3 min read

1. Why is it important to maintain the system time in a Linux distribution?

Linux depends on the system clock to run certain programs at the appointed times. For instance:

  • for accurate time stamps in logs

  • for ensuring that processes run on time

  • and for applications that depend on keeping good time.

Schroder, Carla. "The Latest Network Routers, Software, Management Tools and Information for Enterprise IT Administrators." Enterprise Networking Planet. 22 Jan. 2004. Web. 24 Apr. 2016.

Programs such as cron and at depend on the accuracy of the time setting. If one has an employee time clock connected to the computer, and the time is not correct, the employees may get very unhappy if their paychecks are short.

2. What is the hardware clock?

The hardware clock is like the bios clock which maintains accurate time while the computer is turned off, or in sleep mode. When Linux is booted up, it reads the hardware clock and sets the software clock to the value it retrieves.

3. What is the software clock?

On the other hand, the software clock is part of the OS which is used for most purposes while it is running. This system uses the Coordinated Universal Time (UTC) which is identical to Greenwich mean time (GMT). Greenwich is in England and the time is managed by atomic clocks stationed around the world. I’m throwing in this information for those of us who don’t or didn’t know what atomic clocks are:

National standards agencies in many countries maintain a network of atomic clocks which are intercompared and kept synchronized to an accuracy of 10⁻⁹ seconds per day (approximately 1 part in 1014). These clocks collectively define a continuous and stable time scale, International Atomic Time (TAI). For civil time, another time scale is disseminated, Coordinated Universal Time (UTC). UTC is derived from TAI, but approximately synchronised, by using leap seconds, to UT1, which is based on actual rotation of the Earth with respect to the solar time.

Atomic clock. (n.d.). Retrieved April 24, 2016, from https://en.wikipedia.org/wiki/Atomic_clock

4. What issues result from the lack of time maintenance?

If your computer is connected to a network, and your office is in say Los Angeles, Wisconsin, and you have sister offices in Eastern Europe, the time zones are different, and perhaps you want to control the employee time clock from your Los Angeles office, the time difference will have to be adjusted accordingly. This little hardware clock is run by a battery and the time drifts with the speed of the battery power. Thus for this reason, Linux supports various network protocols for time setting. The most popular is the Network Time Protocol (NTP).

5. What is NTP and how is it used by Linux systems?

NTP is the most common method used to synchronize the software clock in a GNU/Linux system. With the system connected to the Internet, it is designed to mitigate the latency effects between different networks in various parts of the world. The accuracy can usually be maintained within tens of milliseconds over the public Internet. On a local network server, the accuracy can be up to one millisecond.

What are the basic features of NTP?

There exist several protocols to synchronize computer clocks, each having distinguished features. Here is a list of NTP's features:

  • NTP needs some reference clock that defines the true time to operate. All clocks are set towards that true time. (It will not just make all systems agree on some time, but will make them agree upon the true time as defined by some standard.)

  • 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.

  • NTP is highly scalable: A synchronization network may consist of several reference clocks. Each node of such a network can exchange time information either bidirectional or unidirectional. Propagating time from one node to another forms a hierarchical graph with reference clocks at the top.

  • Having available several time sources, NTP can select the best candidates to build its estimate of the current time. The protocol is highly accurate, using a resolution of less than a nanosecond (about 2^-32 seconds). (The popular protocol used by rdate and defined in [RFC 868] only uses a resolution of one second).

  • 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.

4. What is NTP? (n.d.). Retrieved April 24, 2016, from http://www.ntp.org/ntpfaq/NTP-s-def.htm

So, there it is in a nut shell. Should be a SSH. Anyway, I hope this blog was interesting for you.

Once again, “Happy Researching”.


 
 
 

Commentaires


Featured Posts
Recent Posts
Archive
WHATEVER THE WEATHER
INSPIRATION
Follow Me

    This is the day the Lord has made;

    let us rejoice and be glad in it.

       -Psalm 118:24     

     

     

    Whatever you do,

    work at it with all your heart,

    as working for the Lord,

    not for men.

    - Colossians 3:23     

     

    • LinkedIn - Black Circle

     

     

    E-mail: 

    anne_shroble@sbcglobal.net

    © 2023 BY FREE LINE CREATIVE STUDIO. PROUDLY MADE BY WIX.COM

    bottom of page