-1

I've set up an Ubuntu Server with LAMP. Now I wish I could access it from the other computers in the network just by typing http://hostname/ in the browser.

Is it possible without setting up a DNS server? Or should this server be also a DNS and resolve its own name?

What's the best way to solve it?

  • Welcome to Server Fault! Questions on Server Fault must demonstrate a minimum understanding of the technology in question. Otherwise, the post often turns into a discussion forum, instead of straight Q&A. The best advice we can give you is to hire a consultant to help you out or do further research on the basics of this technology. – TheCleaner Apr 08 '14 at 13:17
  • @TheCleaner But I showed a minimum of understanding. I even proposed a possible solving when I asked if the server should be also a DNS and resolve its own name to the other computers in the network. I just wanted to know what's the best way or the most used way of getting around this. – Marcos Cassiano Apr 08 '14 at 20:35

1 Answers1

3

You can map the hostname to the IP via the hosts file. On Windows clients accessing your LAMP server, edit the file located at %systemroot%\system32\drivers\etc\ and add an entry to point hostname - to the IP of your LAMP server.

For example:

192.168.1.56       lampserver

If you have a local DNS server it would be better to add it to that and use that server for DNS queries. Outside of the network is a different story all together :)

user3227965
  • 98
  • 1
  • 7
  • Thanks @user3227965! For now, I'll configure the PC's to resolve it via the hosts file. But having a local DNS Server would be better. – Marcos Cassiano Apr 08 '14 at 20:40