分布式系统与管理chapter_Synchronization.ppt

分布式系统与管理chapter_Synchronization.ppt

  1. 1、本文档共130页,可阅读全部内容。
  2. 2、原创力文档(book118)网站文档一经付费(服务费),不意味着购买了该文档的版权,仅供个人/单位学习、研究之用,不得用于商业用途,未经授权,严禁复制、发行、汇编、翻译或者网络传播等,侵权必究。
  3. 3、本站所有内容均由合作方或网友上传,本站不对文档的完整性、权威性及其观点立场正确性做任何保证或承诺!文档内容仅供研究参考,付费前请自行鉴别。如您付费,意味着您自己接受本站规则且自行承担风险,本站不退款、不进行额外附加服务;查看《如何避免下载的几个坑》。如果您已付费下载过本站文档,您可以点击 这里二次下载
  4. 4、如文档侵犯商业秘密、侵犯著作权、侵犯人身权等,请点击“版权申诉”(推荐),也可以打举报电话:400-050-0827(电话支持时间:9:00-18:30)。
查看更多
分布式系统与管理chapter_Synchronization.ppt

Distributed Systems Synchronization Yingchi Mao Outline Clock Synchronization Mutual Exclusion Election Algorithms Clock Synchronization Physical Clocks Logical Clocks Vector timestamps Why is it important ? Need to measure accurately E.g., auditing in e-commerce Algorithms depending on E.g., consistency, make Correctness of distributed systems frequently hinges upon the satisfaction of global system invariants. E.g., Absence of deadlocks Write access to a distributed database never granted to more than one process the sum of all account debits and ATM payments in an electronic cash system is zero Objects are only subject to garbage collection when no further reference to them exists E.g., UNIX make program When each machine has its own clock, an event that occurred after another event may nevertheless be assigned an earlier time. Physical Clocks Time Synchronization Algorithms Cristian’s method The Berkeley Algorithm The Network Time Protocol 时间简史 人类生活有紧密联系的太阳的运动是比较均匀 地球自传是一天,公转是一年 天文计量,自从17世纪机械钟表发明. GMT (Greenwich Mean Time) 太阳到达天空中它出现的最高点时称为中天 两次连续的太阳中天之间的时间称为一个太阳日 每天有24小时,每小时有3600秒, 1/86400个太阳日是太阳秒 物理计量,20世纪40年代 1秒是铯133原子作9,192,631,770次跃迁所用的时间 BIH (Bureau International de l’Heure)将这些值平均起来产生国际原子时间,简称为TAI (International Atomic Time) TAI和太阳秒计时之间的差增加到800毫秒时使用一次闰秒,修正后的时间系统称作统一协调时间,简称UTC (Universal Coordinated Time) Physical Clocks A high-frequency oscillator, counter, and holding register Counter decrements on each oscillation, generates a “tick” and is reset from the holding register when it goes to 0. On a network, clocks will differ: “skew”. Two problems: How do we synchronize multiple clocks to the “real” time? How do we synchronize with each other? Measuring Time How long is a second? How long is a day? One solar day is 86,400 solar seconds. Some variation in the rotational speed of the earth: mean solar second. A Solar Day Computation of the mean solar day. Changes Big problem: the earth’s rotation is slowing. Seconds are getting longer. Is this acceptable f

文档评论(0)

000 + 关注
实名认证
内容提供者

该用户很懒,什么也没介绍

1亿VIP精品文档

相关文档