1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice
  2. Dear Pleskians, please read this carefully! New attachments and other rules Thank you!
    Dismiss Notice
  3. Dear Pleskians, I really hope that you will share your opinion in this Special topic for chatter about Plesk in the Clouds. Thank you!
    Dismiss Notice

One site on 2 IP's?

Discussion in 'Plesk 10.x for Linux Issues, Fixes, How-To' started by keff, Aug 25, 2011.

  1. keff

    keff Basic Pleskian

    25
    57%
    Joined:
    Dec 3, 2007
    Messages:
    88
    Likes Received:
    0
    Hi,

    it is possible to get working One site on two IP's in Plesk? If it is how do I do this?
     
  2. paulieG

    paulieG Regular Pleskian

    25
     
    Joined:
    Mar 5, 2009
    Messages:
    164
    Likes Received:
    0
    Location:
    Lancaster
    Hi,

    One site? One domain? Whats the use case?

    If its one site, two domains then the technique we use on 8 and 9 is to create the one domain (the primary) and put all the data on this one, then create the 2nd site and point it to the first using a vhost.conf (and vhost_ssl.conf) that sets the document root to the primary domain. We use mod_php so our vhost.conf would be :

    You'd need a different configuration for fastCGI, but this technique should work fine on Plesk 10.

    Paul
     
  3. keff

    keff Basic Pleskian

    25
    57%
    Joined:
    Dec 3, 2007
    Messages:
    88
    Likes Received:
    0
    I mean one domain on two IP's. Such as in apache:
    Name VirtualHost IP1
    Name VirtualHost IP2
    <VirtualHost IP1, IP2>.

    Thats my problem.
     
  4. paulieG

    paulieG Regular Pleskian

    25
     
    Joined:
    Mar 5, 2009
    Messages:
    164
    Likes Received:
    0
    Location:
    Lancaster
    Hi,
    We're getting a little beyond my knowledge but I think thats impossible even outside of Plesk, since the vhost name is what defines it uniquely.

    Why are you wanting to do this?

    Paul.
     
  5. keff

    keff Basic Pleskian

    25
    57%
    Joined:
    Dec 3, 2007
    Messages:
    88
    Likes Received:
    0
    The apache manual says:

    Serving the same content on different IP addresses (such as an internal and external address).

    The server machine has two IP addresses (192.168.1.1 and 172.20.30.40). The machine is sitting between an internal (intranet) network and an external (internet) network. Outside of the network, the name server.example.com resolves to the external address (172.20.30.40), but inside the network, that same name resolves to the internal address (192.168.1.1).

    The server can be made to respond to internal and external requests with the same content, with just one VirtualHost section.

    Server configuration

    NameVirtualHost 192.168.1.1
    NameVirtualHost 172.20.30.40

    <VirtualHost 192.168.1.1 172.20.30.40>
    DocumentRoot /www/server1
    ServerName server.example.com
    ServerAlias server
    </VirtualHost>
    Now requests from both networks will be served from the same VirtualHost.

    I know this is specific configuration, for internal and external network, but I think i can be run for two external IP's.
     
Loading...