On Tue, Aug 16, 2016 at 01:07:15PM -0700, Rick Thomas wrote:

> Thanks Pascal!

Indeed thanks, now I have less explaining to do :)

> >> Aug 14 17:02:41 sheeva systemd[1]: Starting Raise network interfaces...
> >> Aug 14 17:02:46 sheeva ifup[893]: /sbin/ifup: waiting for lock on 
> >> /run/network/ifstate.eth0
> >> Aug 14 17:02:49 sheeva ifup[893]: RTNETLINK answers: File exists
> > 
> > "RTNETLINK answers: File exists" typically happens when you try to add an 
> > address or a route which is already exists with "ip", which is the tool 
> > used internally by ifup.

Correct. And when any error occurs, ifup thinks that it failed to bring
the interface up properly.

> >> # The primary network interface
> >> allow-hotplug eth0
> >> iface eth0 inet static
> >>    address 192.168.3.111
> >>    netmask 255.255.240.000
> >>    network 192.168.0.0
> >>    broadcast 192.168.15.255
> >>    gateway 192.168.1.1
> > 
> > Note that the network and broadcast options are not required. If missing, 
> > they will be calculated from the address and net mask values.
> 
> Thanks.  I’ll keep that in mind for next time.  No harm in leaving them in 
> though, right?

It's fine to leave them. But next time you write an
/etc/network/interfaces file, you can save yourself some typing: you
only need the address and gateway statements:

iface eth0 inet static
        address 192.168.3.111/20
        gateway 192.168.1.1

> >> iface eth0 inet6 static
> >>       address 2001:1234:2d2:1:f2ad:4eff:fe00:3077
> >>       netmask 64
> > 
> > This IPv6 address looks like an autoconfigured address calculated from the 
> > MAC address. You should not statically assign this kind of address.

Good catch!

> Why do you say that I should not statically assign this kind of address?  As 
> long as it’s the same as it would be getting dynamically, is there any harm? 
> (other than the one we’re observing here?)

If you have a DHCP daemon or RADVD running on your network, you
generally want to use what they provide instead of hardcoding your IP
addresses. Just think of the situation where you change your IPv6
provider and you get a new prefix: if you just use autoconfiguration,
you don't have to edit your /etc/network/interface files.

> It seems that it is getting a dynamic address from the RA (Yes, it’s the same 
> address as I am statically assigning.)  Prior to the most recent Sid update, 
> it did not get a dynamic address.  Is that a bug?  If so, is the bug in the 
> previous behavior or the current behavior?  can someone explain what the 
> purpose of the change was?

It could be that the kernel is behaving differently with the update;
maybe it did IPv6 autoconfiguration slower before, so ifupdown could
still add the address.

Unfortunately it is the case that the Linux kernel is doing IPv6 configuration
on its own. With IPv4, everything was done by userspace. The BSDs
require you to start "rtsold" which is basically a client version of
radvd. You can tell the kernel not to accept route advertisements by
adding the option "accept_ra 0" to the inet6 stanza in
/etc/network/interfaces, but unfortunately that does not always work
because the kernel might already have gotten an address by the time
ifupdown is run at boot. Another option is to add the followning line to
/etc/systl.conf:

net.ipv6.conf.all.accept_ra=0

But in your case, I'd follow Pascal's recommendation and just not
configure the IPv6 part statically.

-- 
Met vriendelijke groet / with kind regards,
      Guus Sliepen <g...@debian.org>

Attachment: signature.asc
Description: Digital signature

Reply via email to