[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: hosts file entry for 127.0.1.1



Joe wrote:
> Bob Proulx wrote:
> > Joe wrote:
> > > It doesn't work with Windows 8, which refuses to accept 127.0.1.1 as
> > > a valid DHCP server IP address, and to be honest I can't say I blame
> > > it.
> > 
> > Excuse me?  Why is your DHCP server using 127.0.1.1?  How is that even
> > working at all?  That is completely wrong.  Something is wrong with
> > your dhcp server configuration.
>
> Such as? What in terms of DHCP configuration determines what source IP
> address is used by dhcpd? DHCP is a bit special, operating on MAC
> addresses rather than IP addresses, so I suppose many clients don't
> care what IP address turns up. Windows 8 seems uncouth enough to expect
> a real IP address, or at least the same address as was used earlier.

Can you share your dhcpd.conf file?  Private mail for that would be
fine if you don't want to dump the entire thing to the list.  Here is
a complete copy of a simple dhcpd that serves my wifi network.

  # The ddns-updates-style parameter controls whether or not the server will
  # attempt to do a DNS update when a lease is confirmed. We default to the
  # behavior of the version 2 packages ('none', since DHCP v2 didn't
  # have support for DDNS.)
  ddns-update-style none;

  # option definitions common to all supported networks...
  option domain-name "proulx.com";
  option domain-name-servers 192.168.230.109, 192.168.230.119;

  default-lease-time 600;
  max-lease-time 7200;

  # If this DHCP server is the official DHCP server for the local
  # network, the authoritative directive should be uncommented.
  authoritative;

  subnet 192.168.93.0 netmask 255.255.255.0 {
    option routers 192.168.93.1;
    range 192.168.93.100 192.168.93.254;
  }

What does your file look like?

> > I am using KVM on my machines.  I am using 127.0.1.1 on my machines.
> > I use the ISC DHCP server as well as the dnsmasq server and I am not
> > seeing the problem you describe anywhere.  What VM software are you
> > using?
>
> None. All bare metal stuff.

Sorry.  I confused you with the original poster who was using VMs and
dnsmasq for the dhcp server for them.  Understand now that this is a
different case and you are using bare metal.  That should make things
easier.  Sorry for the mix up.

> > > This is with Bind9 and the ISC DHCP server. And yes, 127.0.1.1 was
> > > being used as a source IP address during the DHCP negotiation, after
> > > the real server IP address had been used once.
> > 
> > Something is wrong with your dhcp server configuration.  Please say
> > more about it.  How is your networking set up?  Are you using a
> > network bridge?
> 
> No. It's a two-NIC server running DHCP for the internal network,
> linked with Bind9, fixed IPs on the NICs.

The use with BIND9 should be unrelated.  Works great.  But bind is
unrelated to dhcp.

Please install dhcpdump and then capture a trace of a dhcp exchange.
It is very useful for debugging dhcp issues.

  dhcpdump -i eth1

> Supposedly. It works fine with XP, Win7, various Debians and
> Macbooks and a Humax TV recorder. And a Raspberry Pi running Wheezy
> Raspbian. No dice with Windows 8, which of course I put down to W8
> being broken. But that machine picked up addresses perfectly well in
> other networks... What does a Windows DHCP server have that ISC
> dhcpd doesn't? Or a cheap DSL router, for that matter.

One follows the standards and the other is windows? ;-)

> When I got fed up, and W8 manual networking is a pain (who in God's
> name ever thought APIPA addresses were a good idea? The one way to
> *absolutely* *guarantee* that a computer won't operate in an existing
> network), I put a packet sniffer on it, and lo and behold, there were
> second and subsequent DHCP packets arriving with the offending source
> address, and no further discussion from the W8 end.

ROTFL!

> Remove the hosts entry, the problem goes away, and that's where I stop
> trying to fix it. I cannot imagine why an Ethernet implementation would
> ever allow a source address of the 127. persuasion to be used other
> than on lo, so I'm not about to try to debug it.

Bad route?  What is the output of this?

  ip route show

Bob

Attachment: signature.asc
Description: Digital signature


Reply to: