Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

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 have ubuntu server set up on a computer at my house, and I want to be able to access it from another computer in the house (through SSH) without typing in its IP address. I'd really rather type in the computer's name (homeserver) or create a static domain name to access it from (i.e., or something similar) from either the router or my home server?

share|improve this question
up vote 1 down vote accepted

What you are looking for is DNS. Most routers don't run DNS and you probably don't have a DNS server in your house. The next closest thing that you can do is add an entry to the HOSTS file on the computer that you will be SSHing from.

If you really want, you can set a static IP on the Ubuntu box and install BIND on it and point all of the other computers in your network to use it for DNS resolution.

share|improve this answer
Ah, I was afraid of this. Mostly because I don't want to either walk my fiancee through how to do it or do it myself for her computer. ;) But if that is what it takes, then that is what it takes. Thanks! – ashays Feb 11 '11 at 2:02
Well, if you set up DNS, and her computer is configured via DHCP, you can just set your router to use that as the DNS server. Next time she renews her address lease, she'll be using the server for DNS. She'll never know it happened :) – MDMarra Feb 11 '11 at 2:05
DNSMasq is a nice package to do this. Disable DHCP in DNSmasq or your router. It can read your /etc/hosts file and pass out addresses for hosts listed there. You will want to configure your server with a static address outside your router's DHCP range. – BillThor Feb 11 '11 at 2:09
I will set up DNS at some point in the near future, I guess. For now, I edited the hosts file in windows, and got it to work with and homeserver, so that should be good enough for now. Thanks for the help! – ashays Feb 11 '11 at 2:09
@ashays - No problem. If a question solved a problem for you, the proper thing to do is click the check mark under the voting button to accept it. That way other users that have the same problem can easily see what solved it. – MDMarra Feb 11 '11 at 2:25

The surefire easiest way will be to map the server's IP to the name of your choosing in the etc/host file on your computer. Follow the format of the existing entry, substituting the server's IP for, and the name you want to use for the server in place of 'localhost'.

share|improve this answer

If you have a DD-WRT supported router you can enable the 'Local DNS' option. This will serve DNS records for you local network and is updated by DHCP.

share|improve this answer

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.