Redirect to "internal server"

Discussion in 'Apache' started by igorsa, Aug 20, 2008.

  1. #1
    Hi all,

    I'm a beginner on server admin, and i have a problem with redirect on apache...

    My problem is:

    i have a server that can be access by the name www.example.com,

    i want that when this server is access using www.example.com/page, that the apache redirects to an internal server, with the name server1.

    My first attempt was use virtual host, like this:


    <VirtualHost *:80>
    DocumentRoot /var/www/html/
    RewriteEngine On
    RewriteRule ^/page http://server1/page
    </VirtualHost>

    but when i go to the browser and write www.example.com/page it says that the server http://server1/page don't exists, and it's true :)...

    thanks for any help
     
    igorsa, Aug 20, 2008 IP