linux下apache安装以及反向代理的配置

阅读更多
apache2.2.x下的安装
1  ./configure --prefix=/usr/local/apache2
   --enable-mods-shared=all
   --enable-so
   --enable-rewrite
2  make
3  make install
4  /usr/local/apache2/bin/apachectl -k start

下来是代理的配置
在httpd-vhosts.conf 下配置

     ProxyPreserveHost On
     ServerAdmin [email protected]
     ProxyPass / http://112.78.124.124:8080/
     ProxyPassReverse / http://112.78.124.124:8080/
     ServerName shop.coojin.com
     ErrorLog logs/shop.coojin.com-error_log
     CustomLog logs/shop.coojin.com-access_log common



     ProxyPreserveHost On
     ServerAdmin [email protected]
     ProxyPass / http://112.78.124.124:7007/
     ProxyPassReverse / http://112.78.124.124:7007/
     ServerName kaoo.jp
     ErrorLog logs/kaoo.jp-error_log
     CustomLog logs/kaoo.jp-access_log common


在http.conf下配置
LoadModule proxy_module modules/mod_proxy.so
LoadModule proxy_ajp_module modules/mod_proxy_ajp.so
LoadModule proxy_balancer_module modules/mod_proxy_balancer.so
LoadModule proxy_ftp_module modules/mod_proxy_ftp.so
LoadModule proxy_http_module modules/mod_proxy_http.so
LoadModule proxy_connect_module modules/mod_proxy_connect.so
# Virtual hosts
Include conf/extra/httpd-vhosts.conf


  • proxy.rar (77.7 KB)
  • 下载次数: 8
  • httpd-2.2.15.tar.bz2 (4.7 MB)
  • 下载次数: 7

你可能感兴趣的:(Apache,Linux,Access)