SlideShare a Scribd company logo
1 of 53
Download to read offline
Inter-Process
Communication
(IPC)
1
Agenda
• Introduction
• Layered Protocols (7 Layers)
• Types of Communication (3 Categories)
• Models for Communication (3 Models)
• The Group Communication and the
Multicasting Communication
2
Introduction
• IPC is at the heart of all distributed systems, so
we need to know the ways that processes can
exchange information.
• Communication in distributed systems is
based on Low-level message passing as
offered by the underlying network.
3
Layered Protocols
Two processes A,B
A wants to communicate with B.
A builds a message in its own address space.
A execute a call to the OS to send the message.
To prevent chaos (mass)
A,B have to agree on the meaning of the bites
being sent.
4
• The International Standards Organization (ISO)
developed a reference model that clearly
identifies the various levels involved
Open Systems Interconnection (OSI).
• It provides a description of how network
hardware and software work together in a
layered fashion to make communications
possible.
5
• Communication divided into 7 layers.
• Each layer has a responsibility to perform
specific tasks but all of the layers are needed
for a message to reach its destination.
• Message send (downwards) Message received
(upwards).
6
Two general type of protocols
• Connection oriented protocols:
Before exchanging data the sender and receiver first
establish a connection, and possibly negotiate the
protocol they will use When they are done, they
must terminate the connection.
The Telephone
• Connectionless protocols:
No setup in advance is needed, The sender just
transmits the first message when it is ready.
The mailbox or mail
7
Presentation Layer
Session Layer
Transport Layer
Network Layer
Data Link Layer
Physical Layer
Application Layer
Layered Protocols
8
Application Layer
• It is the software that the end-user interacts
with.
• It serves as a window through which
application processes can access network
services.
9
Presentation Layer
• Think of it as the network's translator.
• It is responsible for translating the data,
encrypting the data, changing or converting
the character set.
• Manages data compression to reduce the
number of bits that need to be transmitted.
10
Session Layer
• Provides dialog control between
communicating processes, such as which party
is currently talking, when, and for how long.
• Allows users to insert checkpoints into long
transfers.
• In the event of crash, it is necessary to go
back only to the last checkpoint.
11
Transport Layer
• Turns the underlying network into something
that an application developer can use.
• Ensures that packets are delivered error free,
in sequence, and without losses or
duplications.
12
Network Layer
• Addresses the packets and translating logical
addresses and names into physical addresses.
• Determines the route from the source to the
destination computer (Delay-Wise).
13
Data Link Layer
• Groups bits into frames and sees that each
frame is correctly received (checksum), If
checksums differ, requests a retransmission.
• Sends data frames from the network layer to
the physical layer
14
15
Physical Layer
• The physical layer is totally hardware-
oriented.
• It is responsible for transmitting bits (zeros
and ones) from one computer to another.
• Defines the duration of each impulse.
16
Middleware Protocols
• Communications Middleware is the layer that
lies between the operating system and system
applications that allows for communications.
• Sometimes Communications Middleware is
referred to as “plumbing” because it is the
piece that connects two (or more) applications
and allows data to pass through.
17
• Communications Middleware can be cross-
platform, that is, it facilitates communications
between these differing devices.
• We can use a cell phone and a PC here as an
example. They both function in vastly different
capacities, but with Communications
Middleware, are able to “talk” to and “work
with” each other
18
19
Remote Procedure Call
• Many distributed systems have been based on
explicit message exchange between processes
and this exchange must be transparent.
• Problems
 the calling and called procedures run on different
machines, they execute in different address
spaces.
 Parameters and results also have to be passed.
 Either or both machines can crash and each of the
possible failures causes different problems.
count =read (fd, buf, nbytes);
fd is an integer
indicating a file.
buf is an array of
characters into which data
are read.
nbytes is an integer
telling how many bytes to
read.
• By Value
• By Reference
• By Copy and Restore
count =read (fd, buf, nbytes);
Performing read operation in RPC :
1. The client procedure calls the client stub in the normal way.
2. The client stub builds a message and calls the local
operating system
3. The client's as sends the message to the remote as.
4. The remote as gives the message to the server stub.
5. The server stub unpacks the parameters and calls the
server.
6. The server does the work and returns the result to the stub.
7. The server stub packs it in a message and calls its local as.
8. The server's as sends the message to the client's as.
9. The client's as gives the message to the client stub.
10. The stub unpacks the result and returns to the client.
• By Value
• By Reference
• Problems
add(i, j);
• The message format must be defined, the caller
and the callee must agree on the format of the
messages they exchange, and that they follow
the same steps when it comes to.
• The interface language must be the same in
client and server.
• developed by the Open Software Foundation
(OSF).
• DCE RPC is not as popular as some other RPC
systems.
• Initially designed for UNIX, it has now been
ported to all major operating systems including
VMS and Windows variants.
• Idea
Distributed Computing Environment
Procedures that form part of DCE
The distributed file service is a worldwide file system that
provides a transparent way of accessing any file in the system in
the same way.
The directory service is used to keep track of the location of all
resources in the system. These resources include machines,
printers, servers, data, and much more, and they may be
distributed geographically over the entire world. The directory
service allows a process to ask for a resource and not have to be
concerned about where it is, unless the process cares.
The security service allows resources of all kinds to be
protected, so access can be restricted to authorized persons.
The distributed time service is a service that attempts to keep
clocks on the different machines globally synchronized.
• Cannot pass pointers
 call by reference becomes copy-restore (but
might fail)
• Weakly typed languages
 client stub cannot determine size
• Not always possible to determine parameter
types
• Cannot use global variables
RPCs, i.e., enhance access transparency but they are
not always appropriate to distributed system. 31
Message-Oriented Communication is a way of
communicating between processes. Messages,
which correspond to events, are the basic units of
data delivered. Message-oriented communication
is classified according to two factors:
• synchronous or asynchronous communication,
and transient or persistent communication.
32
Many distributed systems built on top of simple
message-oriented model
– Example: Berkeley sockets
– Socket?
33
34
• Sockets designed for network communication (e.g.,
TCP/IP)
 Support simple send/receive primitives
 Use general-purpose protocol stacks such as TCP/IP
• Abstraction not suitable for other protocols in clusters
of workstations or massively parallel systems
 Need an interface with more advanced primitives
• Large number of incompatible proprietary libraries
and protocols.
 Need for standard interface
35
• Message-passing interface (MPI)
 Hardware independent
 Designed for parallel applications (uses
transient communication)
• Key idea: communication between groups of
processes
 Each endpoint is a (groupID, processID) pair
• An MPI implementation allows a user to start
multiple threads and provide functions for the
threads to communicate and synchronize.
36
• The need for persistent communication services
is clear in developing middleware for large-scale
distributed applications.
• If you use direct point-to-point interfaces to
integrate your systems means that every system
would have to know exactly how to connect to
all other systems and enterprise.
37
You can see that as you add more systems it gets more
complex!
N(N-1)/2 different connections!
38
39
• Message queuing systems or Message-Oriented
Middleware (MOM).
 Support asynchronous persistent
communication
 Intermediate storage for message while
sender/receiver are inactive
 Example application: email
• Communicate by inserting messages in queues
• Sender is only guaranteed that message will be
eventually inserted in recipient’s queue
 When/if the message will be read?
40
• Queues are managed by queue managers
They move a message from a source queue to a
destination queue.
Special queue managers operate as routers or
relays: they forward incoming messages to other
queue managers.
41
Four combinations for loosely-coupled
communications using queues:
42
General Architecture of MOM:
43
The general organization of a message-
queuing system with routers:
44
Relays/Routers:
• special queue managers that operate as routers
and forward incoming messages to other queue
managers (Overlay network)
45
Why Routers??
• Only the routers need to be updated when queues
are added or removed
• Allow for secondary processing of messages (e.g.,
logging for fault tolerance)
• Used for multicasting purposes
• Act as message brokers
46
The Role of Message Brokers:
• Often, there’s a need to integrate new/existing apps
into a “single, coherent Distributed Information System
(DIS)”.
• Problem: different message formats exist in legacy
systems (cooperation and adherence to open standards
was not how things were done in the past).
It may not be convenient to “force” legacy systems to adhere
to a single, global message format (cost!?).
It is often necessary to live with diversity (there’s no choice).
• Solution: the “Message Broker”.
47
Message Broker
• In message-queuing systems, conversions are handled
by special nodes in a queuing network, known as
message brokers.
• A message broker acts as an application-level gateway
in a message-queuing system.
• Purpose - convert incoming messages so that they can
be understood by the destination application.
Note: a message broker is just another application - not
considered to be an integral part of the queuing system.
• Message brokers can be simple (reformat messages) or
complex (find associated applications, convert data).
48
The general organization of a message
broker in a message-queuing system:
49
Message-Queuing (MQ)
Applications:
• General-purpose MQ systems support a wide range
of applications, including:
Electronic mail.
Workflow.
Groupware.
Batch Processing.
• Most important MQ application area:
Integration of a widely dispersed collection of database
applications (which is all but impossible to do with
traditional RPC/RMI techniques).
50
Example IBM WebSphere
Message-Queuing system:
51
52
References
• http://www.ibiblio.org/gdunc/netone/NETESS3_html/netess3/ch05b.htm
• http://education-portal.com/academy/lesson/osi-model-using-open-
systems-interconnection-to-send-and-receive-data.html
• http://www.informit.com/articles/article.aspx?p=349749&seqNum=2
• http://www.twinoakscomputing.com/coredx/middleware_tour
• http://www.slideshare.net/Rishikese/middleware-and-middleware-in-
distributed-application?related=1
• http://www.w3.org/TR/wsdl.html
• https://msdn.microsoft.com/en-us/library/ms189921.aspx
• http://en.wikipedia.org/wiki/Remote_procedure_call
• http://jan.newmarch.name/go/arch/chapter-arch.html
• http://en.wikipedia.org/wiki/Communications_protocol
• http://www.cs.uoi.gr/~pitoura/courses/ds04_gr/communication-part1.pdf
53

More Related Content

What's hot

Chapter 4 a interprocess communication
Chapter 4 a interprocess communicationChapter 4 a interprocess communication
Chapter 4 a interprocess communicationAbDul ThaYyal
 
Transport layer services
Transport layer servicesTransport layer services
Transport layer servicesMelvin Cabatuan
 
Distributed system architecture
Distributed system architectureDistributed system architecture
Distributed system architectureYisal Khan
 
Chapter 4 data link layer
Chapter 4 data link layerChapter 4 data link layer
Chapter 4 data link layerNaiyan Noor
 
Synchronization in distributed systems
Synchronization in distributed systems Synchronization in distributed systems
Synchronization in distributed systems SHATHAN
 
Communications is distributed systems
Communications is distributed systemsCommunications is distributed systems
Communications is distributed systemsSHATHAN
 
Agreement Protocols, distributed File Systems, Distributed Shared Memory
Agreement Protocols, distributed File Systems, Distributed Shared MemoryAgreement Protocols, distributed File Systems, Distributed Shared Memory
Agreement Protocols, distributed File Systems, Distributed Shared MemorySHIKHA GAUTAM
 
Message and Stream Oriented Communication
Message and Stream Oriented CommunicationMessage and Stream Oriented Communication
Message and Stream Oriented CommunicationDilum Bandara
 
Communication in Distributed Systems
Communication in Distributed SystemsCommunication in Distributed Systems
Communication in Distributed SystemsDilum Bandara
 
Distributed operating system(os)
Distributed operating system(os)Distributed operating system(os)
Distributed operating system(os)Dinesh Modak
 
Distributed Systems Introduction and Importance
Distributed Systems Introduction and Importance Distributed Systems Introduction and Importance
Distributed Systems Introduction and Importance SHIKHA GAUTAM
 
File models and file accessing models
File models and file accessing modelsFile models and file accessing models
File models and file accessing modelsishmecse13
 
8. mutual exclusion in Distributed Operating Systems
8. mutual exclusion in Distributed Operating Systems8. mutual exclusion in Distributed Operating Systems
8. mutual exclusion in Distributed Operating SystemsDr Sandeep Kumar Poonia
 
Foult Tolerence In Distributed System
Foult Tolerence In Distributed SystemFoult Tolerence In Distributed System
Foult Tolerence In Distributed SystemRajan Kumar
 
Optimistic concurrency control in Distributed Systems
Optimistic concurrency control in Distributed SystemsOptimistic concurrency control in Distributed Systems
Optimistic concurrency control in Distributed Systemsmridul mishra
 
Chapter 14 replication
Chapter 14 replicationChapter 14 replication
Chapter 14 replicationAbDul ThaYyal
 

What's hot (20)

Network layer tanenbaum
Network layer tanenbaumNetwork layer tanenbaum
Network layer tanenbaum
 
Chapter 4 a interprocess communication
Chapter 4 a interprocess communicationChapter 4 a interprocess communication
Chapter 4 a interprocess communication
 
Transport layer services
Transport layer servicesTransport layer services
Transport layer services
 
Network software
Network softwareNetwork software
Network software
 
Distributed system architecture
Distributed system architectureDistributed system architecture
Distributed system architecture
 
Chapter 4 data link layer
Chapter 4 data link layerChapter 4 data link layer
Chapter 4 data link layer
 
Synchronization in distributed systems
Synchronization in distributed systems Synchronization in distributed systems
Synchronization in distributed systems
 
Communications is distributed systems
Communications is distributed systemsCommunications is distributed systems
Communications is distributed systems
 
Agreement Protocols, distributed File Systems, Distributed Shared Memory
Agreement Protocols, distributed File Systems, Distributed Shared MemoryAgreement Protocols, distributed File Systems, Distributed Shared Memory
Agreement Protocols, distributed File Systems, Distributed Shared Memory
 
Process Management-Process Migration
Process Management-Process MigrationProcess Management-Process Migration
Process Management-Process Migration
 
Message and Stream Oriented Communication
Message and Stream Oriented CommunicationMessage and Stream Oriented Communication
Message and Stream Oriented Communication
 
Communication in Distributed Systems
Communication in Distributed SystemsCommunication in Distributed Systems
Communication in Distributed Systems
 
Distributed operating system(os)
Distributed operating system(os)Distributed operating system(os)
Distributed operating system(os)
 
Distributed Systems Introduction and Importance
Distributed Systems Introduction and Importance Distributed Systems Introduction and Importance
Distributed Systems Introduction and Importance
 
Naming in Distributed System
Naming in Distributed SystemNaming in Distributed System
Naming in Distributed System
 
File models and file accessing models
File models and file accessing modelsFile models and file accessing models
File models and file accessing models
 
8. mutual exclusion in Distributed Operating Systems
8. mutual exclusion in Distributed Operating Systems8. mutual exclusion in Distributed Operating Systems
8. mutual exclusion in Distributed Operating Systems
 
Foult Tolerence In Distributed System
Foult Tolerence In Distributed SystemFoult Tolerence In Distributed System
Foult Tolerence In Distributed System
 
Optimistic concurrency control in Distributed Systems
Optimistic concurrency control in Distributed SystemsOptimistic concurrency control in Distributed Systems
Optimistic concurrency control in Distributed Systems
 
Chapter 14 replication
Chapter 14 replicationChapter 14 replication
Chapter 14 replication
 

Viewers also liked

Interprocess communication
Interprocess communicationInterprocess communication
Interprocess communicationSushil Singh
 
Unit 3
Unit  3Unit  3
Unit 3siddr
 
Interprocess Communication
Interprocess CommunicationInterprocess Communication
Interprocess CommunicationDeepak H L
 
Distributed Systems
Distributed SystemsDistributed Systems
Distributed SystemsRupsee
 

Viewers also liked (7)

RMI
RMIRMI
RMI
 
Interprocess communication
Interprocess communicationInterprocess communication
Interprocess communication
 
Unit 3
Unit  3Unit  3
Unit 3
 
Internet Protocols
Internet ProtocolsInternet Protocols
Internet Protocols
 
Interprocess Communication
Interprocess CommunicationInterprocess Communication
Interprocess Communication
 
Distributed System
Distributed System Distributed System
Distributed System
 
Distributed Systems
Distributed SystemsDistributed Systems
Distributed Systems
 

Similar to Inter-Process Communication in distributed systems

Linux Inter Process Communication
Linux Inter Process CommunicationLinux Inter Process Communication
Linux Inter Process CommunicationAbhishek Sagar
 
IT-NET GROUP 3 REPORT.pptx
IT-NET GROUP 3 REPORT.pptxIT-NET GROUP 3 REPORT.pptx
IT-NET GROUP 3 REPORT.pptxEdJulleza
 
Protocol layer,OSI model & POP3
Protocol layer,OSI model & POP3Protocol layer,OSI model & POP3
Protocol layer,OSI model & POP3Zakirul Islam
 
20IT703_PDS_PPT_Unit_I.ppt
20IT703_PDS_PPT_Unit_I.ppt20IT703_PDS_PPT_Unit_I.ppt
20IT703_PDS_PPT_Unit_I.pptsuganthi66742
 
Internetworking
InternetworkingInternetworking
InternetworkingRaghu nath
 
DCN notes adi
DCN notes adiDCN notes adi
DCN notes adiAdiseshaK
 
06 - OSI Model.ppt
06 - OSI Model.ppt06 - OSI Model.ppt
06 - OSI Model.pptssuserf7cd2b
 
06 - OSI Model.ppt
06 - OSI Model.ppt06 - OSI Model.ppt
06 - OSI Model.pptssuserf7cd2b
 
Chapter 2 computer network PPT CN-1.pptx
Chapter 2 computer network PPT CN-1.pptxChapter 2 computer network PPT CN-1.pptx
Chapter 2 computer network PPT CN-1.pptxManasaPM3
 
unit1 network model osi and tcpip.pptx
unit1  network model osi and tcpip.pptxunit1  network model osi and tcpip.pptx
unit1 network model osi and tcpip.pptx183JAIDEEP
 
Networking for MBA
Networking for MBANetworking for MBA
Networking for MBAKK Bajpai
 
ITFT_Osi reference model
ITFT_Osi reference modelITFT_Osi reference model
ITFT_Osi reference modelSneh Prabha
 
Lect 1 Distributed System.pptx
Lect 1 Distributed System.pptxLect 1 Distributed System.pptx
Lect 1 Distributed System.pptxPardonSamson
 
Concept of OSI Model_KSMS_BCA_4th_6th_Sem_Priyanka Bhattacharya_20th March 2020
Concept of OSI Model_KSMS_BCA_4th_6th_Sem_Priyanka Bhattacharya_20th March  2020Concept of OSI Model_KSMS_BCA_4th_6th_Sem_Priyanka Bhattacharya_20th March  2020
Concept of OSI Model_KSMS_BCA_4th_6th_Sem_Priyanka Bhattacharya_20th March 2020PriyankaBhattacharya28
 
1_Operating System.ppt
1_Operating System.ppt1_Operating System.ppt
1_Operating System.pptSproohaAthalye
 

Similar to Inter-Process Communication in distributed systems (20)

Linux Inter Process Communication
Linux Inter Process CommunicationLinux Inter Process Communication
Linux Inter Process Communication
 
Viloria osi layer4-7
Viloria osi layer4-7Viloria osi layer4-7
Viloria osi layer4-7
 
Chap 2 network models
Chap 2 network modelsChap 2 network models
Chap 2 network models
 
IT-NET GROUP 3 REPORT.pptx
IT-NET GROUP 3 REPORT.pptxIT-NET GROUP 3 REPORT.pptx
IT-NET GROUP 3 REPORT.pptx
 
Protocol layer,OSI model & POP3
Protocol layer,OSI model & POP3Protocol layer,OSI model & POP3
Protocol layer,OSI model & POP3
 
20IT703_PDS_PPT_Unit_I.ppt
20IT703_PDS_PPT_Unit_I.ppt20IT703_PDS_PPT_Unit_I.ppt
20IT703_PDS_PPT_Unit_I.ppt
 
Internetworking
InternetworkingInternetworking
Internetworking
 
Networking concepts
Networking conceptsNetworking concepts
Networking concepts
 
DCN notes adi
DCN notes adiDCN notes adi
DCN notes adi
 
06 - OSI Model.ppt
06 - OSI Model.ppt06 - OSI Model.ppt
06 - OSI Model.ppt
 
06 - OSI Model.ppt
06 - OSI Model.ppt06 - OSI Model.ppt
06 - OSI Model.ppt
 
Chapter 2 computer network PPT CN-1.pptx
Chapter 2 computer network PPT CN-1.pptxChapter 2 computer network PPT CN-1.pptx
Chapter 2 computer network PPT CN-1.pptx
 
unit1 network model osi and tcpip.pptx
unit1  network model osi and tcpip.pptxunit1  network model osi and tcpip.pptx
unit1 network model osi and tcpip.pptx
 
Network Protocol and TCP/IP
Network Protocol and TCP/IPNetwork Protocol and TCP/IP
Network Protocol and TCP/IP
 
OSI Model
OSI ModelOSI Model
OSI Model
 
Networking for MBA
Networking for MBANetworking for MBA
Networking for MBA
 
ITFT_Osi reference model
ITFT_Osi reference modelITFT_Osi reference model
ITFT_Osi reference model
 
Lect 1 Distributed System.pptx
Lect 1 Distributed System.pptxLect 1 Distributed System.pptx
Lect 1 Distributed System.pptx
 
Concept of OSI Model_KSMS_BCA_4th_6th_Sem_Priyanka Bhattacharya_20th March 2020
Concept of OSI Model_KSMS_BCA_4th_6th_Sem_Priyanka Bhattacharya_20th March  2020Concept of OSI Model_KSMS_BCA_4th_6th_Sem_Priyanka Bhattacharya_20th March  2020
Concept of OSI Model_KSMS_BCA_4th_6th_Sem_Priyanka Bhattacharya_20th March 2020
 
1_Operating System.ppt
1_Operating System.ppt1_Operating System.ppt
1_Operating System.ppt
 

Recently uploaded

AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdfankushspencer015
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escortsranjana rawat
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdfKamal Acharya
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Bookingdharasingh5698
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...Call Girls in Nagpur High Profile
 
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...ranjana rawat
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsCall Girls in Nagpur High Profile
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesPrabhanshu Chaturvedi
 
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...ranjana rawat
 
Online banking management system project.pdf
Online banking management system project.pdfOnline banking management system project.pdf
Online banking management system project.pdfKamal Acharya
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxupamatechverse
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Call Girls in Nagpur High Profile
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...ranjana rawat
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxAsutosh Ranjan
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performancesivaprakash250
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxpranjaldaimarysona
 
Introduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxupamatechverse
 
Extrusion Processes and Their Limitations
Extrusion Processes and Their LimitationsExtrusion Processes and Their Limitations
Extrusion Processes and Their Limitations120cr0395
 
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTINGMANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTINGSIVASHANKAR N
 
Porous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writingPorous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writingrakeshbaidya232001
 

Recently uploaded (20)

AKTU Computer Networks notes --- Unit 3.pdf
AKTU Computer Networks notes ---  Unit 3.pdfAKTU Computer Networks notes ---  Unit 3.pdf
AKTU Computer Networks notes --- Unit 3.pdf
 
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Isha Call 7001035870 Meet With Nagpur Escorts
 
University management System project report..pdf
University management System project report..pdfUniversity management System project report..pdf
University management System project report..pdf
 
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 BookingVIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
VIP Call Girls Ankleshwar 7001035870 Whatsapp Number, 24/07 Booking
 
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...Booking open Available Pune Call Girls Pargaon  6297143586 Call Hot Indian Gi...
Booking open Available Pune Call Girls Pargaon 6297143586 Call Hot Indian Gi...
 
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
(ANJALI) Dange Chowk Call Girls Just Call 7001035870 [ Cash on Delivery ] Pun...
 
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur EscortsHigh Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
High Profile Call Girls Nagpur Meera Call 7001035870 Meet With Nagpur Escorts
 
Glass Ceramics: Processing and Properties
Glass Ceramics: Processing and PropertiesGlass Ceramics: Processing and Properties
Glass Ceramics: Processing and Properties
 
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
The Most Attractive Pune Call Girls Manchar 8250192130 Will You Miss This Cha...
 
Online banking management system project.pdf
Online banking management system project.pdfOnline banking management system project.pdf
Online banking management system project.pdf
 
Introduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptxIntroduction to Multiple Access Protocol.pptx
Introduction to Multiple Access Protocol.pptx
 
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...Top Rated  Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
Top Rated Pune Call Girls Budhwar Peth ⟟ 6297143586 ⟟ Call Me For Genuine Se...
 
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
(SHREYA) Chakan Call Girls Just Call 7001035870 [ Cash on Delivery ] Pune Esc...
 
Coefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptxCoefficient of Thermal Expansion and their Importance.pptx
Coefficient of Thermal Expansion and their Importance.pptx
 
UNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its PerformanceUNIT - IV - Air Compressors and its Performance
UNIT - IV - Air Compressors and its Performance
 
Processing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptxProcessing & Properties of Floor and Wall Tiles.pptx
Processing & Properties of Floor and Wall Tiles.pptx
 
Introduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptxIntroduction to IEEE STANDARDS and its different types.pptx
Introduction to IEEE STANDARDS and its different types.pptx
 
Extrusion Processes and Their Limitations
Extrusion Processes and Their LimitationsExtrusion Processes and Their Limitations
Extrusion Processes and Their Limitations
 
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTINGMANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
MANUFACTURING PROCESS-II UNIT-1 THEORY OF METAL CUTTING
 
Porous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writingPorous Ceramics seminar and technical writing
Porous Ceramics seminar and technical writing
 

Inter-Process Communication in distributed systems

  • 2. Agenda • Introduction • Layered Protocols (7 Layers) • Types of Communication (3 Categories) • Models for Communication (3 Models) • The Group Communication and the Multicasting Communication 2
  • 3. Introduction • IPC is at the heart of all distributed systems, so we need to know the ways that processes can exchange information. • Communication in distributed systems is based on Low-level message passing as offered by the underlying network. 3
  • 4. Layered Protocols Two processes A,B A wants to communicate with B. A builds a message in its own address space. A execute a call to the OS to send the message. To prevent chaos (mass) A,B have to agree on the meaning of the bites being sent. 4
  • 5. • The International Standards Organization (ISO) developed a reference model that clearly identifies the various levels involved Open Systems Interconnection (OSI). • It provides a description of how network hardware and software work together in a layered fashion to make communications possible. 5
  • 6. • Communication divided into 7 layers. • Each layer has a responsibility to perform specific tasks but all of the layers are needed for a message to reach its destination. • Message send (downwards) Message received (upwards). 6
  • 7. Two general type of protocols • Connection oriented protocols: Before exchanging data the sender and receiver first establish a connection, and possibly negotiate the protocol they will use When they are done, they must terminate the connection. The Telephone • Connectionless protocols: No setup in advance is needed, The sender just transmits the first message when it is ready. The mailbox or mail 7
  • 8. Presentation Layer Session Layer Transport Layer Network Layer Data Link Layer Physical Layer Application Layer Layered Protocols 8
  • 9. Application Layer • It is the software that the end-user interacts with. • It serves as a window through which application processes can access network services. 9
  • 10. Presentation Layer • Think of it as the network's translator. • It is responsible for translating the data, encrypting the data, changing or converting the character set. • Manages data compression to reduce the number of bits that need to be transmitted. 10
  • 11. Session Layer • Provides dialog control between communicating processes, such as which party is currently talking, when, and for how long. • Allows users to insert checkpoints into long transfers. • In the event of crash, it is necessary to go back only to the last checkpoint. 11
  • 12. Transport Layer • Turns the underlying network into something that an application developer can use. • Ensures that packets are delivered error free, in sequence, and without losses or duplications. 12
  • 13. Network Layer • Addresses the packets and translating logical addresses and names into physical addresses. • Determines the route from the source to the destination computer (Delay-Wise). 13
  • 14. Data Link Layer • Groups bits into frames and sees that each frame is correctly received (checksum), If checksums differ, requests a retransmission. • Sends data frames from the network layer to the physical layer 14
  • 15. 15
  • 16. Physical Layer • The physical layer is totally hardware- oriented. • It is responsible for transmitting bits (zeros and ones) from one computer to another. • Defines the duration of each impulse. 16
  • 17. Middleware Protocols • Communications Middleware is the layer that lies between the operating system and system applications that allows for communications. • Sometimes Communications Middleware is referred to as “plumbing” because it is the piece that connects two (or more) applications and allows data to pass through. 17
  • 18. • Communications Middleware can be cross- platform, that is, it facilitates communications between these differing devices. • We can use a cell phone and a PC here as an example. They both function in vastly different capacities, but with Communications Middleware, are able to “talk” to and “work with” each other 18
  • 19. 19
  • 21. • Many distributed systems have been based on explicit message exchange between processes and this exchange must be transparent. • Problems  the calling and called procedures run on different machines, they execute in different address spaces.  Parameters and results also have to be passed.  Either or both machines can crash and each of the possible failures causes different problems.
  • 22. count =read (fd, buf, nbytes); fd is an integer indicating a file. buf is an array of characters into which data are read. nbytes is an integer telling how many bytes to read.
  • 23. • By Value • By Reference • By Copy and Restore count =read (fd, buf, nbytes);
  • 24. Performing read operation in RPC : 1. The client procedure calls the client stub in the normal way. 2. The client stub builds a message and calls the local operating system 3. The client's as sends the message to the remote as. 4. The remote as gives the message to the server stub. 5. The server stub unpacks the parameters and calls the server. 6. The server does the work and returns the result to the stub. 7. The server stub packs it in a message and calls its local as. 8. The server's as sends the message to the client's as. 9. The client's as gives the message to the client stub. 10. The stub unpacks the result and returns to the client.
  • 25. • By Value • By Reference • Problems add(i, j);
  • 26. • The message format must be defined, the caller and the callee must agree on the format of the messages they exchange, and that they follow the same steps when it comes to. • The interface language must be the same in client and server.
  • 27.
  • 28. • developed by the Open Software Foundation (OSF). • DCE RPC is not as popular as some other RPC systems. • Initially designed for UNIX, it has now been ported to all major operating systems including VMS and Windows variants. • Idea Distributed Computing Environment
  • 29. Procedures that form part of DCE The distributed file service is a worldwide file system that provides a transparent way of accessing any file in the system in the same way. The directory service is used to keep track of the location of all resources in the system. These resources include machines, printers, servers, data, and much more, and they may be distributed geographically over the entire world. The directory service allows a process to ask for a resource and not have to be concerned about where it is, unless the process cares. The security service allows resources of all kinds to be protected, so access can be restricted to authorized persons. The distributed time service is a service that attempts to keep clocks on the different machines globally synchronized.
  • 30.
  • 31. • Cannot pass pointers  call by reference becomes copy-restore (but might fail) • Weakly typed languages  client stub cannot determine size • Not always possible to determine parameter types • Cannot use global variables RPCs, i.e., enhance access transparency but they are not always appropriate to distributed system. 31
  • 32. Message-Oriented Communication is a way of communicating between processes. Messages, which correspond to events, are the basic units of data delivered. Message-oriented communication is classified according to two factors: • synchronous or asynchronous communication, and transient or persistent communication. 32
  • 33. Many distributed systems built on top of simple message-oriented model – Example: Berkeley sockets – Socket? 33
  • 34. 34
  • 35. • Sockets designed for network communication (e.g., TCP/IP)  Support simple send/receive primitives  Use general-purpose protocol stacks such as TCP/IP • Abstraction not suitable for other protocols in clusters of workstations or massively parallel systems  Need an interface with more advanced primitives • Large number of incompatible proprietary libraries and protocols.  Need for standard interface 35
  • 36. • Message-passing interface (MPI)  Hardware independent  Designed for parallel applications (uses transient communication) • Key idea: communication between groups of processes  Each endpoint is a (groupID, processID) pair • An MPI implementation allows a user to start multiple threads and provide functions for the threads to communicate and synchronize. 36
  • 37. • The need for persistent communication services is clear in developing middleware for large-scale distributed applications. • If you use direct point-to-point interfaces to integrate your systems means that every system would have to know exactly how to connect to all other systems and enterprise. 37
  • 38. You can see that as you add more systems it gets more complex! N(N-1)/2 different connections! 38
  • 39. 39
  • 40. • Message queuing systems or Message-Oriented Middleware (MOM).  Support asynchronous persistent communication  Intermediate storage for message while sender/receiver are inactive  Example application: email • Communicate by inserting messages in queues • Sender is only guaranteed that message will be eventually inserted in recipient’s queue  When/if the message will be read? 40
  • 41. • Queues are managed by queue managers They move a message from a source queue to a destination queue. Special queue managers operate as routers or relays: they forward incoming messages to other queue managers. 41
  • 42. Four combinations for loosely-coupled communications using queues: 42
  • 44. The general organization of a message- queuing system with routers: 44
  • 45. Relays/Routers: • special queue managers that operate as routers and forward incoming messages to other queue managers (Overlay network) 45
  • 46. Why Routers?? • Only the routers need to be updated when queues are added or removed • Allow for secondary processing of messages (e.g., logging for fault tolerance) • Used for multicasting purposes • Act as message brokers 46
  • 47. The Role of Message Brokers: • Often, there’s a need to integrate new/existing apps into a “single, coherent Distributed Information System (DIS)”. • Problem: different message formats exist in legacy systems (cooperation and adherence to open standards was not how things were done in the past). It may not be convenient to “force” legacy systems to adhere to a single, global message format (cost!?). It is often necessary to live with diversity (there’s no choice). • Solution: the “Message Broker”. 47
  • 48. Message Broker • In message-queuing systems, conversions are handled by special nodes in a queuing network, known as message brokers. • A message broker acts as an application-level gateway in a message-queuing system. • Purpose - convert incoming messages so that they can be understood by the destination application. Note: a message broker is just another application - not considered to be an integral part of the queuing system. • Message brokers can be simple (reformat messages) or complex (find associated applications, convert data). 48
  • 49. The general organization of a message broker in a message-queuing system: 49
  • 50. Message-Queuing (MQ) Applications: • General-purpose MQ systems support a wide range of applications, including: Electronic mail. Workflow. Groupware. Batch Processing. • Most important MQ application area: Integration of a widely dispersed collection of database applications (which is all but impossible to do with traditional RPC/RMI techniques). 50
  • 52. 52
  • 53. References • http://www.ibiblio.org/gdunc/netone/NETESS3_html/netess3/ch05b.htm • http://education-portal.com/academy/lesson/osi-model-using-open- systems-interconnection-to-send-and-receive-data.html • http://www.informit.com/articles/article.aspx?p=349749&seqNum=2 • http://www.twinoakscomputing.com/coredx/middleware_tour • http://www.slideshare.net/Rishikese/middleware-and-middleware-in- distributed-application?related=1 • http://www.w3.org/TR/wsdl.html • https://msdn.microsoft.com/en-us/library/ms189921.aspx • http://en.wikipedia.org/wiki/Remote_procedure_call • http://jan.newmarch.name/go/arch/chapter-arch.html • http://en.wikipedia.org/wiki/Communications_protocol • http://www.cs.uoi.gr/~pitoura/courses/ds04_gr/communication-part1.pdf 53