The International Standards Organization Reference Model of Open

  • Slides: 10
Download presentation
The International Standards Organization Reference Model of Open System Interconnection (ISO OSI model) Host

The International Standards Organization Reference Model of Open System Interconnection (ISO OSI model) Host A 1 Application Host B Message interfaces 2 Presentation Message interfaces 3 Session Message Subnet 4 Transport Message Boundary 5 Network Packet 6 Data Link Frame 7 Physical Bit

ISO OSI Model (The 7 Layers) Physical Layer specifies physical signals (electrical, optical), cabling/wiring.

ISO OSI Model (The 7 Layers) Physical Layer specifies physical signals (electrical, optical), cabling/wiring. Data Link Layer frame boundaries, error detection (noise), flow control Network Layer how packets are sent from sources to destinations: routing, congestion control, internetworking. Transport Layer break messages into packets, multiplex/demultiplex messages, end-to-end reliability. Session Layer provides users interface: directory, access rights, synchronization. Presentation Layer data encryption, data compression, code conversion. Application Layer virtual terminal, virtual file transfer

Information Transfer Implementation of Layering Message Application layer Conversion layer Presentation Session Transport Converted

Information Transfer Implementation of Layering Message Application layer Conversion layer Presentation Session Transport Converted Message Packet layer Pkt Hdr First Pkt Hdr Second Pkt Frame layer Frame Hdr Pkt Hdr First Pkt Frame Hdr Pkt Hdr Second Pkt Physical layer Frames sent out onto network

Common Network Protocols • • • Ethernet (IEEE 802. 3) 10 Mbps – Carrier

Common Network Protocols • • • Ethernet (IEEE 802. 3) 10 Mbps – Carrier Sense Multiple Access / Collision Detect Token-Bus (IEEE 802. 4) – Physically a bus, logically a ring, token passing Token-Ring (IEEE 802. 5) 4 -16 Mbps – Ring topology, token passing Slotted Aloha – Time slot, broadcasting Slotted-ring (Cambridge ring) – Time multiplexing Fibre Distributed Data Interface (FDDI) – High speed (100 Mbps), token-bus like protocol Integrated Service Digital Network (ISDN) – Multiples of 64 kbps, up to 2 Mbps per channel for voice & video ATM Switch (155 Mbps, 622 Mbps) Fast Ethernet (100 Mbps), Giga-bit Ethernet (1 Gbps)

Popular protocols for PC Do. D Netware/Novell IBM 7 - Application 6 - Presentation

Popular protocols for PC Do. D Netware/Novell IBM 7 - Application 6 - Presentation 5 - Session 4 - Transport 3 - Network 2 - Data Link 1 - Physical UDP IP TCP SPX Net. BIOS IPX Network Card UDP: User Datagram Protocol TCP: Transmission Control Protocol IP: Internet Protocol SPX: Sequenced Packet e. Xchange IPX: Internetwork Packet e. Xchange

The Client-Server Model • A server is a program that provide a service. –

The Client-Server Model • A server is a program that provide a service. – It makes some resource available to other programs running somewhere on the network. – The resource could be anything: a database, a file system, a printer, a modem, a screen, or a scanner. – The server program runs on the machine which resource is attached to, and waits passively until the services are required. – Servers are often started up at boot-time, via commands in a start-up script and Servers usually spent most of their time asleep, waiting for work. • A client is a program that uses a resource. – It may be running on the machine to which the resource is attached, or on a different machine. – A client actively makes a connection across the network to the server it requires.

The Client-Server Model (continue) • The terms client and server are sometimes used to

The Client-Server Model (continue) • The terms client and server are sometimes used to refer to a machine. • We may point out a computer on our network which has a large disk attached and say “That is our file server, and these workstations here are its clients”. • We may refer to a machine with a printer attached as a “print server”. • The term client and server refer to the relationship between individual programs, not to machines. • In general, machines cannot simply be labeled as clients and servers. • One machine might be a server for a piece of the file system, but a client of a remote print server. • Example, a program which is a server for a database might itself contact a time server to obtain an accurate timestamp to attach to a new record in the database. • In UNIX world, the term daemon is sometimes used to refer to a server. • It means that the server is “permanently available”, which implies that it is started at boot-time. • Daemon usually provide a “system-related” service, such as: rlogind, telnetd, ftpd, httpd, nfsd, … etc.

Remote Procedure Calls • The procedure call (same as function call or subroutine call)

Remote Procedure Calls • The procedure call (same as function call or subroutine call) is a well-known method for transferring control from one part of a process to another, with a return of control to the caller. • Associated with the procedure call is the passing of arguments from the caller (the client) to the callee (the server). • In most current systems the caller and the callee are within a single process on a given host system. This is what we called “local procedure calls”. • In a remote procedure call (RPC), a process on the local system invokes a procedure on a remote system. The reason we call this a “procedure call” is because the intent is to make it appear to the programmer that a normal procedure call is taking place. • We use the term “request” to refer to the client calling the remote procedure, and the term “response” to describe the remote procedure returning its result to the client. • We will use the SUN RPC as our remote procedure call example. However, our example works for BSD as well with very minor modifications. • But let’s look at the steps that is involved in a remote procedure call.

The 10 steps in a Remote Procedure Call (RPC) Client Process Server Process Client

The 10 steps in a Remote Procedure Call (RPC) Client Process Server Process Client routines Server routines local procedure (10) call = (1) Client stub system call = (2) (6) Server stub (9) Network routines local kernel (5) (7) (8) (3) = network communication (4) Network routines remote kernel

The 10 steps in a Remote Procedure Call (continue) 1. The client calls a

The 10 steps in a Remote Procedure Call (continue) 1. The client calls a local procedure, called the client stub. It appears to the client that the client stub is the actual server procedure that it wants to call. The purpose of the stub is to package the arguments for the remote procedure, possibly put them into some standard format and then build one or more network messages. The packaging of the client's arguments into a network message is termed marshaling. 2. These network messages are sent to the remote system by the client stub. This requires a system call to the local kernel. 3. The network messages are transferred to the remote system. Either a connection-oriented or a connection-less protocol is used. 4. A server stub procedure is waiting on the remote system for the client's request. It unmarshals the arguments from the network message and possibly converts them. 5. The server stub executes a local procedure call to invoke the actual server function, passing it the arguments that it received in the network messages from the client stub. 6. When the server procedure is finished, it returns to the server stub with return values. 7. The server stub converts the return values, if necessary, and marshals them into one or more network messages to send back to the client stub. 8. The messages get transferred back across the network to the client stub. 9. The client stub reads the network messages from the local kernel. 10. After possibly converting the return values, the client stub finally returns to the client function. This appears to be a normal procedure return to the client.