Ask Ubuntu is a question and answer site for Ubuntu users and developers. 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 recently purchased a VPS hosting (rackspace) and want to configure a domain for this account. I've configured nginx and other stuff to run Ruby on Rails on it. And everything works perfectly when I reach it by its ip. I've changed the domain DNS servers at my domain registrant to point to my hosting. I've been waiting for 48+ hours but still no luck. Maybe I should add some configuration on the server side? Please help.


share|improve this question
Does the domain correctly resolve to the VPS's IP? host domain.tld, replacing domain.tld with the actual domain, will give you the answer for that. If that resolves, then it's probably a config issue and I can help with that. – Thomas Ward Jun 2 '13 at 19:24
Should I run this command via terminal? host – Dima Knivets Jun 2 '13 at 19:32
If yes, it doesn't return anything. – Dima Knivets Jun 2 '13 at 19:38
replace domain.tld with your actual domain though when you run the command via the terminal. If you don't have one, then that's the first thing you need to go get. – Thomas Ward Jun 2 '13 at 19:38
I understood, I've replaced and run this command via terminal and it returned nothing. – Dima Knivets Jun 2 '13 at 19:39
up vote 2 down vote accepted

We discussed this in a chat room here, however this is the brief summary:

  1. Make sure you have a domain name.
  2. Make sure that the domain points to your provider's name servers.
  3. Make sure that an A record exists (for IPv4) in the provider's name servers which points your domain to the correct IP for your VPS. If it's an IPv6 address, use an AAAA record.
  4. Make sure that nginx has a server_name line in the configuration for the server { block which has the domain name in it.

And you're done.

To add additional sites in nginx, make additional server { blocks in the configuration file with the relevant configuration data, after making sure the domain points to the IP address for your server, and that the server_name lines contain the domain name(s) in that line for each relevant site root directory on the server.

share|improve this answer
+1 for good explanation – Shrayas Nov 12 '13 at 17:09

Your Answer


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

Not the answer you're looking for? Browse other questions tagged or ask your own question.