Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I've read a few tutorials on setting up a server on HowtoForge etc.. So I'm aware of the installation and software requirement part. However , how do I go about assigning domains to my server. When I set my VPS up , it only asked me for a hostname. How do I point domains to my server ? I use GoDaddy as a registrar. Thanks in advance

share|improve this question
up vote 1 down vote accepted

At a very simple level- at your registrar you can amend the DNS records for the domain - you would point the A (and possibly MX for mail) records at the public IP address allocated to your VPS. There's a huge variety of options depending on what exactly you want to do. Provide a little more info for a more detailed answer.

share|improve this answer

With GoDaddy, you go to the DNS management tool and point your DNS records at the IP address of your VPS.

To configure Apache to handle multiple domains, you need to look at the VirtualHosts directive. An except from mine:

NameVirtualHost *:80

# ie - if anything directs here and has no matching domain, presume default domain
<VirtualHost *:80>
    DocumentRoot /var/www/<mainsite>
    ServerName www.<mainsite>.com
    ServerAlias <mainsite>.com *.<mainsite>.com
    ErrorLog logs/<mainsite>-error_log
    CustomLog logs/<mainsite>-access_log common
    ServerAdmin myemail@domain.tld

<VirtualHost *:80>
    DocumentRoot /var/www/othersite
    ServerName www.<othersite>.com
    ServerAlias <othersite>.com *.<othersite>.com
    ErrorLog logs/<othersite>-error_log
    CustomLog logs/<othersite>-access_log common
    ServerAdmin <admin>

Configuring sendmail for multiple domains is a teensy bit harder than apache - a restart of apache (or apachectl graceful) will load any new virtual domains.

share|improve this answer

Check with your VPS provider. Often, they would provide you with configuration entries for the two DNS servers. So, you would then need to sent these entries in the DNS section of your GoDaddy account. This will allow your VPS provided DNS servers to serve as the authoritative servers for your domain.

Alternatively, you could use an alternative DNS service provider (e.g. Zoneedit) and configure the appropriate A-record and CNAME-records to point to your VPS provided IP. Then, configure GoDaddy to use the Zoneedit servers as the authoritative DNS servers.

share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.