Forum Moderators: phranque
# aptitude purge apache2 apache2-utils apache2.2-bin apache2.2-common
# rm -fr /etc/apache2 /var/www /var/log/apache2
# aptitude -y install \
apache2 apache2-mpm-prefork \
libapache2-mod-perl2 libapache2-mod-php5 \
libapache2-mod-python libapache2-reload-perl \
nagios3 nagios3-cgi
# a2enmod rewrite
LogLevel debug
LogFormat "%h %l %u %t \"%r\" %>s %O \"%{Referer}i\" \"%{User-Agent}i\" \"%e\"" combined
RewriteEngine on
RewriteLog /var/log/apache2/rewrite.log
RewriteLogLevel 7
RewriteRule ^ - [env=FOO:BAR]
RewriteRule ^/*(.*) http://192.168.3.51/$1 [L,R,NE] http://192.168.168.51 displays the as-installed index.html but still with http://192.168.168.51 in the URL bar. Then ... <VirtualHost *:80>
ServerAdmin webmaster@localhost
DocumentRoot /var/www
<Directory />
Options FollowSymLinks
AllowOverride None
</Directory>
<Directory /var/www/>
Options Indexes FollowSymLinks MultiViews
AllowOverride None
Order allow,deny
allow from all
</Directory>
ScriptAlias /cgi-bin/ /usr/lib/cgi-bin/
<Directory "/usr/lib/cgi-bin">
AllowOverride None
Options +ExecCGI -MultiViews +SymLinksIfOwnerMatch
Order allow,deny
Allow from all
</Directory>
ErrorLog ${APACHE_LOG_DIR}/error.log
# Possible values include: debug, info, notice, warn, error, crit,
# alert, emerg.
LogLevel warn
CustomLog ${APACHE_LOG_DIR}/access.log combined
Alias /doc/ "/usr/share/doc/"
<Directory "/usr/share/doc/">
Options Indexes MultiViews FollowSymLinks
AllowOverride None
Order deny,allow
Deny from all
Allow from 127.0.0.0/255.0.0.0 ::1/128
</Directory>
</VirtualHost>