Starting from:

$25

CS3093D - Networks Lab - Assignment – III  - Solved

1.      Implementation of basic Client Server program using both TCP and UDP Socket. 

Write a client/server program with the socket interface. The server has the list of five fruits ‘apple’, ‘mango’, ‘banana’, ‘chikoo’ and ‘papaya’ available along with their count stored in a buffer. The user presses “Fruits” and the server responds with “Enter the name of the fruit”. The user then responds with the fruit name and the count. The server decreases the count of the entered fruit value from its buffer. If the count of the fruit the user needs is more than the available count, the server responds with “Not available”. Once someone keys in "SendInventory", the server will send a message which includes all the fruit names along with their count.  

 

2.      Write a client/server program with the socket interface. The client program may send out the words to the server once the user presses "Enter" and the server will respond to these words with any meaningless terms. However, the server will close the connection once it receives the word "Bye". Also, once someone keys in "GivemeyourVideo", the server will immediately send out a 50 MB data file with message size of 500 bytes. 

a)      Calculate and record the data transmission rate every 0.1 second for a 50 MB data transmission with message size of 500 bytes. 

b)      Use xgraph and gnuplot to display the results [Hint: Use timer and handler functions]. 

c)      Create a socket that implements stop and wait ARQ protocol and analyze the RTT for varying message sizes. 

 

More products