                      Computer Science 481/681
                         Quiz B           Name _______________________

1. For each of the following system calls used in a client / server
   application answer S, C, or B based upon whether the call would
   normally be used by the Server, the Client or Both

   ____ a. socket()

   ____ b. bind()

   ____ c. connect()

   ____ d. listen()

   ____ e. accept()


2. Which of the following best describes the connection model used
   in the multi-threaded (multi-process) server we described in class.

   a. Each server process was       b. Each server process used the
      connected through a unique       same port and socket.
      port.

   c. Each server process used the  d. Each server process was connected
      same port but used a unique      through a unique port but they
      socket.                          all used the same socket.

3. Answer the following B or NB depending on whether the system call
   is  Blocking or NonBlocking (a Blocking system call is one in which
   an arbitrarily long delay can occur between making the call and
   the return form the call).

   ____ a. bind()

   ____ b. listen()

   ____ c. connect()

   ____ d. accept()


4. The sequence of states: FIN-WAIT-1, FIN-WAIT-2, TIME-WAIT will
   occur in:

   a. The end of the connection      b. The end of the connection that
      that is last to close.            is first to close.

   c. Only in the case of a          d. Always in a server but never
      simultaneous close.               in a client.

5. The function achieved by use of the Nagle algorithm is to:

   a. Improve the response of        b. Reduce the number of small
      interactive connections.          segments in the networks.

   c. Improve the throughput of
      the network measured in
      segments transmitted per second.

6. Studies of internet traffic shows that interactive traffic
   accounts for

   a. 90% of the packets and 90%    b. 10% of the packets and 10%
      of the bytes transmitted.        of the bytes transmitted.

   c. 50% of the packets but only   d. 10% of the packets but 50%
      10% of the bytes transmitted.    of the bytes transmitted.

7. Match the TCP close state names with the appropriate description.

   ____ a. FIN_WAIT_2:    1. Have sent FIN but not yet received an ack for it.

   ____ b. LAST_ACK:      2. Have received an ACK from my FIN but haven't
                             received FIN from the other end yet.
   ____ c. CLOSING:       3. Have sent and received FIN and have ACKed
                             other end's FIN (State occupancy time is 2MSL).
   ____ d. CLOSE_WAIT:    4. Received FIN from the other end before receiving
                             ACK of my FIN from the other end .
   ____ e. TIME_WAIT:     5. Received FIN from the other end and am
                             waiting for the client or server to close on my end.
   ____ f. FIN_WAIT_1:    6. Sent the final FIN and am waiting for an ACK.



