Help!

Configuring both ipv4 and ipv6 with ifupdown

 
  

Post new topic   General Reply to Topic (not reply to a specific post)    Forums Home -> IPv6 RSS
Next:  L'Italia non pi#&249; dettare una moda il mon..  
Author Message
Frederic Lehobey
External


Since: Nov 15, 2004
Posts: 30



PostPosted: Thu Jan 11, 2007 5:20 pm    Post subject: Configuring both ipv4 and ipv6 with ifupdown
Archived from groups: linux>debian>maint>ipv6 (more info?)

Hi,

In sarge, the following /etc/network/interfaces configuration used to
work:

----
auto eth0
iface eth0 inet static
address 192.168.0.1
netmask 255.255.255.0

iface eth0 inet6 static
address 2002:some:addr::1
netmask 64
----

while in etch if fails with:

# invoke-rc.d networking restart
Reconfiguring network interfaces...SIOCADDRT: File exists
Failed to bring up eth0.
done.

I am ready to file a bug report against ifupdown with severity serious
as it is a regression with respect to working configurations in sarge,
though I ask here before in case I miss something.

I have read bugs #360155, #395826 and #168776 though none of them
seems to be the same as this one.

Thanks for your help,
Frédéric Lehobey


--
To UNSUBSCRIBE, email to debian-ipv6-REQUEST.DeleteThis@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster.DeleteThis@lists.debian.org
Back to top
Frederic Lehobey
External


Since: Nov 15, 2004
Posts: 30



PostPosted: Thu Jan 11, 2007 6:20 pm    Post subject: Re: Configuring both ipv4 and ipv6 with ifupdown [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Hi,

On Thu, Jan 11, 2007 at 04:34:19PM +0000, Jeroen Massar wrote:
> Frederic Lehobey wrote:

> > In sarge, the following /etc/network/interfaces configuration used to
> > work:
> >
> > ----
> > auto eth0
> > iface eth0 inet static
> > address 192.168.0.1
> > netmask 255.255.255.0
> >
> > iface eth0 inet6 static
> > address 2002:some:addr::1
> > netmask 64
>
> I have a couple of hosts where that works perfectly well with separate
> 'iface eth0 inet...' and 'iface eth0 inet6...' lines.

OK (I understand them to be running etch). Thanks.

By the way the configuration that does not work (in etch) has more
IPv4 fields set up than the working configuration in sarge, namely:

broadcast 213.251.134.255
network 213.251.134.0
gateway 213.251.134.254

I am considering this given the kind of problems that come around from
googling for the 'SIOCADDRT: File exists' error I try to understand.

> Also note that RFC1918 and 6to4 (2002::/16) don't mix, as they

(actually the etch host has a real 2001:... address and direct IPv6
connectivity, it is not using 6to4).

> technically can't work, unless you route 6to4 globally of course or are
> using the IPv4 address of another (public) host in the 6to4 address...

Yes. The documentation of the working (and different) sarge setup is
there: http://proxience.net/dokuwiki/doku.php?id=doc:ipv6 (and, by the
way, credits you as a source for inspiration: thanks twice). Smile

> > # invoke-rc.d networking restart
> > Reconfiguring network interfaces...SIOCADDRT: File exists
> > Failed to bring up eth0.
> > done.
>
> Mine work, but I usually use 'ifdown eth0' and 'ifup eth0', never
> invoke-rc.d, can you try it with 'ifdown eth0' and then 'ifup eth0' ?

Actually it is a remote server and very boring to get back on track if
I loose my ssh access. Sad So I am extremely careful in my
experiments. Actually, 'invoke-rc.d networking restart' is a mild
substitute for a reboot (but the problem shows up too at reboot with
the IPv6 address not being enabled).

> Also interesting to do is activating debugging.
>
> As the above in effect only calls:
>
> ifdown -a --exclude=lo || true
> if ifup -a --exclude=lo; then
> log_action_end_msg $?
> else
> log_action_end_msg $?
> fi
>
> try a 'ifdown -a --verbose --exclude=lo' and then a
> 'ifup -a --verbose -exclude=lo' to see what the results are.

Thanks for the hint, I am still investigating.

I have actually workarounds with
up ifconfig eth0 inet6 add 2001:...
or
up ip -6 ...
but I would prefer (with respect to bug reporting) understand the real
cause of the problem.

Thanks,
Frédéric


--
To UNSUBSCRIBE, email to debian-ipv6-REQUEST.DeleteThis@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster.DeleteThis@lists.debian.org
Back to top
Frederic Lehobey
External


Since: Nov 15, 2004
Posts: 30



PostPosted: Fri Jan 12, 2007 1:00 am    Post subject: [Solved/is it a RC bug?] Re: Configuring both ipv4 and ipv6 with ifupdown [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Hi,

On Thu, Jan 11, 2007 at 06:10:22PM +0100, Frederic Lehobey wrote:
> On Thu, Jan 11, 2007 at 04:34:19PM +0000, Jeroen Massar wrote:
> > Frederic Lehobey wrote:
>
> > > In sarge, the following /etc/network/interfaces configuration used to
> > > work:

(update: with a
pre-up modprobe ipv6
stated earlier in other interfaces' definitions)

> > > ----
> > > auto eth0
> > > iface eth0 inet static
> > > address 192.168.0.1
> > > netmask 255.255.255.0
> > >
> > > iface eth0 inet6 static
> > > address 2002:some:addr::1
> > > netmask 64
> >
> > I have a couple of hosts where that works perfectly well with separate
> > 'iface eth0 inet...' and 'iface eth0 inet6...' lines.
>
> OK (I understand them to be running etch). Thanks.

> substitute for a reboot (but the problem shows up too at reboot with
> the IPv6 address not being enabled).

Yes, but the real cause of the problem is (with a standard etch
installation and kernel) that at the time the ipv6 interface is
brought up, the ipv6 module is not yet loaded in the kernel (it seems
to be loaded *later* in the boot sequence).

The error message I see after (with invoke-rc.d networking restart)
seems to be only a consequence of the original failure.

> I have actually workarounds with
> up ifconfig eth0 inet6 add 2001:...
> or
> up ip -6 ...
> but I would prefer (with respect to bug reporting) understand the real
> cause of the problem.

These two ideas are NOT working workarounds. The real workaround I
have found so far has been to put a

pre-up modprobe ipv6

in interface eth0 definition. There might be other possible
workarounds.

I am still puzzled with what I should do with respect to this
problem. Is it a bug for the kernel? For ifupdown? Or for 'general'?
(If I do not mistake, ipv6 is a release goal.) (And the problem is not
new as it was the same in sarge actually.)

Thanks,
Frédéric


--
To UNSUBSCRIBE, email to debian-ipv6-REQUEST DeleteThis @lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster DeleteThis @lists.debian.org
Back to top
Pascal Hambourg
External


Since: Jan 10, 2006
Posts: 48



PostPosted: Fri Jan 12, 2007 12:20 pm    Post subject: Re: [Solved/is it a RC bug?] Re: Configuring both ipv4 and ipv6 with ifupdown [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Hello,

Frederic Lehobey a écrit :
> These two ideas are NOT working workarounds. The real workaround I
> have found so far has been to put a
>
> pre-up modprobe ipv6
>
> in interface eth0 definition. There might be other possible
> workarounds.

I hope there are. IMO, doing anything such as loading kernel modules
that is not not interface-specific in /etc/network/interfaces is
definitely not a good solution. Ipv6 is system-wide, not eth0-specific.
Besides, if I had no other choice I would load ipv6 with the lo
interface, which is supposed to be set up first and always enabled,
rather than with another interface.

As Paul suggested, putting ipv6 in /etc/modules would be a better
solution, assuming that this file is parsed soon enough during Etch boot
process. This is what I did in Potato, Woody and currently in Sarge and
it has always worked perfectly for me. I must say that I do not use
hotplug or udev which could mess up everything.


--
To UNSUBSCRIBE, email to debian-ipv6-REQUEST.DeleteThis@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster.DeleteThis@lists.debian.org
Back to top
Frederic Lehobey
External


Since: Nov 15, 2004
Posts: 30



PostPosted: Wed Jan 17, 2007 9:40 am    Post subject: Re: [Solved/is it a RC bug?] Re: Configuring both ipv4 and ipv6 with ifupdown [Login to view extended thread Info.]
Archived from groups: per prev. post (more info?)

Hi,

On Mon, Jan 15, 2007 at 10:53:23PM -0500, Joey Hess wrote:
> Paul TBBle Hampson wrote:
> > On Sat, Jan 13, 2007 at 08:47:31PM -0500, Joey Hess wrote:
> > > Paul TBBle Hampson wrote:
> > >> The best place for it is prolly /etc/modules, created by
> > >> debian-installer during the insatll. Rootskel contains the file, and
> > >> hw-detect populates it. (Or so it seems)
> > >>
> > >> So I'd put it as a bug against rootskel, so it can be default
> > >> installed like 'loop' appears to be...
> >
> > > That doesn't seem very appropriate as it would only address the issue on
> > > newly installed systems, leaving upgraded systems unfixed.
> >
> > I'm not sure you can really do much for newly-installed systems...
> >
> > I think the ipv6 addresses in /etc/hosts similarly could only be
> > automatically added on new installs.
> >
> > I could be wrong about that though.
>
> Yes, which suggests that adding ipv6 to /etc/hosts is not the best

You meant /etc/modules, weren't you?

> solution to this problem. An alternative, for example, would be to have
> ifup make sure it was loaded before upping an inet6 address.

So you think the bug report should be against ifupdown? From reading
this thread I am hesitating about what to do finally (a bug against
'general', 'ifupdown' or whatever).

Thanks,
Frédéric


--
To UNSUBSCRIBE, email to debian-ipv6-REQUEST.DeleteThis@lists.debian.org
with a subject of "unsubscribe". Trouble? Contact listmaster.DeleteThis@lists.debian.org
Back to top
Display posts from previous:   
Post new topic   General Reply to Topic (not reply to a specific post)    Forums Home -> IPv6 All times are: Eastern Time (US & Canada) (change)
Page 1 of 1

 
You can post new topics in this forum
You can reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum