Short paper on your servers performance

Assignment Help Computer Engineering
Reference no: EM13320843

Web Server

Your server will have to do a few different things. First, it will need to bind to a port specified as a command line argument. After successfully doing this, it must listen for incoming client connections and accept them. (Hint: all of the highlighted words are the names of system calls used to do these things).

The server will need to fork() a new process for each connection that it is handling. It is not quite this simple though. If you simply keep forking new processes, when the client closes its connection, you will end up with a zombie process. These zombie processes will build up and slowly eat up your machine's resources. Obviously, this isn't good.

To remedy this, you should write a signal handler for the SIGCHLD signal to properly dispose of zombified children (hehe).

After the new process has been created, the server is responsible for reading data from the client (recv) and parsing it as an HTTP request. We are only concerned with GET requests. Remember that handy dictionary you wrote in A1? That'll be really useful here, since HTTP headers are a key/value data structure.

Now that the GET request has been parsed, you can look up the file that is being requested. If the server can locate the file, it should form an appropriate response header and serve file back to the client with a 200 response code. If it can't find it, it should return a 404 response code. If there is some other kind of error, just throw a 500 response code.

Note that you should support enough of the HTTP protocol to allow a web browser to navigate to the port your server is running on and successfully get a file. This article should help you with that.

Profiling Your Server

After you have a working server (or before, doesn't really matter), you should write a client program to test your web server and gather various statistics on its performance. The statistics you collect are really up to you, but I recommend testing throughput (requests/second), the length of an average successful request vs. an unsuccessful one, and request time vs. file size. You can write the client in any language. Merry Christmas.

After you have gathered a solid amount of statistics, you should write a short paper on your server's performance. Point out bottlenecks and analyze the data that you've gathered, as well as coming up with a few suggestions on how you may be able to increase performance. This doesn't have to be a thesis, but it should be a solid analysis of what you've done.

https://github.com/funkenstein/WMU-CS2240

Reference no: EM13320843

Questions Cloud

What is the minimum coefficient of static friction : What is the minimum coefficient of static friction between the road and the tires on a car for the car to go around a flat curve at 45.0 mph
Determine what is the gage pressure in chamber a : Two chambers, A and B both have manometers with the same fluid with specific gravity 1.4. When h(sub a) = 6 cm and h(sub b) = 4 cm, what is the gage pressure in chamber A
What is the tension in the left-handed cable : A mass M is suspended using two cables which make angles of theta_1 and theta_2 with the horizontal across the top. What is the tension (T_1) in the left-handed cable
Analyse the supply and demand of labor in the country : Analyze the supply and demand of labor in the country
Short paper on your servers performance : A solid amount of statistics, you should write a short paper on your server's performance. Point out bottlenecks and analyze the data that you've gathered, as well as coming up with a few suggestions on how you may be able to increase performance
What is the minimum speed at the top of the circle : A 0.250 kg ball attached to a string s being swung in a vertical circle, What is the minimum speed at the top of the circle to keep the string from going slack
Calculate the required average strength fc for the concrete : Calculate the required average strength fc for the concrete ( a) if there are no prior test results for concrete with a compressive strength within 1000 psi of fc made with sim-ilar materials.
Calculate the amount the spring compresses : An elevator cable breaks when a 975 kg elevator is 24.5 m above the top of a huge spring (k = 8.00 x 10^4 N/m) at the bottom of the shaft. Calculate the amount the spring compresses
How is jainism different from buddhism : How is Jainism different from Buddhism? theological as well as historical similarities and differences between these two religions with special emphasis on their respective origins, goals, central teachings, and religious practices

Reviews

Write a Review

 

Computer Engineering Questions & Answers

  Design the program in vb.net

Write down the program in VB.Net (not Web based) and have it accept user input of the amount, term and interest rate. Display the mortgage payment amount.

  Explain a control object

express Control Object Properties. Why do we use them?

  Routing process

Access control is handled at the ____ layer at the time of routing process; the router consults the list of rules before forwarding the incoming packet.

  Is a shift toward dna based identifications a good idea

What are some of the benefits and limitations of using DNA to identify victims of mass causalities. When answering take into account available resources, types of attacks, evidence collection and preservation, etc.

  Define computer hardware - financial planning

In this recommendation, selecting only two kinds of computers (desktop, laptop, notebook or handheld computers) and other hardware components.

  Use the master theorem to solve bound

Prove bound is right using the substitution (induction) method

  Make use the vb.net programming to write statement

imagine that the array has a data type of frmMdiChildList having subscripts from 0 to 9. Configure the forms so that they appear as child forms of the MDI parent form named frmMdiParent.

  Why it is important to keep the web open and free

Tim Berners-Lee is called as the father of the Web. In "The Man who Invented the Web" (2005) it states that Berners-Lee has fought to keep it open, non-proprietary and free. Why would it be important to keep the Web open and free.

  Write down a driver program to test your library

create a library containing functions to compute the surface area and volume of a sphere. For a sphere of radius r, these values can be calculated using.

  Suppose two computers in each scenario need to exchange

What could you speculate regarding the time required to perform the transfer in each scenario? Explain your reasoning and support it with estimated calculations.

  Explain to a-company might set up auditing

define to A-Companyy how they might create a security template and some useful settings. What security suggestions do you have to secure communications from Human Resources server to the Payroll server.

  Generating ten random permutations

Write down a program which generates ten random permutations of numbers 1 to 10. To produce a random permutation, you require filling a vector along with the numbers 1 to 10 so that no two entries of vector have the same contents.

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd