Knowledgebase

DDoS Attacked - SQL CPU Load Issue

Posted by da3m0n, 10-23-2010, 04:03 PM
Hello! My first post! I work in SEO and only have basic linux / database skills. A number of my sites fell victim to an ongoing DDoS attack, we were on a VPS but moved to a dedicated DDoS protected server with an Application Firewall and using LiteSpeed rather than Apache, however, the SQL usage is through the roof. This is caused by the attack on one certain database driven website where the GET attack is repeatedly requesting a product page. I have done my best to remove any thing that would cause unnecessary SQL load on the page and have optimised all of the tables which has reduced the load considerably, however: It's still running really high. It's been fun trawling the net looking for a solution to this and learning new things, but I've been persevering for a few days now and only managed to halve the SQL load. I've tried enabling and increasing SQL caching in the my.conf but any changes to that file (even drastic ones) have little to no effect on the SQL load. Any help on this would be majorly appreciated! Last edited by da3m0n; 10-23-2010 at 04:07 PM.

Posted by vapetrov, 10-23-2010, 04:13 PM
It impossible to avoid even small DDoS just by optimizing dynamic with sql requests. You can decrease server load by converting attacked pages to clear static HTML. But the best way is to block attacker's IPs by iptables. Try to use a log-to-ban script. It is effective way to fight against small and medium DDoS.

Posted by plumsauce, 10-23-2010, 04:38 PM
If it's a product page, which means that the db is only used to produce a page from a catalog, but it is the same everytime, then put the site behind a proxy like nginx. Let the proxy trigger the creation of the page and then let the proxy cache and serve the page.



Was this answer helpful?

Add to Favourites Add to Favourites

Print this Article Print this Article

Also Read
dns.he.net down (Views: 615)


Language:

Client Login

Email

Password

Remember Me

Search