First VPS, some problems

I got my VPS today. Installed CentOS 5. And it says the only virtual serever I have is site1.com

So I installed virtualmin and gave site1.com as hostname. Now I tried to creat a new virtual server via virtualmin for site1.com but it won’t let me. This is because you cannot use the hostname as a virtual server. So how am I expected to upload files onto site1 and use it as a site? Or when I installed should the IP have been the host name?

Another problem I have is creating private nameservers. I have an IP for my VPS so do I just go to my domain registrate and register private server for ns1 and ns2 using that ip?

Howdy,

Whenever you have a server, it should use an “FQDN” as the hostname… an FQDN means that it is in the format “host.domain.tld”.

My recommendation would be to change your system’s hostname so that it’s something like “server1.site1.com”.

Then, you’ll be able to create a Virtual Server named site1.com.

As far as creating nameservers goes – not all registrars will allow you to register two nameservers with just one IP address. But you can try it, that might just work! There’s instructions on setting up nameservers here in the question titled “How do I setup nameservers for my server”:

https://www.virtualmin.com/documentation/dns/faq

Thank you andrey. so just to verify I should reinstall virtualmin and post-installation settings I should use hostname server1.site.com?

Nope! You can make all those changes without reinstalling.

You can do the following:

  • Go into Webmin -> Networking -> Network Configuration, and change the “Hostname” field to be your desired hostname.

  • Then go into Webmin -> Networking -> Network Configuration -> Host Addresses, and make sure your hostname is listed correctly there next to your primary IP address.

  • Lastly, go into Webmin -> Servers -> Postfix -> General Options, and add your system’s new hostname to the end of the “What domains to receive mail for” option.

After you do that, you should be in good shape!

-Eric

Okay in Network Configuration my hostname is site1.com (site.com is the account in my solusvm)

In Host Addresses site1.com is listed with correct ip (ip of virtualadmin)) and is correctly placed in Postfix General options.

Yet when I try to add new serveri says Failed to create virtual server : AWstats reporting is already enabled for this domain.

Sorry to keep asking for help. Trying to learn new things. Thanks andrey

Okay in Network Configuration my hostname is site1.com

Mmm, well, you’d want to make sure that your hostname is in the “host.domain.tld” (FQDN) format, or else you could run into problems. So, rather than “site1.com”, you’d want to use “server1.site1.com” as your hostname.

As far as that AWStats error goes – chances are something went wrong during the previous attempts to create that domain, and some remnants of that are still laying around.

If you log into your server as root over SSH, and ‘cd’ into /etc/awstats, you’ll see a file that is named something like:

awstats.site1.com.conf

You may need to delete that file, and then try adding your Virtual Server again.

-Eric

Thank you Andrey, that helped me too…