Transcription of Distributed Systems CIS 505: Software Systems Introduction ...
1 11 CIS 505: Software SystemsIntroduction to Distributed SystemsInsup LeeDepartment of Computer and Information ScienceUniversity of PennsylvaniaCIS 505, Spring 2007 CIS 505, Spring 2007 Distributed Systems2 Distributed Systems Why Distributed Systems ?oavailability of powerful yet cheap microprocessors (PCs,workstations, PDAs, embedded Systems , etc.)ocontinuing advances in communication technology What is a Distributed system ?oA Distributed system is a collection of independentcomputers that appear to the users of the system as a singlecoherent 505, Spring 2007 Distributed Systems3 Examples The world wide web information, resourcesharing Clusters, Network of workstations Distributed manufacturing system ( ,automated assembly line) Network of branch office computers -Information system to handle automaticprocessing of orders Network of embedded Systems New Cell processor (PlayStation 3)
2 CIS 505, Spring 2007 Distributed Systems4 Advantages and disadvantages AdvantagesoEconomicsoSpeedoInherent distributionoReliabilityoIncremental growth DisadvantagesoSoftwareoNetworkoMore components to failoSecurity2 CIS 505, Spring 2007 Distributed Systems5 Organization of a Distributed SystemA Distributed system organized as that the middleware layer extends over multiple 505, Spring 2007 Distributed Systems6 Goals of Distributed Systems Transparency Openness Reliability Performance ScalabilityCIS 505, Spring 2007 Distributed Systems7 Transparency How to achieve the single- system image, ,how to make a collection of computersappear as a single computer. Hiding all the distribution from the users aswell as the application programs can beachieved at two levels:1)hide the distribution from users2)at a lower level, make the system looktransparent to ) and 2) requires uniform interfaces such as accessto files, 505, Spring 2007 Distributed Systems8 Transparency in a Distributed SystemDifferent forms of transparency in a Distributed whether a ( Software )
3 Resource is in memory or on diskPersistenceHide the failure and recovery of a resourceFailureHide that a resource may be shared by several competitiveusersConcurrencyHide that a resource may be shared by several competitiveusersReplicationHide that a resource may be moved to another location whilein useRelocationHide that a resource may move to another locationMigrationHide where a resource is locatedLocationHide differences in data representation and how a resource isaccessedAccessDescriptionTransparency3 CIS 505, Spring 2007 Distributed Systems9 Openness Make it easier to build and change Monolithic Kernel: Systems calls are trapped andexecuted by the kernel. All system calls are servedby the kernel, , UNIX. Microkernel: provides minimal services. IPC some memory management some low-level process management and scheduling low-level i/o ( , Mach can support multiple file Systems ,multiple system interfaces.)
4 Standard interface, separation of policy frommechanismCIS 505, Spring 2007 Distributed Systems10 Reliability Distributed system should be more reliablethan single system . Availability: fraction of time the system is improves it. Need to maintain consistency Need to be secure Fault tolerance: need to mask failures, recover from errors. Example: 3 machines with .95 probability ofbeing up ( )**3 vs **3 probability of being upCIS 505, Spring 2007 Distributed Systems11 Performance Without gain on this, why bother with distributedsystems. Performance loss due to communication delays: fine-grain parallelism: high degree of interaction coarse-grain parallelism Performance loss due to making the systemfault 505, Spring 2007 Distributed Systems12 Scalability Systems grow with time or become obsolete. Techniques that require resources linearly in terms ofthe size of the system are not scalable.
5 ( ,broadcast based query won't work for largedistributed Systems .) Examples of bottlenecks ( , scalability limitations)oCentralized components: a single mail serveroCentralized tables/data: a single URL address bookoCentralized algorithms: routing based on complete information4 CIS 505, Spring 2007 Distributed Systems13 Scalability ProblemsCharacteristics of decentralized algorithms: No machine has complete information aboutthe system state. Machines make decisions based only onlocal information. Failure of one machine does not ruin thealgorithm. There is no implicit assumption that a globalclock 505, Spring 2007 Distributed Systems14 Scaling Techniques (1) difference between letting:a)a server orb)a client check forms as they are being filledCIS 505, Spring 2007 Distributed Systems15 Scaling Techniques (2) example of dividing the DNS name space into 505, Spring 2007 Distributed Systems16 Pitfalls when Developing Distributed SystemsFalse assumptions made by first time developer: The network is reliable.
6 The network is secure. The network is homogeneous. The topology does not change. Latency is zero. Bandwidth is infinite. Transport cost is zero. There is one 505, Spring 2007 Distributed Systems17 Hardware basic organizations and memories in distributedcomputer Systems : multiprocessors vs. multicomputersCIS 505, Spring 2007 Distributed Systems18 Multiprocessors (1)A bus-based multiprocessoroCache memory, hit rate, coherence, write-throughcache, snoopy 505, Spring 2007 Distributed Systems19 Multiprocessors (2)a)A crossbar switchb)An omega switching 505, Spring 2007 Distributed Systems20 Homogeneous Multicomputer Systemsa)Gridb)Hypercube1-9 Tightly coupled vs. loosely coupled6 CIS 505, Spring 2007 Distributed Systems21 How slow is the network? ping Round-trip timesoUpenn .5msoPrinceton 5msoRice 43msoStanford 80msoTsinghua, Beijing 280msCIS 505, Spring 2007 Distributed Systems22 Communication Latency Latency wire delay oTime to send and recv one byte of dataoDepends on distance BandwidthoBytes/secondoDepends on size of vehicle Latency is the bottleneckoIt improves slower than bandwidth Speed of light Routers in the middle (traffic stops)oRequest-respond cycles dominate applicationCIS 505, Spring 2007 Distributed Systems23 The speed pyramid Will the ratios change?
7 20,000,000 WAN2,000,000 Disk100,000 LAN200 Memory10L21registerCIS 505, Spring 2007 Distributed Systems24 Continuum of Distributed Systems ??smallfastbigslowLANG lobalInternetParallelArchitectureshigh latencylow bandwidthautonomous nodesunreliable networkfear and distrustindependent failuresdecentralized administrationNetworksIssues:naming and sharingperformance and scaleresource managementlow latencyhigh bandwidthsecure, reliable interconnectno independent failurescoordinated resourcesMultiprocessorsclustersfast networktrusting hostscoordinatedslow networkuntrusting hostsautonomy[J. Chase]7 CIS 505, Spring 2007 Distributed Systems25 Types of Distributed Systems Distributed Computing Systems Distributed information Systems Distributed Pervasive/Embedded SystemsCIS 505, Spring 2007 Distributed Systems26 Cluster Computing Systems Figure 1-6.
8 An example of a cluster computing 505, Spring 2007 Distributed Systems27 Grid Computing Systems Figure 1-7. A layered architecture for grid 505, Spring 2007 Distributed Systems28 Transaction Processing Systems (1) Figure 1-8. Example primitives for 505, Spring 2007 Distributed Systems29 Transaction Processing Systems (2)Characteristic properties of transactions: Atomic: To the outside world, thetransaction happens indivisibly. Consistent: The transaction does notviolate system invariants. Isolated: Concurrent transactions do notinterfere with each other. Durable: Once a transaction commits,the changes are 505, Spring 2007 Distributed Systems30 Transaction Processing Systems (3) Figure 1-9. A nested 505, Spring 2007 Distributed Systems31 Enterprise Application Integration Figure 1-11. Middleware as a communication facilitator inenterprise application 505, Spring 2007 Distributed Systems32 Distributed Pervasive SystemsRequirements for pervasive Systems Embrace contextual changes.
9 Encourage ad hoc composition. Recognize sharing as the 505, Spring 2007 Distributed Systems33 Embedded Home EnvironmentCIS 505, Spring 2007 Distributed Systems34 Example: Home and Personal AppliancesYr~2025~2015 Volume /Diversity2005 Smart homes, home theaters,games, smart cars, devices, tools,appliances and softwarefor assisted livingHome carefacilities[Liu]CIS 505, Spring 2007 Distributed Systems35 Justifications Rapid advances in component technologies, ,oSmart gadgets, wearable sensors and actuators,robotic helpers, mobile devicesoWireless, wideband interconnects Increasing critical needs due tooAging baby-boom generationoLong life expectancyoNew safety, security, and privacy concernsCIS 505, Spring 2007 Distributed Systems36 Observations Number of users: 10 1000 million Types of sensors and actuators: 100 s Number of suppliers.
10 10 100 s Required reliability: <10,000 recalls/year User tolerance to glitches: minimum Product life cycles: 3 20 yrs Tolerable upgrade effort: minimumThe environment must be open and evolvable, & capable of self diagnosis, healing, maintenance10 CIS 505, Spring 2007 Distributed Systems37 Desired Trends~20152005~2025 Volume&DiversityQuality&UsabilityUnit costMaintenancecostCIS 505, Spring 2007 Distributed Systems38 Electronic Health Care Systems (1)Questions to be addressed for health care Systems : Where and how should monitored data bestored? How can we prevent loss of crucial data? What infrastructure is needed to generate andpropagate alerts? How can physicians provide online feedback? How can extreme robustness of the monitoringsystem be realized? What are the security issues and how can theproper policies be enforced?