How to install Apache mod_limits module on CentOS WebPanel?
This apache module is aimed at protecting the web server during attacks.

It provides a few, very usefull, functionalities:

* Limit the maximum number of simultaneous connections
* Limit the maximum number of simultaneous connections per Vhost
* Limit the maximum number of spawned processes with the same UID
* Do not serve request if the load is over certain value

Install development packages

yum install apr-devel apr-util-devel apr apr-util

Download and Install Apache mod_limits module

cd /usr/local/src
cd mod_limits-master
/usr/local/apache/bin/apxs -a -i -c mod_limits.c

Add this configuration to file: /usr/local/apache/conf.d/mod_limits.conf

LoadModule limits_module modules/
<IfModule mod_limits.c>
    LimitMaxConnsPerVhost 20
    LimitMaxConnsPerUid 20
    LimitMaxConnsPerIP 80
    LimitMaxLoadAVG 10
    CheckLoadInterval 5

* Make custom changes based on the limits you want to have set.

Please note that ExtendedStatus needs to be set to On in

At the end restart apache to load new changes

service httpd restart

Home page

Last testing done with apache 2.4.26.