Please enable JavaScript.
Coggle requires JavaScript to display documents.
Lecture 6: Synchronization (Time systems (Universal Time Coordinate (UTC),…
Lecture 6: Synchronization
Time systems
Universal Time Coordinate (UTC)
Synchronize with earth rotation around axis and around the Sun
=> Leap day, leap second
Define timezone, provide local time
Epoch
Serves as a reference point from which time is measured
Unix epoch: 00:00:00 UTC Thursday 1, January 1970
Unix localtime
The number of seconds per day are fixed with Unix time stamps(UNIX time number is zero at the Unix epoch, increases by 86400 per day since epoch
When appearing time leaps (leap years, leap seconds, daylight saving times) a table must be provided to set up time to an appropriate value.
Temps Atomique International (TAI)
Follow principle of General Relativity Theory
Monotone
Physical real time
Universal
: independent from geocentrically effects
is the international atomic time scale based on a continuous counting of the SI seconds.
Time synchronization
Network time protocol
UDP
transmission time = (received time - request time)/2
To synchronize clocks in DS
4 GPS satellites
Global state
Happend-before
Relation between 2 events such that if event A should happen before event B, the result should reflects that.
Even if the they are executed out of order (for optimization)
ordering events based on the potential causal relationship of pairs of events in a concurrent system, especially asynchronous distributed systems.
Vector Clocks
Used in DS to determine whether pairs of events are causally related.
Using vector clocks, time stamps are generated for each event in the system, and their causal relationship is determined by comparing those time stamps
Consistent Cuts
A cut C (snapshot) s.t with all event e in C, if event f happend-before e, then f belong to C also.
Catch all events happened before f.
Mutual Exclusion
Liveness: A process P requests to enter the critical section and eventually succeeds,
startvation free, deadlock free
Ordering: Request from process P to enter the critical section follow the happended-before relationship.
Safety: At most one process
p
may execute at a critical section in a given interval time.
Simultaneous receiving message.
Use Vector clock with Counter from many participants.