Hi all, I run a small community . Iam using apache web server with smf forums on a vps with centos 7. I have all good firewalls going (csf) . Iam trying to solve an issue with a user crashing my7 forums. The memory on the vps and cpu will spike to 100% and create a "cannot connect to mysql database" error. on the apache error logs I get a mpm_prefork error showing AH00159 error out of memory. can anyone tell me how to prevent this attack. thanks.
Check your access logs. Someone is definitely scraping your forum, and this is what is causing the MySQL overload. One or two IPS, too many requests, in a very short time. Block that IP.
it wont matter if you ban the IP, I know the user, he is the king of getting new IPs using vpns. Iam running centos 7, apache, mysql and smf forums. i have csf firewall. is there any apache settings iam overlooking i can set. thanks. I forgot to mention, he can only do this while forums are open. if I put the forum in maintaince mode and restrict access to only admins. he cant do this or take down apache or mysql
Use CloudFlare, whitelist the reverse proxy ip ranges in your firewall, and remove ports 80,443/tcp and 443/udp from your firewall whitelist so only CloudFlare can hit your server. This should improve stability by leaps and bounds.
1. Setup a CDN, like CloudFlare which is free. The free version will do a good job at blocking false visits and attacks like this. 2. Why can't you just block this user? 3. You should use MPM_event as it will perform much better, your MySQL also needs tuning so it can accept more connections. 4. Nginx would also work well with your forum but would need rewrite rules setup. 5. Setup a rule in your firewall to block XX number of connections from the same IP or similar class C subnet.
thanks alot, ive overlooked those things and have csf firewall working perfectly with cloudlfare and everything locked down.
Sorry to hear, One golden rule is not to install software that you have no trust in. Meaning audit source code prior installing. If no SC is available, or authors/devs deny your right to audit, than just ignore and use alternative/s