[CentOS] How to make nodes in my local LAN see each other's names

Lamar Owen lowen at pari.edu
Tue Nov 29 16:52:12 UTC 2011


On Tuesday, November 29, 2011 11:14:16 AM Timothy Madden wrote:
> The router has the 'DNS relay' option enabled, and all 7 computers use 
> the router as the DNS server, which in turn will forward DNS requests to 
> the ISP DNS server. That way I can understand that simple, plain, 
> default DNS is not enough for my boxes to see each-other's names.

Can this router have DNS entries added for local hosts?  Some SOHO type routers can do this, but I'm not that familiar with your particular router.

> somehow I think installing cifs on every node just to get my local 
> machine names to resolve properly to the IP addresses is not the right 
> way to solve my problem ...

Indeed.

> What is the way to have all computers in my simple network know each 
> other by name ?

There is no one correct way.  But here are a few possibilities for you:
1.) DNS entries in the D-Link router;
2.) static hostnames in /etc/hosts (you'll need to set the router up to always hand out the same IP address for each machine; most SOHO routers can do this, but it may not be obvious how to make it work)
3.) Run a separate DHCP and DNS server on the LAN and not use the router (for a larger installation this would be the preferred way to do things, but for a small number it's not ideal).

> Is it possible to have the name resolving procedure used by the system 
> automatically recognize a new machine added to my network, when I try to 
> access it with right host name, like WINS can ?

Dynamic DNS; your router may be able to do this for you.

> Is there an easy way to install a caching name server on my each 
> machine, and make sure my system is using /that server/ to resolve names ?

Yes.  More than one option exists for this; for CentOS 5 at least you can just 'yum install caching-nameserver' and 'chkconfig named on' (and then 'service named start') and it should come up; I haven't used that setup in some time, though, so not sure how nice that plays with DHCP.  There are other options, but that is the main one that is in the CentOS distribution's main repo.

Hope that helps.



More information about the CentOS mailing list