Professional Documents
Culture Documents
Trebas Institute
10 mai 2023
RPC : Architecture
Client-Server Model
Synchronous operation (require program suspension until the results
are returned)
Multiple RPC through threading
Interface Definition Language (IDL) a are commonly used
▶ Provide a bridge between machines at either end of the link (#OSes or
Computer languages)
a. language that lets a program or object written in one language communicate with
another program written in an unknown language. IDLs describe an interface in a
language-independent way, enabling communication between software components that
do not share one language, for example, between those written in C++ and those
written in Java.
RPC : Components
Client
Server
Client Stub
Server Stub
Port Mapper / RPCBind
RPC : Client
Computer or process that accesses the services or resources of another
process or computer on the network
Knows how to address the remote computer and server application
Send a message across the network that requests the remote procedure
RPC : Server
Computer that provides services and resources, and that implements
network services.
Provides application/server services and features to remotely
connected RPC clients
▶ Request can be for server access, data or any other server-based
requests
Send a message across the network that requests the remote procedure
Operation
When an RPC server is started, it will tell portmap what port number it is
listening to, and what RPC program numbers it is prepared to serve. When
a client wishes to make an RPC call to a given program number, it will first
contact portmap on the server machine to determine the port number
where RPC packets should be sent.
RPC : Steps
The client invokes a "client stub" which resides in the client’s own
address space.
This stub converts the message into the standard format according to
the client’s network services.
Then it transfers the message to the remote network service.
On the other side, the server invokes the "server stub" which decodes
the transferred
message according to its standard format and takes up the regular
procedure call.
RPC : Steps
Once the call is executed according to its procedure the call is
returned to the server
stub and it transfers the message to the transport layer.
Then the transport layer sends back the message to the client server
stub.
Then the client server stubs decode the message into its standard form
and the call gets completed.
RPC : Steps
Client calls the client stub.
Stub generates a system call to forward the message and adds
parameters to the message.
Message forwarding from client to server via client OS.
Message further passes to server stub with the help of OS.
Message parameters are removed.
Server stub calls the server procedure.
Microsoft-RPC
MS-RPC (Microsoft Remote Procedure Call : protocol that allows
requesting service from a program on another computer without
having to understand the details of that computer’s network.
Compatible with the Open Group’s Distributed Computing
Environment (DCE) specification for remote procedure calls
interoperable with other DCE-based RPC systems : HP-UX and IBM
AIX UNIX-based operating systems
The RPC facility is compatible with the Open Group specification.
Microsoft-RPC : Components
MIDL compiler
Runtime libraries and header files Transport interface modules
Name service provider
Endpoint supply service
Microsoft-RPC : Components
Runtime libraries and header files Transport interface modules
▶ Windows 2000 uses dynamic link libraries (DLLs) to provide procedure
code and backbone code.
▶ This enables the DLLs to be modified or updated without changing or
redistributing the backbone portion.
▶ Client applications are developed with specially compiled stub libraries
provided by the application program.
▶ This module is responsible for finding the server that can satisfy the
RPC command.
▶ Once found, the function and data are sent to the server, where they
are picked up by the RPC runtime component on the server
Name service provider
Endpoint supply service
Microsoft-RPC : Components
Name service provider
▶ Allows client applications to use a logical name instead of a specific
protocol sequence and network address
Endpoint supply service
▶ network location where a program could transfer its RPC requests to
access server data