config ns1 and ns2

Hi, I’m new to the VPS world, create a VPS in Digital Ocean and install virtual min.

I have a doubt.

I have the domain1.com and domain2.com

Both domains I have registered at name.com
and both are targeted to ns1.digitalocean.com and ns2.digitalocean.com

the domain1.com is the one that I have configured in Digitalocean, created the corresponding DNS.

On that domain1 install virtuamin.
To enter tipeo dominio1.com:10000

until there everything perfect.

Now within Virtuamin create a Virtual server.

When I try to ping or enter through any browser, it will not let me.

I calculate that the problem is that the NS1 and NS2 should point to the virtuamin and not to digitl ocean, I’m right ???

I did not find in virtuamin how to confirm those 2 details nor the name that I should put in name.com to the ns1 and ns2 of domain2

Thank you

hi gLew,

  1. you have a digital ocean droplet on which you installed virtualmin
  2. Make sure at your domain registrar, you have added custom name server records that enable your domain registrar server to tell the world to ask digital ocean’s nameservers (ns1 and ns2) in order to find the server location (ipaddress) where your website is being hosted
  3. in your digital ocean interface ns records, you need to also add the ipaddress of your droplet and any cname records etc. Otherwise, when the registrar server tell’s the world to go to digital oceans name servers for the ipaddress, digital ocean’s name servers dont actually have any ip address in them yet in order to tell the world what you website ipaddress is. the result will be an error.
  4. Also ensure that you have added a rule opening port 10000 on your digital ocean droplet as it most likely isnt open by default.
  5. as a final check, ensure that you are installing the website for domain2.com into the correct directory in apache. I think from memory apache can use 1 of at least 3 locations for the web directory. Having said this, if you are using a standard virtualmin install from the installer script, im pretty sure it should already be configured correctly anyway (but worth checking just the same)
  6. Goto https://mxtoolbox.com/SuperTool.aspx and use this interface to check if your server and hence website are reachable. I use mxtoolbox all the time, its a valuable tool.

based on your original post above, it appears you are not using Bind dns in virtualmin, so you do not need to manually add any nameserver records inside virtualmin itself. You would do this is only if you have setup your droplet to be one of the nameservers (of course you could do this if you wanted to)

EDIT…
a simple workaround for all of the above is to not use nameserver records at all but instead, do the following at your registrar…

go to registrar domain zone records and simply add an “A record” pointing the domain directly at the ip address of your digital ocean droplet where your virtualmin install is located. You may do this for all virtual server on your virtualmin install.

Just 2 caveats about A records at the registrar…

  1. some registrars do not provide free dns hosting
  2. if you have many clients in my opinion this would not be a good idea because if for some reason you need to move servers to a new ip address, then every client website will go offline until they manually update their A records. By having clients instead point their domains at your own nameservers you can control all of this updating yourself without worrying clients to do it themselves.

Hi Thanks for the fast reply.

I make this only for me, i have 3 sites and like to use a VPS, im totaly newbie.

  1. Perfect
  2. In name.com i have domain1.com (the domain of the droplet) with the ns1 and ns2 of digital ocean.
    2b. in name.com i have the domain2.com (the virtual server in virtuamin) with de ns1 and ns2 of digital ocean (i need to change this 2 ns to the virtuamin ns??)
    3 in my Digital Ocena in the domain records i have 5 DNS records
    A - www.domain1.com - ip of droplet
    A - domian1.com - ip of droplet
    NS - domain1.com - ns1.digitalocean.com
    NS - domain1.com - ns2.digitalocean.com
    NS - domain1.com - ns3.digitalocean.com

in the digital ocean dns records dont say nothing about the domain2
i need to add something in the digitalocean dns records???

  1. Perfect
  2. I think yes
  3. Sorry, we couldn’t find any name servers for 'www.domain2.com

Thanks
Sorry my english