Tim Wescott wrote:
>>> Does that mean that I need to make my host machine a fixed IP (currently
>>> I'm getting that from the router)?  Or can I just call my router a
>>> "nameserver" in /etc/resolv.conf and have it work?
>>>
>> You can't just call your router a "nameserver" to make it so any more than
>> you can call me a millionaire to make me financially comforted.
>>
> Thank you for the useful information, and for the reminder of the depths
> of my ignorance.  Perhaps you could help out even more by illuminating
> the difference between what my router is doing when it assigns IP
> addresses, and what a nameserver is?

A nameserver (typically Bind's named) provides mappings from human readable
names to IP addresses and IP addresses to names.  The software on your system
never sends data to www.whatever.tld, it sends it to an IP address. The wordy
names exist solely as a memory aid for people.  So when you do something that
requires your computer to connect to another one and you do it by the name the
underlying software looks up the name to figure out what IP address to send
data to.  For more information:
http://en.wikipedia.org/wiki/Nameserver

Your router is performing the role of a DHCP server. DHCP - Dynamic Host
Configuration Protocol.   Typically DHCP is used to provide IP addresses to
systems that are configured to ask for one.  The do not (usually) tell a
nameserver about the assignment.  It just hands out the address to the system
that requested one. For more information:
http://en.wikipedia.org/wiki/Dhcp

>> You may be able to configure the router (what is it anyway?) to always
>> assign
>> thatthere the same IP address.  In which case you could then add it to
>> /etc/hosts, as Rich demontrated, and have things work.
>>
> It's a Linksys (mumble mumble)54G.

That's good. Is it running stock Linksys software?  If you've installed
OpenWRT or other 3rd party OS on it it can be a nameserver too.  See:
http://en.wikipedia.org/wiki/Linksys_WRT54G_series

> If I'm going to play those games I may as well just assign the desktop
> with a fixed address.  We live out in the boonies with enough power
> outages that the network gets a complete power-down and power-up several
> times a month in the winter; that would scramble the IP addresses each
> time

Not necessarily.  The DHCP protocol allows the client to request a particular
IP address.  And it typically asks when half of the lease time has elapsed.
And by default the DHCP server will renew the lease and hand over the same IP
address.  Most (all?) clients keep track of their most recent assigned IP
address and will request the same one.

It is very likely that herethere and thatthere have _never_ changed their IP
addresses.   So putting them in /etc/hosts isn't a bad idea.

The reason I said to make note of it somewhere is because it's likely to be
months or years from now when that breaks and by then you won't remember what
you'd done to get things to work and a note would save you lots of grief.

As an example, where I work DHCP leases are granted for 10 day periods.  Yet
my desktop has had the same IP address for several months now.


> Going back a bit -- there's no way I can just ping by name?

Not the way you have it now.  change  /etc/hosts and you'll be able to do it.


-- 
     Michael Rasmussen
   http://www.jamhome.us/
 Be Appropriate && Follow Your Curiosity

_______________________________________________
PLUG mailing list
[email protected]
http://lists.pdxlinux.org/mailman/listinfo/plug

Reply via email to