In Apache web server, Modproxy module for redirecting connections and not a single module its a collection of them. This post describe about mod_proxy and modproxyhttp only.
mod_proxy : This is a main module implements that managing collections and redirections
modproxyhttp: This mod_proxy_http module implements to proxy features for HTTP and HTTPS protocols.
Install Apache server if is not yet installed in Ubuntu,
# sudo apt-get update
# sudo apt-get install apache2
# sudo service apache2 restart
# sudo apt-get install apache2
# sudo service apache2 restart
How to Enable Proxy:
You can enable these modules using a2enmod. For example:
# a2enmod proxy
The above command will create a symlink /etc/apache2/mods-enabled pointing to /etc/apache2/mods-available.
If you want to disable a module use a2dismod, This will help you to remove symlink from the mods_enabled directory
# a2dismod proxy
Then, open a apache2 configure file by any text editor vim or vi,
# vim /etc/apache2/apache2.conf
add the below lines to enable modules and also make sure that the moudles are available in /usr/lib/apache2/modules
LoadModule proxy_module /usr/lib/apache2/modules/mod_proxy.so
LoadModule proxy_http_module /usr/lib/apache2/modules/mod_proxy_http.so
Save that updated file
:wq!
Restart your apache2 server using below command,
# service apache2 restart
To make ensure that the modules are enabled in Apache,
# apache2ctl -M | grep proxy
proxy_module (shared)
proxy_http_module (shared)
Comments (0)