netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Hemminger <shemminger@vyatta.com>
To: David Lamparter <equinox@diac24.net>
Cc: netdev@vger.kernel.org
Subject: Re: BUG: net-next netns teardown bridge bug "waiting for lo to become free."
Date: Tue, 27 Jul 2010 10:02:49 -0700	[thread overview]
Message-ID: <20100727100249.51ffc893@nehalam> (raw)
In-Reply-To: <20100727152514.GA13413@jupiter.n2.diac24.net>

On Tue, 27 Jul 2010 17:25:14 +0200
David Lamparter <equinox@diac24.net> wrote:

> (no idea who to Cc on this...)
> 
> Hi,
> 
> 
> i've recently been playing with network namespaces under net-next
> feb8f478... and have been able to reproducibly cause:
> 
> netconsole: network logging stopped, interface lo unregistered
> netconsole: network logging stopped, interface lo unregistered
> unregister_netdevice: waiting for lo to become free. Usage count = 4
> netconsole: network logging stopped, interface lo unregistered
> (repeat.)
> 
> i can trigger this with
> 
> unshare -n -- /bin/bash -c 'ip link add link lo veth0 type veth peer
> name veth3 netns 1; brctl addbr br0; ip l s br0 up; ip a l; sleep 8'
> 
> (It happens when the netns is going down.)
> 
> Without the "ip l s br0 up" it does not happen; the veth I have added
> for "notification" when the namespace goes down, it is probably not
> related.
> 
> I'm looking into this, but i'm not versed in Linux kernel code, so my
> luck in fixing this might be limited. Some reference taken in bridge
> "up"? Should the bridge be set "down" on netns teardown?

Loopback device is special and is referenced by routes etc.
You need to manually remove bridge, and all routes, neighbors and cache
before removing namespace.



-- 

  reply	other threads:[~2010-07-27 17:02 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-07-27 15:25 BUG: net-next netns teardown bridge bug "waiting for lo to become free." David Lamparter
2010-07-27 17:02 ` Stephen Hemminger [this message]
2010-07-28  7:44   ` David Lamparter
2010-07-28  9:58     ` [BUG] bridge leaks 3 references on lo per up&down David Lamparter
2010-07-28 12:03       ` David Lamparter
2010-07-29 11:12         ` Herbert Xu
2010-07-31  6:37           ` David Miller

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20100727100249.51ffc893@nehalam \
    --to=shemminger@vyatta.com \
    --cc=equinox@diac24.net \
    --cc=netdev@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).