Want to subscribe to topics you're interested in?
Become a Member

setup 2 website with 2 ip

Discussion in 'Domains, DNS, Email & SSL Certificates' started by xenbiarritz, May 30, 2017.

  1. xenbiarritz

    xenbiarritz Member

    44
    3
    8
    May 7, 2017
    Ratings:
    +4
    Local Time:
    6:19 AM
    hi

    I am on ovh vps.

    i already set my first domain with centminmod, i use the ip of the vps server for my first domain.


    i would like to add an other domain on my vps with his own ip

    so i bought a fail over ip
    i go to ovh manager and point dns to the new fail over ip and i don't know what to do next?

    thank for your help
    i did not create the new vhost for the second domain yet, any think special to do in this step?

    thank you
     
  2. eva2000

    eva2000 Administrator Staff Member

    54,647
    12,230
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,799
    Local Time:
    3:19 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
  3. xenbiarritz

    xenbiarritz Member

    44
    3
    8
    May 7, 2017
    Ratings:
    +4
    Local Time:
    6:19 AM
    Hi @eva2000 thanks a lot for the tuto

    if i understand correctly on centos 7
    i do

    Code:
    ifconfig
    and i add my ip failover like this

    Code:
    IPADDR1=ipfailover
    edit already existing ip
    Code:
    IPADDR0 existingIP
    restart server

    then create

    Code:
    /etc/centminmod/custom_config.inc
    and add
    Code:
    SECOND_IP=ipfailover
    then create my new vhost

    is that ok? it will not affect the first domain that is set with the server ip?
    when i create the new vhost, should i use the same hostname that i use for the 1 website, if it ask?

    thank you again for your help
     
  4. eva2000

    eva2000 Administrator Staff Member

    54,647
    12,230
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +18,799
    Local Time:
    3:19 PM
    Nginx 1.27.x
    MariaDB 10.x/11.4+
    yup that's correct
    no won't effect existing created nginx vhost sites
    no you won't be able to use same domain name as your existing first domain. If you only want to edit first existing domain to use 2nd IP, just edit nginx vhost for existing domain
     
  5. xenbiarritz

    xenbiarritz Member

    44
    3
    8
    May 7, 2017
    Ratings:
    +4
    Local Time:
    6:19 AM
    Perfect, thank you for your help.
    I will do it tomorrow