Site easily shot down with AB
ab -n 100 -c 10
only i changed first 100 to 10 000 and second to 100 but then whole site and server just stopped responding. I shut it down and restarted server and then it started working. But i am wondering what have happend. I dont see any spike on linode dashboard but my server is stuck, will somebody from other site also be able to do this to me and just shut my site/server down? and if so how do prevent this?
5 Replies
Disabling keepalives means that an IDLE browser won't keep one of those slots occupied. It gets in, and gets out - leaving that slot available for someone else.
For example, with MaxClients 20, if each request takes one second, that's about 81.5 million requests per month. Also keep in mind that a 'user' on your site typically makes a bunch of requests and then is done for a while (while they read your wonderful content). So a MaxClients of 20 really means 100s of users… Don't worry about it.
Better this than anyone or a search engine crawler being able to take out your Linode. You want to fix this in any case - webservers tend to ship with unfortunate defaults in distros. We see this all the time.
-Chris
says it helps with lots of images, and I do have them, lots of them per page. But i limited it to 70 KA requests and timout to 5. Think this could help make it work better, will see if problems occur to put this numbers lower or even disable it memory gets too crowded.
Also, it's easy to take down by a bad person, as you already found out. Even if you limit MaxClients to 20, someone can just use a tool like slowloris and DoS your server.