ModSecurity: ModSecurity requires mod_unique_id to be installed


If modsec throws this error in apache error_log

ModSecurity: ModSecurity requires mod_unique_id to be installed

Sol:- cpanel server

cd /home/cpeasyapache/src/httpd-x.x.x/modules/metadata

/usr/local/apache/bin/apxs -i -a -c mod_unique_id.c

cheeck apache configuration

/usr/local/apache/bin/apachectl configtest

If syntax ok, restart apache

If not cpanel server, download the apache version source file from  http://archive.apache.org/dist/httpd/

Eg:

[root@server ]# /usr/sbin/httpd -v
Server version: Apache/2.2.9
wget http://archive.apache.org/dist/httpd/httpd-2.2.9.tar.gz

tar -zxf httpd-2.2.9.tar.gz

cd httpd-2.2.9

/usr/sbin/apxs -i -a -c mod_unique_id.c

/etc/rc.d/init.d/httpd configtest

/etc/rc.d/init.d/httpd graceful

About these ads

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s