Re: Local Lan DNS Problems
From: prg (rdgentry1_at_cablelynx.com)
Date: 01/14/05
- Next message: Dr Balwinder Singh Dheeman: "Re: Install on small HDD"
- Previous message: xm_at_ca.inter.net: "Re: Forcing SSH on port 80 with iptables"
- In reply to: Murphy: "Re: Local Lan DNS Problems"
- Next in thread: Murphy: "Re: Local Lan DNS Problems"
- Reply: Murphy: "Re: Local Lan DNS Problems"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Date: 13 Jan 2005 18:50:02 -0800
Murphy wrote:
> prg wrote:
>
> > [snip]
> >
> > You mean you added _all_ your hosts to IPCop's /etc/hosts? Or just
the
> > two following?
>
> I've only added the two entries below to the ipcop hosts file as I
> understand, correct me if wrong, that as theothers use DHCP then they
> should be able to be located with dns queries.
>
> >
> >> I now have entries in the IPCop hosts file for
> >> 127.0.0.1 Localhost
> >> 192.168.1.1 ipcop.local ipcop
> >> 192.168.1.2 angus.local angus
> >>
[snip]
> It now appears that everyone can ping everyone with the exception
that the
> dual boot Linux workstation when running as Linux can only be pinged
by
> ipaddress not name only when running as Linux.
>
> In the IPCop DHCP leases section this Linux workstation is the only
entry
> that does not have a name in the hostname column.
As a general rule, don't summarize or comment on command output or
config files -- just post them verbatim via copy-n-paste. What means
nothing to you may be just the clue someone else needs. For now I
don't need it and probably won't ask for it.
> > When you reboot into Windows you will be asking to renew _Windows_
> > lease -- it is ignorant of the lease file used in Linux. And vice
> > versa.
> >
> > The problem with this is that depending on how the dhcp server is
> > tracking host requests (using client-identifier which is commonly a
MAC
> > address?) the Windows request can look like a different machine to
dhcp
> > as it can pre-pend an 0x01 to the MAC that Linux uses.
>
> Whn it's booted as Windows it can be pinged by name and the hostname
appears
> in the IPCop DHCP lease list, when it's booted as Linux it has the
same
> IPAdd however cannot be pinged by name and has no hostname listed in
the
> IPCop DHCP lease list.
This symptom is what I told you earlier. Here's an explanation from
the dnsmasq FAQ that is similar to acquiring a lease with Win then
rebooting into Linux:
[quote]
Q: I'm network booting my machines, and trying to give them static
DHCP-assigned addresses. The machine gets its correct address
whilst booting, but then the OS starts and it seems to get
allocated a different address.
A: What is happening is this: The boot process sends a DHCP
request and gets allocated the static address corresponding to its
MAC address. The boot loader does not send a client-id. Then the OS
starts and repeats the DHCP process, but it it does send a
client-id. Dnsmasq cannot assume that the two requests are from the
same machine (since the client ID's don't match) and even though
the MAC address has a static allocation, that address is still in
use by the first incarnation of the machine (the one from the boot,
without a client ID.) dnsmasq therefore has to give the machine a
dynamic address from its pool. There are three ways to solve this:
(1) persuade your DHCP client not to send a client ID, or (2) set up
the static assignment to the client ID, not the MAC address. The
default client-id will be 01:<MAC address>, so change the dhcp-host
line from "dhcp-host=11:22:33:44:55:66,1.2.3.4" to
"dhcp-host=id:01:11:22:33:44:55:66,1.2.3.4" or (3) tell dnsmasq to
ignore client IDs for a particular MAC address, like this:
dhcp-host=11:22:33:44:55:66,id:*
[end quote]
Here are two other items from FAQ you may need:
[quote]
Q: Names on the internet are working fine, but looking up local names
from /etc/hosts or DHCP doesn't seem to work.
A: Resolver code sometime does strange things when given names without
any dots in. Win2k and WinXP may not use the DNS at all and just
try and look up the name using WINS. On unix look at "options
ndots:"
in "man resolv.conf" for details on this topic. Testing lookups
using "nslookup" or "dig" will work, but then attempting to run
"ping" will get a lookup failure, appending a dot to the end of the
hostname will fix things. (ie "ping myhost" fails, but "ping
myhost." works. The solution is to make sure that all your hosts
have a domain set ("domain" in resolv.conf, the network applet in
windows, or set a domain in your DHCP server). Any domain will do,
but "localnet" is traditional. Now when you resolve "myhost" the
resolver will attempt to look up "myhost.localnet" so you need to
have dnsmasq reply to that name. The way to do that is to include
the domain in each name on /etc/hosts and/or to use the
--expand-hosts and --domain-suffix options.
Q: I'm running Debian, and my machines get an address fine with DHCP,
but their names are not appearing in the DNS.
A: By default, none of the DHCP clients send the host-name when asking
for a lease. For most of the clients, you can set the host-name to
send with the "hostname" keyword in /etc/network/interfaces. (See
"man interfaces" for details.) That doesn't work for dhclient, were
you have to add something like "send host-name daisy" to
/etc/dhclient.conf [Update: the lastest dhcpcd packages _do_ send
the hostname by default.
[end quote]
Note that in RH the relaevant file _may_ be
/etc/sysconfig/networking/profiles/default/network
On this machine it contains _only_ this:
HOSTNAME=pbrain
I'm in a bind helping you as I've never installed IPCop and can't now
as it requires a dedicated hard disk -- sorry, but... ;)
You are not quite far enough along to decipher some of the explanations
in the docs or that I give, but you getting there. Read the dnsmasq
docs in the source download -- it's only 131.3 KB. Even IPCop
indicates that they are the authoritative documentation for dnsmasq in
IPCop. You will very likely have to extrapolate the examples in the
docs -- the source of your problem is your client setup, I convinced.
RH is the only one I would even venture a guess on.
Get used to reading man pages -- some of them _are_ useful ;)
Don't make a bunch of config changes at once in hopes that one will
work. Make a single change, test, if no change go on to the next most
likely winner based on the symptoms and docs. Be patient.
BTW, be sure to try the "ping host." with-a-dot test. That one is a no
change test that clearly points to a symptom/solution. But, it may not
be the _only_ needed change :-(
hth,
prg
email above disabled
- Next message: Dr Balwinder Singh Dheeman: "Re: Install on small HDD"
- Previous message: xm_at_ca.inter.net: "Re: Forcing SSH on port 80 with iptables"
- In reply to: Murphy: "Re: Local Lan DNS Problems"
- Next in thread: Murphy: "Re: Local Lan DNS Problems"
- Reply: Murphy: "Re: Local Lan DNS Problems"
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Relevant Pages
|