Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I am wondering why websites crash at all.

If a server has too many requests, it might queue up the request in its waiting lists and serve it when all the earlier requests have been served. That means that the request for the website will be taken care of, although it may take some more time than expected.

Then, how do websites crash due to server overload?

share|improve this question

migrated from superuser.com May 12 '10 at 0:57

This question came from our site for computer enthusiasts and power users.

add comment

3 Answers 3

up vote 2 down vote accepted

Web sites do not "crash".

Web servers are configured to stop accepting new visitors if the requests in the request queue exceeds a predetermined number. When this limit is reached, an error message is displayed.

503 Service Unavailable

The server is currently unable to handle the request due to a temporary overloading or maintenance of the server. The implication is that this is a temporary condition which will be alleviated after some delay. If known, the length of the delay MAY be indicated in a Retry-After header. If no Retry-After is given, the client SHOULD handle the response as it would for a 500 response.

  Note: The existence of the 503 status code does not imply that a
  server must use it when becoming overloaded. Some servers may wish
  to simply refuse the connection.
share|improve this answer
    
@TFM: Does this mean that the server is still handling requests, just that my request is too long way back in the queue for it to handle properly? –  Lazer May 11 '10 at 20:21
1  
It depends. Before a request reaches the web server software, it has to pass through a network, the network interface on the machine, and the operating system. If any of these factors cannot cope with the amount of requests sent to the server, the request will not even reach the web server software. In that case, there will not be any 503-response from the server at all. –  TFM May 11 '10 at 20:27
add comment

In a very simple scenario, the waiting list might fill up and the server is so busy handling/ignoring new requests that it can efficiently deal with requests in the queue.

Take a look at http://en.wikipedia.org/wiki/Denial-of-service_attack

share|improve this answer
add comment

Lots of ways:

  • There's only so much bandwidth available to the server. If an attacker is able to flood the target web site's connection with traffic, he can take the site offline.
  • "queue up the request in its waiting lists and serve it when all the earlier requests have been serve" Queuing requests takes time in itself. If an attack can send requests faster than the server is able to queue them, he can take the site offline.
  • The web server depends on other resources, like a database server or the file system. If an attack can send enough requests to overload the database, he can take the site offline.
share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.