1. Distributed Systems
Introduction
Administrivia
Books and references
1 Distributed systems: Principles and Paradigms - Tanenbaum
and Steen.
2 Distributed systems - Colouris, Dollimore and Kindberg.
3 Advanced concepts in OS - Shivaratri and Singhal.
4 Distributed Computing: Principles, Algorithms, and Systems -
Kshemkalyani and Singhal.
5 http://web.cse.iitk.ac.in/users/cs632
R. K. Ghosh Distributed Systems
4. Distributed Systems
Introduction
Definition of distributed systems
Definition 1
A distributed system: your computer
becomes unusable due to failure of a
computer you did not even know existed.
Notable contributions in DS
Clock in DS and ordering of events.
Byzantine problem
Distributed snapshot
Paxos algorithm for consensus.
R. K. Ghosh Distributed Systems
5. Distributed Systems
Introduction
Definition of distributed systems
Definition 2
A collection of computers not sharing a common memory or a
common physical clock that communicate by messages over a
communication network and where each computer has its own
memory and runs on its own OS. Typically computers are
semi-automatic, loosely coupled when they cooperate to address a
problem collectively.
R. K. Ghosh Distributed Systems
6. Distributed Systems
Introduction
Definition of distributed systems
Definition 3
A collection of independent computers that appears to the users of
the system as a single coherent computer.
R. K. Ghosh Distributed Systems
7. Distributed Systems
Introduction
Definition of distributed systems
Definition 4
A term used to describe a wide range of computer systems from
weakly coupled system such as a wide area network, to strongly
coupled systems such as local area network, to very strongly
coupled mulitprocessor systems.
R. K. Ghosh Distributed Systems
9. Distributed Systems
Introduction
Characteristics of a DS
1 Consists of many autonomous components.
2 Users think that they are dealing with a single system.
Autonomous entities must collaborate for developing DS
applications.
And collaboration mostly hidden from end users.
R. K. Ghosh Distributed Systems
10. Distributed Systems
Introduction
Users prospectives
Single system view
1 Communication among computers is hidden.
2 Internal organization is hidden
3 Users & applications interact with DS in a consistent and
uniform way regardless of where and when interaction occurs.
4 Scaling is inherent, easy to expand.
5 Resilence to partial failures (hidden from user).
Parts can be replaced, repaired and temporarily out of order.
R. K. Ghosh Distributed Systems
11. Distributed Systems
Introduction
Users prospectives
DS is Middleware
Single system view is provided by organizing DS using many
layers of abstractions between user/application and
OS/communication layer underneath.
So, DS sometimes known as middleware.
R. K. Ghosh Distributed Systems
12. Distributed Systems
Introduction
Goals of DS
Remote resource accessibility
Obvious reason is economics.
Collaboration becomes easy.
Cost of sharing and connectivity: security
More connectivity increases vulnerability towards hacking.
With tracking building user profile is possible.
How secure are credit cards transactions?
R. K. Ghosh Distributed Systems
13. Distributed Systems
Introduction
Goals of DS
Transparency
Access Data access/representation Web, SQL queries.
Location Resource locations Web pages, tables
in Dist. DB
Migration Resource relocation during use Web pages
Relocation Resource relocation Web pages
Replication Replication of resources DDBMS, Mirrors
Concurrency Sharing resource (lock) ATM, DBMS.
Failures Failure and recovery DBMS
Persistence Resource in memory or on disk S/W
R. K. Ghosh Distributed Systems
14. Distributed Systems
Introduction
Goals of DS
Degree of transparency
Hiding location is not desirable at times.
Hiding latency is not possible.
Hiding failure may force application to slowdown
Hiding replication leads increase in update time.
In mobile distributed system: context and location becomes
important.
Full transparency neither achievable nor desirable.
It should adjust according to performance and information
comprehensibility.
R. K. Ghosh Distributed Systems
15. Distributed Systems
Introduction
Goals of DS
Transparency relationship
scalability
migration
access
performance
replication
location
failure
concurrency
R. K. Ghosh Distributed Systems
16. Distributed Systems
Introduction
Goals of DS
Openness
System should conform to standards
Should be interoperable.
Applications should be portability.
Should be extensible: possible to configure system out of
components from different developers.
Idependent development by third party.
Generalized IDL for specifying services.
Closed systems: older systems evolved out monolithic
programs often tend to be close.
R. K. Ghosh Distributed Systems
17. Distributed Systems
Introduction
Goals of DS
Implementing Openness
Open system: flexibility is key property.
Organized as a collection of small, easy replaceable, adaptable
components.
Degree of openness: Interfaces should exist not only for
users/applications but also for internal parts of system.
Separation: needed between policy and mechanism
User can set web cache size but should not influence policies.
Different trust levels of mobile codes.
Possible to adjust QoS parameters.
Possible to use different encryptions.
R. K. Ghosh Distributed Systems
18. Distributed Systems
Introduction
Goals of DS
Dimensions of scalability
Numerical
(number of nodes)
Geographical
(nodedistances)
Administrative
(domain)
R. K. Ghosh Distributed Systems
19. Distributed Systems
Introduction
Goals of DS
Bottlenecks
Centralized algorithms: routing based on complete info.
Centralized data: single database for telephone numbers.
Centralized server: one server for all users.
R. K. Ghosh Distributed Systems
20. Distributed Systems
Introduction
Goals of DS
Distributed Algorithms
No m/c has complete data
Every m/c makes decisions on local information
Failure of any single m/c does not ruin algorithm
No implicit assumption about global clock.
R. K. Ghosh Distributed Systems
21. Distributed Systems
Introduction
Goals of DS
Geographical scalability
Hard to scale DS algorithm designed for LANs as they are
based on assumption of:
Reliability of network, and make use of
Synchronous communication and use broadcast/multicast.
Other problems of scaling DS algos to WANs are:
Trust/security: multiple administrative domains
Centralized component: affect performance severely.
R. K. Ghosh Distributed Systems
22. Distributed Systems
Introduction
Goals of DS
Scalability techniques
Reduce dependence on remote servers.
Hiding latency by following tricks:
Split problems into independent parts.
Use asynchronous communication.
Rely on local computation.
Breakdown large messages: check syntactical correctness of
requests at client end.
Use replication, caching
R. K. Ghosh Distributed Systems
23. Distributed Systems
Introduction
Goals of DS
Problem of Scaling
Maintaining consistency of replicas.
Needs global synchronization.
Can be avoided by relaxing consistency.
DS algos make too many assumptions concerning reliability,
stability and security of network.
Homogeneous, topology does not change.
Latency is zero, bandwidth is infinite.
No transport cost, and single domain administrators.
R. K. Ghosh Distributed Systems
24. Distributed Systems
Introduction
Parallel/distributed system
Parallel
Tightly coupled, shared
memory
Homogeneous nodes
Global clock control
Interconnection: Tbps
(mesh, tree, hypercube)
Knowledge of network is
advantageous.
Distributed
Loosely coupled, no shared
memory.
Nonhomogeneous nodes
No common clock.
Interconnection: Gbps
(Ethernet, infini band)
Network transparency.
R. K. Ghosh Distributed Systems
25. Distributed Systems
Introduction
Parallel/distributed system
Parallel
Resources: dedicated and
managed by application.
Location of service: mostly
local and known
Application focus: scientific
computation.
Distributed
Resource: uses idle ones,
system managed.
Location of service:
transparent
Application focus:
information/resource sharing
R. K. Ghosh Distributed Systems
27. Distributed Systems
Introduction
Hardware organization
High level classification
M M M M M M M
M M M M
P P P P
P P P P
P P P P
BusbasedSwitchbased
Distributed memory
multiprocessors multicomputers
P P P P
M M M
Shared memory
R. K. Ghosh Distributed Systems
28. Distributed Systems
Introduction
Hardware organization
Multiprocessors
Bus based system has several disadvantages
Performance suffers due to bus contention.
Cache can enhance performance, but cache coherency would
be a problem.
Scalability is low, bus becomes the bottleneck.
Scalability can be solved using cross-bar switches.
Down-side: n2
crosspoint switches will be needed.
Alternative is multistage network: but latency increases due to
multiple switching stages.
R. K. Ghosh Distributed Systems
30. Distributed Systems
Introduction
Hardware organization
Homogeneous multicomputers
Mesh, Hypercube, etc.
Switched multicomputers vary widely
MPPs: thousands of CPUs use high performance proprietry
interconnection netwroks.
Cluster computers: collection standard WS connected through
myrinet boards.
R. K. Ghosh Distributed Systems
32. Distributed Systems
Introduction
Some of common assumptions
Network is homogeneous, reliable and secure.
Topology does not change.
Latency is zero
Bandwidth is infinite.
Transport cost is zero.
One network administrator.
R. K. Ghosh Distributed Systems
33. Distributed Systems
Introduction
Types of distributed systems
Computing system: used for high performance computing
tasks.
Cluster, grid and cloud computing systems.
Information system: used for interoperability of networked
applications
Transaction processing and enterprise application
integration systems.
Distributed embedded systems: used for pervasive
computing.
Mobile and sensor embedded systems.
R. K. Ghosh Distributed Systems
34. Distributed Systems
Introduction
Distributed Computing Systems
Cluster computing system
Component
of parallel
application
Local OSLocal OS
Parallel libs
Management
application
Component
of parallel
application
Local OS
Master compute nodecompute node
standard network
.....
.....
High speed network
Remote access n/w
Used for parallel programming.
Master distributes tasks, interfaces with user, and middleware
runs here.
R. K. Ghosh Distributed Systems
41. Distributed Systems
Introduction
Distributed Computing Systems
Grid layered architecture
services
resources &
access to
secure
directory brokering,
diagnostics, and
monitoring
diverse resources
storage media
such as computers,
networks and sensors
tools and applications Applications
Collective layer
Connectivity layer
Resource and
Febric layer
Febric: interfaces local control.
Connectivity: secure connection.
Resources: sharing a single
resource.
Collective: multiple resource
coordination.
Application: users determine.
R. K. Ghosh Distributed Systems
42. Distributed Systems
Introduction
Distributed Computing Systems
Different views of cloud system
John MacCarthy 1960
. . . computation may someday be organized as public utility . . .
James Obrien
Cloud computing can take on different shapes depending on
viewer, and often seem a little fuzzy on edges
Greg Boss and others IBM
A cloud is a pool of virtualized resources that can host a variety of
different workshloads, allow the workloads to be deployed and
scaled-out quickly, allocate resources when needed and support
redundancy.
R. K. Ghosh Distributed Systems
43. Distributed Systems
Introduction
Distributed Computing Systems
Comparing grid and cloud
Cloud
Reducing computing cost
Flexibility and reliability
Resources assigned not
shared
Virtualization of H/W and
S/W
Security through isolation
Grid
Reducing computing cost
Flexibility and reliability
Resources shared
Virtualization of data and
computing resources.
Security through credential
delegation
R. K. Ghosh Distributed Systems
44. Distributed Systems
Introduction
Distributed Computing Systems
Comparing grid and cloud
Cloud
No highlevel service yet
User chosen architecture
Needs service provider client
s/w
Allows node, site and h/w
scalability
Reconfigurable, autonomic
Flexible payment model
Grid
Plenty of high level services
Service oriented architecture
Needs grid enabled client
s/w
Allows node and site
scalability
Reconfigurable, not
autonomic
Rigid payment model
R. K. Ghosh Distributed Systems
45. Distributed Systems
Introduction
Distributed Computing Systems
Cloud computing system
Refers: infrastructure (IaaS), platform (PaaS) and software
(SaaS) as service types.
Platform: allows dynamic provisioning, configuration,
reconfiguration and deprovsioning of computing resources:
hypervisor service.
Applications: those on internets, any one with a browser can
access: google docs, spread sheets.
Infrastructure: servers, storage systems, networking equipment,
data centre space etc., are pooled and made available to
handle workloads.
R. K. Ghosh Distributed Systems
46. Distributed Systems
Introduction
Distributed Computing Systems
Cloud computing system
Networking
Server
Storage
Virtualization
OS
Middleware
Runtime
Data
Application
SaaS
PaaS
IaaS
Scalable internet based applications
on cloud offered as services to users
applications
for design, development and testing
Platforms provided by cloud infrastr.
on pay per use model.
Storage, database management,
computing are offered as serice
Paas
SaaS
IaaS
Google doc
service
engine
Amazon
EC−2
MS Azure
Google app
R. K. Ghosh Distributed Systems
47. Distributed Systems
Introduction
Distributed Information Systems
Interoperability and middleware
Many networked applications are developed by organizations.
Middleware provides an infrastructure for easy integration of
such applications.
Two important areas of application integrations are
Transaction Processing, and
Enterprise Application Integration.
R. K. Ghosh Distributed Systems
48. Distributed Systems
Introduction
Distributed Information Systems
Transaction processing systems
independent DBs
subtransaction subtransaction
Nested transaction
hotel airline
Simplifies programming, and gives
better performance.
If parent aborts all committed
substransactions should also abort.
If any subtransaction abort parent
must abort.
R. K. Ghosh Distributed Systems
49. Distributed Systems
Introduction
Distributed Information Systems
Transaction processing systems
server
server
server
client
app.
TM
reply
req
req
reply
reply
req
reply
transaction
req
Data is distributed over different
servers.
TM basically works as a
coordinator.
R. K. Ghosh Distributed Systems
50. Distributed Systems
Introduction
Distributed Information Systems
Enterprise application integration
client
application
server side
application
server side server side
application application
application
client
Communication middleware
A generalization of the TM.
Finds use when application are
decoupled from databases.
Applications interact through
communication middleware.
RPC, or
Message Orient Middleware
(MOM)
R. K. Ghosh Distributed Systems
51. Distributed Systems
Introduction
Distributed Pervasive Systems
Low power or energy efficient computing is important.
The system is pervasive or part of our surroundings.
No human administrative control: automatic discovery and
self configuration.
Context aware
Ad hoc composition
Allow sharing.
R. K. Ghosh Distributed Systems
52. Distributed Systems
Introduction
Evolution of Distributed Systems
Distributed
computing
coordination
high availability
fault tolerance
security
remote comm
computing
computing
energy aware system
adaptive and reflective
mobile network
mobility
uneven conditions
standardization
virtualization
federate community
grid
mobile
smart space
localize scalabilty
invisibility
context awareness
pervasive
computing
cloud/global
smart space
R. K. Ghosh Distributed Systems