I guess that you somewhat extent got the knowledge of server and client.
In our daily life, in the internet, we usually send the request to servers and servers provides us the information about the page. This is how the server and client works. The only data we get is the reply from the server. If the server is not responding that means the server is not getting the request that client sends.
For example, a server machine might have software running on it that allows it to act as a Web server, an e-mail server and an FTP server. Clients that come to a server machine do so with a specific intent, so clients direct their requests to a specific software server running on the overall server machine. For example, if you are running a Web browser on your machine, it will most likely want to talk to the Web server on the server machine. Your Telnet application will want to talk to the Telnet server, your e-mail application will talk to the e-mail server, and so on…
The client’s responsibility is usually to:
- Handle the user interface.
- Translate the user’s request into the desired protocol.
- Send the request to the server.
- Wait for the server’s response.
- Translate the response into “human-readable” results.
- Present the results to the user.
The server’s functions include:
- Listen for a client’s query.
- Process that query.
- Return the results back to the client.
The architect of typical client/server interaction goes like this:
- The user runs client software to create a query.
- The client connects to the server.
- The client sends the query to the server.
- The server analyzes the query.
- The server computes the results of the query.
- The server sends the results to the client.
- The client presents the results to the user.
- Repeat as necessary.
Happy socket coding…….