Question: Please Can you explain what the server and client sides should do, and give the piece of code written in c language for serve and

Please Can you explain what the server and client sides should do,and give the piece of code written in c language for serveand client. It would be great if you could share the samplemakefile. Note: In such system programming course questions, the full code is

Please Can you explain what the server and client sides should do, and give the piece of code written in c language for serve and client. It would be great if you could share the sample makefile. Note: In such system programming course questions, the full code is not given or the faulty piece of code is sent to us. I would be very grateful if you could make sure the code works. Thank you for your help.

MybiboBor, A Concument File Access System Description: This assigment is similar to your midtern project, with the only difference being that you will be creating threads instead of processes to handle client requests. This means you will need to implement a thread pool. On the server side, instead of creating a separate process for each request, a thread from the thread pool will be assigned to hancle each request To begin, give the size of the thread pool as an argument on the server side (try values such as 5,10 , or 20 ). Size on "server side" creates a thread pool that can be set (try with 5,10,20 ). This is how they will communicate with their previously written clients. Your task is to design and implemsent a file server that enables multiple clients to connect, access and modify the contents of files in a specific directory. The project should be implemented as a server side and a client-side programs. Server side : biboServer ccirnames umax. fofClientsyopoolSizes- The Server side would enter the specified directocy (creste dimaxe if the dimnwe does not exits). create a log file for the clierts and proumt its PD for the clients to cornect. The for each client connected will fouk a copy of itself in order to serve the specified client (commands are given on the client side). If a kill signal is generated (either by Ctrl-C or from a client side request) Server is expected to display the request, send kill signals to its child processes, ensure the log file is created properly and exit. An exanple of the Server screen output might be in the following form: > biboServer Here 3 20. Server Started PID 104065 20. waiting for clients. so Client PID 106055 connected as "client01" so client01 disconnected. so. Client PID 106065 connected as "client02" so. Client PID 106074 connected as "client03" so. Client PID 106076 connected as "client04" so. Connection request PID 106008... Que FULL so client03 disconnected. so Client PID 106008 connected as "client05" so kill signal from dient05. terminating. 20 bye Client side: biboClient wConnect/tryConnect. ServerPID the client prognm with Connect option request a spot from the Server Que with ServerPID and connects if a spot is available (if not the client should wait until a spot becomes avaibable, tryConnect option leaves without waiting if the Que is full). When connected the client can perform the following requests : - help display the list of possible client recuests - list sends a request to displry the list of files in Servers directory (also displays the list received from the Server) readF file line = requests to display the \# line of the ciles, if no line mumber is given the whole cortents of the file is requested (and cisplayed on the client side) witeT file line = string request to write the content of "sting" to the fth line the cfile", if the line \# is not given wites to the end of file. If the file does not exists in Servers directory crentes and edits the file at the same time upload file? uploods the file from the carrent working directory of client to the Servers directory (beware of the cases no file in clients current wodking directory and file with the same nome on Servers side) download file: request to receive file> from Servers directory to client side quil Send write request to Server side log file and quits killserver Sends a kill request to the Server An example of the Server screen output might be in the following form: s biboclient connect 104065 2o. Waiting for Que. Connection established: >o. Enter comment : help Available comments are : 20. Enter comment: help readF read F sfiles rline \# display the \#th line of the ufiles, retums with an error if wiles does not exists Enter comment : list Home.tot Work.bin le.tut importanteve Enter comment : upload question.exe file trancfer request received. Beginning file transfer: 124354 bytes troneferred so Enter comment : quit Sending write request to server log file waiting for logfile... logfile write request granted bye.. Requirement: - Your Server prognam should be able to hanile multiple processes accessing files similtaneously. - Your prognom should enforce mutul exchasion to prevent race conditions. - Your prognem should ensure data consistency and avoid data comuption. - Your prognom should allow for file read and wite operations. - Your prognm should be able to handle large files (ie. >10MB ). - Your prognm should be able to handle different file formats (ie text, binry). - Your prognm should use multiple processes for file access and synchronimation. - Signals should be hancled properly on boch client and Server sides Suggested Steps: 1. Design a high-level architecture for your system, including the mubber of processes and bow they will coumunicate with exch other. 2. Irplement a file IO mochle that can handle read and write operations for different file formats. 3. Implement a synchronimation mocule that provides mutual exclusion and prevents race conditions. 4. Integate the file IO and synchronization modules to create a concumrent file access system 5. Test your system with multiple processes accessing files simmltaneously and verify that data consistency is maintained. Deliverables: - A document describing your system architecture, design decisions, and implementation details. - A source code for your concurrent file access system (for the Server and Client) and a makefile to coumile the project as a whole. - A test plan and results demonstating that your system meets the requirements. The project requires inter-process coumunication and multiple synchronimtion prinitives. Inplementations lacking these requirements would not be graded

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related General Management Questions!