Welcome to Centmin Mod Community
Register Now

setup 2 website with 2 ip

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

  1. xenbiarritz

    xenbiarritz New Member

    8
    1
    3
    May 7, 2017
    Ratings:
    +1
    Local Time:
    6:41 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

    30,839
    6,903
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,393
    Local Time:
    3:41 PM
    Nginx 1.13.x
    MariaDB 5.5
  3. xenbiarritz

    xenbiarritz New Member

    8
    1
    3
    May 7, 2017
    Ratings:
    +1
    Local Time:
    6:41 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

    30,839
    6,903
    113
    May 24, 2014
    Brisbane, Australia
    Ratings:
    +10,393
    Local Time:
    3:41 PM
    Nginx 1.13.x
    MariaDB 5.5
    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 New Member

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