SlideShare ist ein Scribd-Unternehmen logo
1 von 32
Downloaden Sie, um offline zu lesen
Networking Principles
      IT1 Course Slide
         Instructor:
       Majid Taghiloo
Functionality

    • Transport layer and layers below
      – B i communication
        Basic       i ti
      – Reliability
    • Application layer
      – Abstractions
         • Files
         • Services
         • Databases
      – Names
2
Dichotomy of Duties

    • Network
      – Transfers bits
      – Operates at application s request
                     application’s
    • Applications determine
      – What to send
      – When to send
      – Where to send
      – Meaning of bits
3
Important Point
    Although an internet system provides a 
                                 ,    p
    basic communication service, the protocol 
    software cannot initiate contact with, or 
         p          f     ,             p
    accept contact from, a remote computer.  
    Instead, two application programs must 
    participate in any communication: one 
    participate in any communication: one
    application initiates communication and 
    the other accepts it.
    the other accepts it.


4
How Two Application Programs Make
                 Contact
• One application
     – Begins execution first
         g
     – Waits passively at prearranged location
• A th application
  Another li ti
     – Begins execution later
     – Actively contacts first program
• Called client‐server interaction


5
Client‐Server
        Client Server Paradigm
• Used by all network applications
• Passive program called a server
• Active program called a client




6
Internet Communication
    All network applications use a form of 
    communication known as the client‐server 
    paradigm.  A server application waits 
    p
    passively for contact, while a client 
             yf           ,
    application initiates communication 
    actively.




7
Characteristics of a Client
•   Arbitrary application program
•   Becomes client temporarily
•   Can also perform other computations
•   Invoked directly by user
•   Runs locally on user’s computer
                     user s
•   Actively initiates contact with a server
•   Contacts one server at a time

8
Characteristics of a Server
•   Special‐purpose, privileged program
•   Dedicated to providing one service
•   Can handle multiple remote clients simultaneously
•   Invoked automatically when system boots
                          y        y
•   Executes forever
•   Needs powerful computer and operating system
•   Waits passively for client contact
•   Accepts requests from arbitrary clients


9
Terminology
• Server
     – An executing program that accepts contact over
                  gp g               p
       the network
• Server class computer
  Server‐class
     – Hardware sufficient to execute a server
• Informally
     – Term server often applied to computer


10
Direction of Data Flow
• Data can fl
           flow
     – From client to server only
     – From server to client only
     – In both directions
• Application protocol determines flow
• Typical scenario
     – Client sends request(s)
     – Sever sends response(s)


11
Key Idea

Although the client initiates contact, 
information can flow in either or both 
information can flow in either or both
directions between a client and server.  
Many services arrange for the client to send 
one or more requests and the server to 
return one response for each request.



12
Clients, Servers,
     Clients Servers and Other Protocols




     Clients and servers are application programs •

13
Server CPU Use
• Facts
     – Server operates like other applications
        • Uses CPU to execute instructions
        • Performs I/O operations
     – Waiting for data to arrive over a network does not
       require CPU time
• Consequence
     – Server program only uses CPU when servicing a
              p g        y                       g
       request


14
Multiple Services
• Can have multiple servers on single computer
• Servers only use processor when handling a
  request
• P
  Powerful h d
        f l hardware required to h dl many
                          i d handle
  services simultaneously




15
Illustration of Multiple Servers




• Each server offers one service
• One server can handle multiple clients
16
Identifying a Service
• Protocol port number used
         l          b      d
• Each service given unique p number, P
               g        q port
• Server
     – Informs OS it is using port P
     – Waits for requests to arrive
• Cli
  Client
     – Forms request
     – Send request to port P on server computer


17
The Point About Ports
Transport protocols assign each service a 
unique port identifier.  A server must specify 
unique port identifier A server must specify
the identifier when it begins execution.  A 
client must specify the identifier when it 
client must specify the identifier when it
requests transport protocol software to 
contact a server.  Protocol software on the 
server computer uses the identifier to direct 
an incoming request to the correct server.

18
In Theory
• Port numbers are merely integers
• Any server could use any port number




19
In Practice
     • P t l port numbers used as service
       Protocol    t   b      d       i
       identifiers
     • Need uniform numbering
       – To allow arbitrary client to contact server on
         arbitrary machine
       – To avoid inventing “directory assistance”
         mechanism
     • Port numbers
       – Uniform throughout Internet
       – Set by standards bodies


20
Terminology
• Sequential program
     – Typical of most programs
        yp             p g
     – Single thread of control
• C
  Concurrent program
           t
     – Multiple threads of control
     – Execution proceeds “in parallel”
     – More difficult to create


21
Servers and Concurrency
• Sequential server
     – Also called iterative
     – Handles one request at a time
• C
  Concurrent server
           t
     – Can handle multiple requests at a time
     – No waiting




22
Delay in Servers

     • Concurrent server
        – Server creates new thread of control to handle each request
        – Client only waits for its request to be processed
     • Sequential server
        – Client waits for all previous requests to be processed as well
          as f it request t b processed
             for its       t to be          d
        – Unacceptable to user if long request blocks short requests




23
Concurrency in Servers
Concurrent execution is fundamental to 
servers because concurrency permits 
servers because concurrency permits
multiple clients to obtain a given service 
without having to wait for the server to 
without having to wait for the server to
finish previous requests.  In a concurrent 
server, the main server thread creates a 
new service thread to handle each client.


24
Protocol Ports and Concurrent Servers
• Apparent problem
     – One port number assigned to each service
            p               g
     – Concurrent server has multiple copies (threads)
       running
     – Client and server may interact
     – Messages sent to server’s port must be delivered
                               ’           b d li      d
       to correct copy



25
Protocol Ports and Concurrent Servers
             (continued)
• Solution to problem: use i f
     l i          bl         information about
                                       i   b
  client as well as server to deliver incoming
  packets
• TCP uses four items to identify connection
                                  y
     – Server’s IP address
     – Server’s protocol port number
       Server s
     – Client’s IP address
     – Client’s protocol port number
       Client s


26
Demultiplexing in a Concurrent Server


Transport protocols assign an identifier to 
Transport protocols assign an identifier to
each client as well as to each service.  
Protocol software on the server s machine 
Protocol software on the server’s machine
uses the combination of client and server 
identifiers to choose the correct copy of a 
identifiers to choose the correct copy of a
concurrent server.



27
Variations on a Theme
• A server can use
     – Connectionless transport (UDP)
     – Connection‐oriented transport (TCP)
     – Both for a single service
                     g
• A single server can offer multiple services
     – Often used for “trivial” services
                       trivial
     – Server uses multiple port numbers simultaneously



28
Variations on a Theme (cont)
• A server can
     – Maintain interaction with a client for days or hours
                                                y
     – Send a short response and terminate interaction
     – Perform I/O on the local computer
     – Become a client for another service (potential
       cycle problem)
          l     bl )




29
Example of Circularity
• Time server
   i
     – Returns time of day
• File server
     – Allows client to read or write a file
     – Calls time server when generating time stamp for
       file
• Suppose programmer modifies time server to
  log requests to a file


30
Interacting with Protocol Software
                   g

     •   Client or server uses transport protocols
     •   Protocol software inside OS
     •   Applications outside OS
     •   Mechanism needed to bridge the two
         – Called Application Program Interface (API)


31
Application Program Interface
• Part of operating system
• Permits application to use protocols
• Defines
     – Operations allowed
     – Arguments for each operation
         g                 p




32

Weitere ähnliche Inhalte

Was ist angesagt?

Remote procedure calls
Remote procedure callsRemote procedure calls
Remote procedure callsimnomus
 
Sun RPC (Remote Procedure Call)
Sun RPC (Remote Procedure Call)Sun RPC (Remote Procedure Call)
Sun RPC (Remote Procedure Call)Peter R. Egli
 
Socket网络编程
Socket网络编程Socket网络编程
Socket网络编程qhm123
 
Sept 2017 internetworking
Sept 2017   internetworkingSept 2017   internetworking
Sept 2017 internetworkingshahin raj
 
Introduction to Remote Procedure Call
Introduction to Remote Procedure CallIntroduction to Remote Procedure Call
Introduction to Remote Procedure CallAbdelrahman Al-Ogail
 
Getting started with libfabric
Getting started with libfabricGetting started with libfabric
Getting started with libfabricJianxin Xiong
 
Ds objects and models
Ds objects and modelsDs objects and models
Ds objects and modelsMayank Jain
 
HHM 6894 Messaging APIs for Cloud, Enterprise and Digital Applications
HHM 6894 Messaging APIs for Cloud, Enterprise and Digital ApplicationsHHM 6894 Messaging APIs for Cloud, Enterprise and Digital Applications
HHM 6894 Messaging APIs for Cloud, Enterprise and Digital Applicationsmatthew1001
 
Introduction to OFI
Introduction to OFIIntroduction to OFI
Introduction to OFIseanhefty
 
IBM MQ - Comparing Distributed and z/OS platforms
IBM MQ - Comparing Distributed and z/OS platformsIBM MQ - Comparing Distributed and z/OS platforms
IBM MQ - Comparing Distributed and z/OS platformsMarkTaylorIBM
 
Socket programming
Socket programmingSocket programming
Socket programmingDivya Sharma
 
web communication protocols in IoT
web communication protocols in IoTweb communication protocols in IoT
web communication protocols in IoTFabMinds
 
A Taste of Open Fabrics Interfaces
A Taste of Open Fabrics InterfacesA Taste of Open Fabrics Interfaces
A Taste of Open Fabrics Interfacesseanhefty
 
OFI Overview 2019 Webinar
OFI Overview 2019 WebinarOFI Overview 2019 Webinar
OFI Overview 2019 Webinarseanhefty
 
Communication middleware
Communication middlewareCommunication middleware
Communication middlewarePeter R. Egli
 
Hoti ofi 2015.doc
Hoti ofi 2015.docHoti ofi 2015.doc
Hoti ofi 2015.docseanhefty
 
HHM-2833: Where is My Message?: Using IBM MQ Tools to Work Out What Applicati...
HHM-2833: Where is My Message?: Using IBM MQ Tools to Work Out What Applicati...HHM-2833: Where is My Message?: Using IBM MQ Tools to Work Out What Applicati...
HHM-2833: Where is My Message?: Using IBM MQ Tools to Work Out What Applicati...Matt Leming
 

Was ist angesagt? (20)

Remote procedure calls
Remote procedure callsRemote procedure calls
Remote procedure calls
 
Sun RPC (Remote Procedure Call)
Sun RPC (Remote Procedure Call)Sun RPC (Remote Procedure Call)
Sun RPC (Remote Procedure Call)
 
Socket网络编程
Socket网络编程Socket网络编程
Socket网络编程
 
Sept 2017 internetworking
Sept 2017   internetworkingSept 2017   internetworking
Sept 2017 internetworking
 
Introduction to Remote Procedure Call
Introduction to Remote Procedure CallIntroduction to Remote Procedure Call
Introduction to Remote Procedure Call
 
Multimedia networks
Multimedia networksMultimedia networks
Multimedia networks
 
Getting started with libfabric
Getting started with libfabricGetting started with libfabric
Getting started with libfabric
 
Rpc
RpcRpc
Rpc
 
Ds objects and models
Ds objects and modelsDs objects and models
Ds objects and models
 
HHM 6894 Messaging APIs for Cloud, Enterprise and Digital Applications
HHM 6894 Messaging APIs for Cloud, Enterprise and Digital ApplicationsHHM 6894 Messaging APIs for Cloud, Enterprise and Digital Applications
HHM 6894 Messaging APIs for Cloud, Enterprise and Digital Applications
 
Introduction to OFI
Introduction to OFIIntroduction to OFI
Introduction to OFI
 
IBM MQ - Comparing Distributed and z/OS platforms
IBM MQ - Comparing Distributed and z/OS platformsIBM MQ - Comparing Distributed and z/OS platforms
IBM MQ - Comparing Distributed and z/OS platforms
 
Socket programming
Socket programmingSocket programming
Socket programming
 
web communication protocols in IoT
web communication protocols in IoTweb communication protocols in IoT
web communication protocols in IoT
 
A Taste of Open Fabrics Interfaces
A Taste of Open Fabrics InterfacesA Taste of Open Fabrics Interfaces
A Taste of Open Fabrics Interfaces
 
OFI Overview 2019 Webinar
OFI Overview 2019 WebinarOFI Overview 2019 Webinar
OFI Overview 2019 Webinar
 
Communication middleware
Communication middlewareCommunication middleware
Communication middleware
 
Remote procedure call
Remote procedure callRemote procedure call
Remote procedure call
 
Hoti ofi 2015.doc
Hoti ofi 2015.docHoti ofi 2015.doc
Hoti ofi 2015.doc
 
HHM-2833: Where is My Message?: Using IBM MQ Tools to Work Out What Applicati...
HHM-2833: Where is My Message?: Using IBM MQ Tools to Work Out What Applicati...HHM-2833: Where is My Message?: Using IBM MQ Tools to Work Out What Applicati...
HHM-2833: Where is My Message?: Using IBM MQ Tools to Work Out What Applicati...
 

Andere mochten auch (7)

Lecture7
Lecture7Lecture7
Lecture7
 
Lecture5
Lecture5Lecture5
Lecture5
 
Lecture6
Lecture6Lecture6
Lecture6
 
Lecture1
Lecture1Lecture1
Lecture1
 
Lecture8
Lecture8Lecture8
Lecture8
 
Lecture3
Lecture3Lecture3
Lecture3
 
Resume modifikasi daun dan filotaksis
Resume modifikasi daun dan filotaksisResume modifikasi daun dan filotaksis
Resume modifikasi daun dan filotaksis
 

Ähnlich wie Lecture2

Lecture 11 client_server_interaction
Lecture 11 client_server_interactionLecture 11 client_server_interaction
Lecture 11 client_server_interactionSerious_SamSoul
 
Adding Real-time Features to PHP Applications
Adding Real-time Features to PHP ApplicationsAdding Real-time Features to PHP Applications
Adding Real-time Features to PHP ApplicationsRonny López
 
Ports & sockets
Ports  & sockets Ports  & sockets
Ports & sockets myrajendra
 
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9Waqas Ahmed Nawaz
 
chapter-4-networking hjgjjgj did hfhhfhj
chapter-4-networking hjgjjgj did hfhhfhjchapter-4-networking hjgjjgj did hfhhfhj
chapter-4-networking hjgjjgj did hfhhfhjAmitDeshai
 
Cn application layer_paradigms
Cn application layer_paradigmsCn application layer_paradigms
Cn application layer_paradigmsRohitK71
 
Presentation on Application layer_201.pdf
Presentation on Application layer_201.pdfPresentation on Application layer_201.pdf
Presentation on Application layer_201.pdfprince2412001
 
Web essentials clients, servers and communication – the internet – basic inte...
Web essentials clients, servers and communication – the internet – basic inte...Web essentials clients, servers and communication – the internet – basic inte...
Web essentials clients, servers and communication – the internet – basic inte...smitha273566
 
It nv51 instructor_ppt_ch9
It nv51 instructor_ppt_ch9It nv51 instructor_ppt_ch9
It nv51 instructor_ppt_ch9newbie2019
 
Module 5 Application and presentation Layer .pptx
Module 5 Application and presentation Layer .pptxModule 5 Application and presentation Layer .pptx
Module 5 Application and presentation Layer .pptxAASTHAJAJOO
 
Unit 4-Transport Layer Protocols-3.pptx
Unit 4-Transport Layer Protocols-3.pptxUnit 4-Transport Layer Protocols-3.pptx
Unit 4-Transport Layer Protocols-3.pptxDESTROYER39
 
Unit 4-Transport Layer Protocols.pptx
Unit 4-Transport Layer Protocols.pptxUnit 4-Transport Layer Protocols.pptx
Unit 4-Transport Layer Protocols.pptxsarosh32
 
Module notes artificial intelligence and
Module notes artificial intelligence andModule notes artificial intelligence and
Module notes artificial intelligence andbhagyavantrajapur88
 
Clients and Servers.ppt
Clients and Servers.pptClients and Servers.ppt
Clients and Servers.pptMohammed Ilyas
 
Computer Networks Module 1-part 1.pdf
Computer Networks Module 1-part 1.pdfComputer Networks Module 1-part 1.pdf
Computer Networks Module 1-part 1.pdfShanthalaKV
 

Ähnlich wie Lecture2 (20)

Lecture 11 client_server_interaction
Lecture 11 client_server_interactionLecture 11 client_server_interaction
Lecture 11 client_server_interaction
 
Client server model
Client server modelClient server model
Client server model
 
1-1.pdf
1-1.pdf1-1.pdf
1-1.pdf
 
Adding Real-time Features to PHP Applications
Adding Real-time Features to PHP ApplicationsAdding Real-time Features to PHP Applications
Adding Real-time Features to PHP Applications
 
Ports & sockets
Ports  & sockets Ports  & sockets
Ports & sockets
 
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9
CCNA (R & S) Module 01 - Introduction to Networks - Chapter 9
 
chapter-4-networking hjgjjgj did hfhhfhj
chapter-4-networking hjgjjgj did hfhhfhjchapter-4-networking hjgjjgj did hfhhfhj
chapter-4-networking hjgjjgj did hfhhfhj
 
Cn application layer_paradigms
Cn application layer_paradigmsCn application layer_paradigms
Cn application layer_paradigms
 
Presentation on Application layer_201.pdf
Presentation on Application layer_201.pdfPresentation on Application layer_201.pdf
Presentation on Application layer_201.pdf
 
Web essentials clients, servers and communication – the internet – basic inte...
Web essentials clients, servers and communication – the internet – basic inte...Web essentials clients, servers and communication – the internet – basic inte...
Web essentials clients, servers and communication – the internet – basic inte...
 
Lecture set 7
Lecture set 7Lecture set 7
Lecture set 7
 
It nv51 instructor_ppt_ch9
It nv51 instructor_ppt_ch9It nv51 instructor_ppt_ch9
It nv51 instructor_ppt_ch9
 
Module 5 Application and presentation Layer .pptx
Module 5 Application and presentation Layer .pptxModule 5 Application and presentation Layer .pptx
Module 5 Application and presentation Layer .pptx
 
Application layer
Application layerApplication layer
Application layer
 
Unit 4-Transport Layer Protocols-3.pptx
Unit 4-Transport Layer Protocols-3.pptxUnit 4-Transport Layer Protocols-3.pptx
Unit 4-Transport Layer Protocols-3.pptx
 
Unit 4-Transport Layer Protocols.pptx
Unit 4-Transport Layer Protocols.pptxUnit 4-Transport Layer Protocols.pptx
Unit 4-Transport Layer Protocols.pptx
 
Module notes artificial intelligence and
Module notes artificial intelligence andModule notes artificial intelligence and
Module notes artificial intelligence and
 
Clients and Servers.ppt
Clients and Servers.pptClients and Servers.ppt
Clients and Servers.ppt
 
Computer Networks Module 1-part 1.pdf
Computer Networks Module 1-part 1.pdfComputer Networks Module 1-part 1.pdf
Computer Networks Module 1-part 1.pdf
 
Thick client application security assessment
Thick client  application security assessmentThick client  application security assessment
Thick client application security assessment
 

Lecture2

  • 1. Networking Principles IT1 Course Slide Instructor: Majid Taghiloo
  • 2. Functionality • Transport layer and layers below – B i communication Basic i ti – Reliability • Application layer – Abstractions • Files • Services • Databases – Names 2
  • 3. Dichotomy of Duties • Network – Transfers bits – Operates at application s request application’s • Applications determine – What to send – When to send – Where to send – Meaning of bits 3
  • 4. Important Point Although an internet system provides a  , p basic communication service, the protocol  software cannot initiate contact with, or  p f , p accept contact from, a remote computer.   Instead, two application programs must  participate in any communication: one  participate in any communication: one application initiates communication and  the other accepts it. the other accepts it. 4
  • 5. How Two Application Programs Make Contact • One application – Begins execution first g – Waits passively at prearranged location • A th application Another li ti – Begins execution later – Actively contacts first program • Called client‐server interaction 5
  • 6. Client‐Server Client Server Paradigm • Used by all network applications • Passive program called a server • Active program called a client 6
  • 7. Internet Communication All network applications use a form of  communication known as the client‐server  paradigm.  A server application waits  p passively for contact, while a client  yf , application initiates communication  actively. 7
  • 8. Characteristics of a Client • Arbitrary application program • Becomes client temporarily • Can also perform other computations • Invoked directly by user • Runs locally on user’s computer user s • Actively initiates contact with a server • Contacts one server at a time 8
  • 9. Characteristics of a Server • Special‐purpose, privileged program • Dedicated to providing one service • Can handle multiple remote clients simultaneously • Invoked automatically when system boots y y • Executes forever • Needs powerful computer and operating system • Waits passively for client contact • Accepts requests from arbitrary clients 9
  • 10. Terminology • Server – An executing program that accepts contact over gp g p the network • Server class computer Server‐class – Hardware sufficient to execute a server • Informally – Term server often applied to computer 10
  • 11. Direction of Data Flow • Data can fl flow – From client to server only – From server to client only – In both directions • Application protocol determines flow • Typical scenario – Client sends request(s) – Sever sends response(s) 11
  • 12. Key Idea Although the client initiates contact,  information can flow in either or both  information can flow in either or both directions between a client and server.   Many services arrange for the client to send  one or more requests and the server to  return one response for each request. 12
  • 13. Clients, Servers, Clients Servers and Other Protocols Clients and servers are application programs • 13
  • 14. Server CPU Use • Facts – Server operates like other applications • Uses CPU to execute instructions • Performs I/O operations – Waiting for data to arrive over a network does not require CPU time • Consequence – Server program only uses CPU when servicing a p g y g request 14
  • 15. Multiple Services • Can have multiple servers on single computer • Servers only use processor when handling a request • P Powerful h d f l hardware required to h dl many i d handle services simultaneously 15
  • 16. Illustration of Multiple Servers • Each server offers one service • One server can handle multiple clients 16
  • 17. Identifying a Service • Protocol port number used l b d • Each service given unique p number, P g q port • Server – Informs OS it is using port P – Waits for requests to arrive • Cli Client – Forms request – Send request to port P on server computer 17
  • 18. The Point About Ports Transport protocols assign each service a  unique port identifier.  A server must specify  unique port identifier A server must specify the identifier when it begins execution.  A  client must specify the identifier when it  client must specify the identifier when it requests transport protocol software to  contact a server.  Protocol software on the  server computer uses the identifier to direct  an incoming request to the correct server. 18
  • 19. In Theory • Port numbers are merely integers • Any server could use any port number 19
  • 20. In Practice • P t l port numbers used as service Protocol t b d i identifiers • Need uniform numbering – To allow arbitrary client to contact server on arbitrary machine – To avoid inventing “directory assistance” mechanism • Port numbers – Uniform throughout Internet – Set by standards bodies 20
  • 21. Terminology • Sequential program – Typical of most programs yp p g – Single thread of control • C Concurrent program t – Multiple threads of control – Execution proceeds “in parallel” – More difficult to create 21
  • 22. Servers and Concurrency • Sequential server – Also called iterative – Handles one request at a time • C Concurrent server t – Can handle multiple requests at a time – No waiting 22
  • 23. Delay in Servers • Concurrent server – Server creates new thread of control to handle each request – Client only waits for its request to be processed • Sequential server – Client waits for all previous requests to be processed as well as f it request t b processed for its t to be d – Unacceptable to user if long request blocks short requests 23
  • 24. Concurrency in Servers Concurrent execution is fundamental to  servers because concurrency permits  servers because concurrency permits multiple clients to obtain a given service  without having to wait for the server to  without having to wait for the server to finish previous requests.  In a concurrent  server, the main server thread creates a  new service thread to handle each client. 24
  • 25. Protocol Ports and Concurrent Servers • Apparent problem – One port number assigned to each service p g – Concurrent server has multiple copies (threads) running – Client and server may interact – Messages sent to server’s port must be delivered ’ b d li d to correct copy 25
  • 26. Protocol Ports and Concurrent Servers (continued) • Solution to problem: use i f l i bl information about i b client as well as server to deliver incoming packets • TCP uses four items to identify connection y – Server’s IP address – Server’s protocol port number Server s – Client’s IP address – Client’s protocol port number Client s 26
  • 27. Demultiplexing in a Concurrent Server Transport protocols assign an identifier to  Transport protocols assign an identifier to each client as well as to each service.   Protocol software on the server s machine  Protocol software on the server’s machine uses the combination of client and server  identifiers to choose the correct copy of a  identifiers to choose the correct copy of a concurrent server. 27
  • 28. Variations on a Theme • A server can use – Connectionless transport (UDP) – Connection‐oriented transport (TCP) – Both for a single service g • A single server can offer multiple services – Often used for “trivial” services trivial – Server uses multiple port numbers simultaneously 28
  • 29. Variations on a Theme (cont) • A server can – Maintain interaction with a client for days or hours y – Send a short response and terminate interaction – Perform I/O on the local computer – Become a client for another service (potential cycle problem) l bl ) 29
  • 30. Example of Circularity • Time server i – Returns time of day • File server – Allows client to read or write a file – Calls time server when generating time stamp for file • Suppose programmer modifies time server to log requests to a file 30
  • 31. Interacting with Protocol Software g • Client or server uses transport protocols • Protocol software inside OS • Applications outside OS • Mechanism needed to bridge the two – Called Application Program Interface (API) 31
  • 32. Application Program Interface • Part of operating system • Permits application to use protocols • Defines – Operations allowed – Arguments for each operation g p 32