Computer Network Design EEL 6785 Dr. Janusz Zalewski University of Central Florida.

Slides:



Advertisements
Similar presentations
Lecture 1: Logical, Physical & Casual Time (Part 2) Anish Arora CSE 763.
Advertisements

How does a network identify computers and transmissions?
Time in Distributed Systems
HIERARCHY REFERENCING TIME SYNCHRONIZATION PROTOCOL Prepared by : Sunny Kr. Lohani, Roll – 16 Sem – 7, Dept. of Comp. Sc. & Engg.
Distributed Systems CS Synchronization Lecture 6, Sep 26, 2011 Majd F. Sakr, Vinay Kolar, Mohammad Hammoud.
Network Time Protocol (NTP) August 9 th 2011, OSG Site Admin Workshop Jason Zurawski – Internet2 Research Liaison.
CS6223: Distributed Systems Distributed Time and Clock Synchronization (1) Physical Time.
Computer Science 425 Distributed Systems CS 425 / ECE 428  2013, I. Gupta, K. Nahrtstedt, S. Mitra, N. Vaidya, M. T. Harandi, J. Hou.
CSE 486/586, Spring 2013 CSE 486/586 Distributed Systems Time and Synchronization Steve Ko Computer Sciences and Engineering University at Buffalo.
Time and Global States Ali Fanian Isfahan University of Technology
Distributed Systems Fall 2010 Time and synchronization.
Internet Networking Spring 2006 Tutorial 12 Web Caching Protocols ICP, CARP.
Time Synchronization (RBS, Elson et al.) Presenter: Peter Sibley.
1 University of Freiburg Computer Networks and Telematics Prof. Christian Schindelhauer Wireless Sensor Networks 15th Lecture Christian Schindelhauer.
Distributed Systems CS Synchronization – Part II Lecture 8, Sep 28, 2011 Majd F. Sakr, Vinay Kolar, Mohammad Hammoud.
(Remote Access Security) AAA. 2 Authentication User named "flannery" dials into an access server that is configured with CHAP. The access server will.
Chapter 5 – TCP/IP: Part 4 Dr. V.T. Raja Oregon State University.
1 University of Freiburg Computer Networks and Telematics Prof. Christian Schindelhauer Wireless Sensor Networks 13th Lecture Christian Schindelhauer.
Lecture 9: Time & Clocks CDK4: Sections 11.1 – 11.4 CDK5: Sections 14.1 – 14.4 TVS: Sections 6.1 – 6.2 Topics: Synchronization Logical time (Lamport) Vector.
Gursharan Singh Tatla Transport Layer 16-May
Lecture 2-1 CS 425/ECE 428 Distributed Systems Lecture 2 Time & Synchronization Reading: Klara Nahrstedt.
Network Topologies.
1 Physical Clocks need for time in distributed systems physical clocks and their problems synchronizing physical clocks u coordinated universal time (UTC)
Tanenbaum & Van Steen, Distributed Systems: Principles and Paradigms, 2e, (c) 2007 Prentice-Hall, Inc. All rights reserved DISTRIBUTED SYSTEMS.
Enhanced NTP IETF – TicToc BOF Greg Dowd – Jeremy Bennington –
A Security Analysis of the Network Time Protocol (NTP) Presentation by Tianen Liu.
176 Introduction to Network Time Protocol (NTP) Version A.01 H3065S Module 15 Slides.
INSTALLING MICROSOFT EXCHANGE SERVER 2003 CLUSTERS AND FRONT-END AND BACK ‑ END SERVERS Chapter 4.
GPS based time synchronization of PC hardware Antti Gröhn
Computer Science Lecture 10, page 1 CS677: Distributed OS Last Class: Naming Name distribution: use hierarchies DNS X.500 and LDAP.
Time and Coordination March 13, Time and Coordination What is time? :-)  Issue: How do you coordinate distributed computers if there is no global.
Parallel and Distributed Simulation Synchronizing Wallclock Time.
Application Layer Khondaker Abdullah-Al-Mamun Lecturer, CSE Instructor, CNAP AUST.
CE Operating Systems Lecture 3 Overview of OS functions and structure.
Dr. Hugh Melvin, Dept. of IT, NUI,G1 Clock Synchronisation for RTS.
UNIT - III. Time Server It is a daemon that runs on one machine and to which other systems synchronize their system clocks. It is a service that provides.
Outline for Today Objectives: –Time and Timers Administrative details: –Talk on learning at 4 in 130 North Building –Questions?
 High-Availability Cluster with Linux-HA Matt Varnell Cameron Adkins Jeremy Landes.
1 Clock Synchronization & Mutual Exclusion in Distributed Operating Systems Brett O’Neill CSE 8343 – Group A6.
Lecture 9: Time and clocks (Chap 11) Haibin Zhu, PhD. Assistant Professor Department of Computer Science Nipissing University © 2002.
Time This powerpoint presentation has been adapted from: 1) sApr20.ppt.
70-293: MCSE Guide to Planning a Microsoft Windows Server 2003 Network, Enhanced Chapter 12: Planning and Implementing Server Availability and Scalability.
Tanenbaum & Van Steen, Distributed Systems: Principles and Paradigms, 2e, (c) 2007 Prentice-Hall, Inc. All rights reserved DISTRIBUTED SYSTEMS.
Distributed Systems Lecture 5 Time and synchronization 1.
CSE 486/586 CSE 486/586 Distributed Systems Time and Synchronization Steve Ko Computer Sciences and Engineering University at Buffalo.
Chapter 16 Client/Server Computing Dave Bremer Otago Polytechnic, N.Z. ©2008, Prentice Hall Operating Systems: Internals and Design Principles, 6/E William.
Page 1 Clock Synchronization: Physical Clocks Minqi Zhou Distributed Systems Except as otherwise noted, the content of this presentation.
NTP in UBuntu. The Network Time Protocol (NTP) is a protocol for synchronizing the clocks of computer systems over packet-switched, variable- latency.
Outline for Today Objectives: –Time and Timers Administrative details: –About the final…
Topic 7: Time and Global State Dr. Ayman Srour Faculty of Applied Engineering and Urban Planning University of Palestine.
Dynamic Host Configuration Protocol
Distributed Computing
Infrastructure II NTP.
Lecture 5 Time and synchronization
CSE 486/586 Distributed Systems Time and Synchronization
Net 435: Wireless sensor network (WSN)
Dept. of Computer Science
IEEE 1588 Conference and Plug-fest Winterthur, October 10-12, 2005
Logical time (Lamport)
Clock Synchronization: Physical Clocks
Presentation by Wyatt Zacharias
NTP Clock Discipline Modelling and Analysis
Chapter 2: System Structures
DISTRIBUTED SYSTEMS Principles and Paradigms Second Edition ANDREW S
CDK: Sections 11.1 – 11.4 TVS: Sections 6.1 – 6.2
Logical time (Lamport)
Logical time (Lamport)
What’s the Time? Geoff Huston APNIC.
Logical time (Lamport)
Presentation transcript:

Computer Network Design EEL 6785 Dr. Janusz Zalewski University of Central Florida

Network Time Protocol NTP stands for Network Time Protocol, and it is an Internet protocol used to synchronize the clocks of computers to some time reference. SNTP (Simple Network Time Protocol) is basically also NTP, but lacks some internal algorithms that are not needed for all types of servers.

Supported Operating Systems The implementation works for most popular Unix operating systems. Among these are: Aix, Hp-Ux, Iris, Linux, Sco Unix, Osf/1, Solaris, and Windows.

Basic Concepts The smallest possible increase of time the clock model allows is called resolution. If your clock increments its value only once per second, your resolution is also one second. A high resolution does not help you anything if you can't read the clock. Therefore the smallest possible increase of time that can be experienced by a program is called precision. When repeatedly reading the time, the difference may vary almost randomly. The difference of these differences (second derivation) is called jitter.

A clock not only needs to be read, it must be set, too. The accuracy determines how close the clock is to an official time reference like UTC. Even if the systematic error of some clock model is known, the clock will never be perfect. This is because the frequency varies over time, mostly influenced by temperature, but it could also be air pressure or magnetic fields, etc. Reliability determines the time a clock can keep the time within a specified accuracy.

Network Protocols used by NTP: NTP uses UDP packets for data transfer because of the fast connection setup and response times. The official port number for the NTP (that ntpd and ntpdate listen and talk to) is 123.

NTP Configuration (“Stratum”) S3 S2 S4S3 ** Workstation (a) S1 S2 ** S1 * * to buddy (S2) S2 Clients (c) Clients (b)

NTP Configuration (“Stratum”) (a) Workstations use multicast mode with multiple department servers (b) Department servers use client/server modes with multiple campus servers and symmetric modes with each other (c) Campus servers use client/server modes with up to six different external primary servers and symmetric modes with each other and external secondary (buddy) servers

The stratum is a measure for synchronization distance. Opposed to jitter or delay, the stratum is a more static measure. Basically (and from the perspective of a client) it is the number of servers to a reference clock. So a reference clock itself appears at stratum 0, while the closest servers are at stratum 1.

A server operating at stratum 1 is the best NTP server available, because it has a reference clock attached to it. As accurate reference clocks are expensive, only rather few of these servers are publically available.

Time can be passed from one time source to another, typically starting from a reference clock connected to a stratum 1 server. Servers synchronized to a stratum 1 server will be stratum 2. Generally the stratum of a server will be one more than the stratum of its reference.

NTP/Reference Clock A reference clock is some device or machinery that provides the current time. Its special property is high accuracy. Reference clocks must be accurately following some time standard.

A reference clock provides the current time. NTP computes some additional statistical values that describe the quality of time it sees: offset, jitter (or dispersion), frequency error, and stability.

Thus each NTP server will maintain an estimate of the quality of its reference clocks and of itself.

Basic Features: NTP needs some reference clock that defines the true time to operate. All clocks are set towards that true time.

NTP uses UTC as reference time. UTC ( Universal Time Coordinated, “Temps Universel Coordonne” ) is an official standard for the current 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 clock. Each node of such a network can exchange time information either bi-directional or unidirectional.

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.

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.

How NTP Works? NTP Messages Peer 1 Peer 2 Filter 1 Peer 3 Filter 2 Filter 3 Intersection and Clustering Algorithms Combining Algorithm Loop Filter VFO Timestamps P/F-Lock Loop

Multiple synchronization peers provide redundancy and diversity. Clock filters select best from a window of eight clock offset samples. Intersection and clustering algorithms pick best subset of servers believed to be accurate and fault-free.

Combining algorithm computes weighted average of offsets for best accuracy. Phase/frequency-lock feedback loop disciplines local clock time and frequency to maximize accuracy and stability.

Implementations on NTP/Unix : The software is available as C source and consists of the following components: ntpd: A daemon process that is both, client and server. ntpdate: A utility to set the time once, similar to the popular rdate command. ntpq, ntpdc: Monitoring and control programs that communicate via UDP with ntpd. ntptrace: A utility to back-trace the current system time, starting from the local server.

How will NTP discipline the Clock? ntpd: The ntpd program is an operating system daemon which sets and maintains the system time of day in synchronism with Internet standard time servers. xntpd: running xntpd will learn and remember the clock drift and it will correct it autonomously, even if there is no reachable server. Therefore large clock steps can be avoided while the machine is synchronized to some reference clock. In addition xntpd will maintain error estimates and statistics, and finally it can offer NTP service for other machines.

In order to keep the right time, xntpd must make adjustments to the system clock. There are four mechanisms ( system calls ) an NTP implementation can use to discipline the system clock: settimeofday( ), adjtime( ), ntp_adjtime( ), hardpps( ).

1) settimeofday( ) to step (set) the time. This method is used if the time if off by more than 128ms. 2) adjtime( ) to slew (gradually change) the time. Slewing the time means to change the virtual frequency of the software clock to make the clock go faster or slower until the requested correction is achieved. Slewing the clock for a larger amount of time may require some time, too.

3) ntp_adjtime( ) to control several parameters of the software clock. 4) hardpps( ) is a function that is only called from an interrupt service routine inside the operating system. If enabled, hardpps( ) will update the frequency and offset correction of the kernel clock.

Is more than one clock needed? NTP likes to estimate the errors of all clocks. Therefore all NTP servers return the time together with an estimate of the current error. When using multiple time servers, NTP also wants these servers to agree on some time, meaning there must be one error interval where the correct time must be.

Not all NTP servers work as designed in theory. Time sources that are reachable and have a dispersion smaller than the maximum become candidates for time synchronization, thus contributing an error interval.

If these candidates pass another validation test, they become survivors. Basically all values must lie within the error interval the majority of candidates defines. All other time sources are called falsetickers subsequently.

Among the survivors those with significant high dispersion are removed and tagged as outlyers. The final synchronization source is the survivor with the smallest dispersion.

Just one time source will always be trusted Two time sources cannot be split into two parties where one has a majority. For a three-server configuration a failing server will cause the two-server problem to appear.