On Thu, Mar 16, 2017 at 11:45:03AM +0100, Jakub Sitnicki wrote: > On Thu, Mar 16, 2017 at 10:12 AM GMT, Kevin Xu wrote: > > Do you mean the message looping endlessly? > > No, the message is emitted just once. Around 100 seconds after > destroying a few namespaces. Occurs not so often, maybe once per ten > runs. > > -Jakub >
I saw that happening from time to time during my test as well, I suspect it was because some TCP sockets stays in either TCP_TIME_WAIT or TCP_FIN_WAIT1. But eventually those sockets get destroyed and lo gets deleted as well. The patch was fixing an issue I am seeing, that the message gets looped forever, and causing a deadlock on new network ns creation. Kevin > > If so, then I suppose it's a different bug. > > > > Kevin > > > >> On Mar 16, 2017, at 3:01 AM, Jakub Sitnicki <j...@redhat.com> wrote: > >> > >>> On Thu, Mar 16, 2017 at 08:08 AM GMT, Kevin Xu wrote: > >>> In some rare cases, inet_sk_rx_dst_set() may be called multiple times > >>> on the same dst, causing reference count leakage. Eventually, it > >>> prevents net_device to be destroyed. The bug then manifested as > >>> > >>> unregister_netdevice: waiting for lo to become free. Usage count = 1 > >>> > >>> in the kernel log, preventing new network namespace creation. > >>> > >>> The patch works around the issue by checking whether the socket already > >>> has the same dst set. > >>> > >>> Signed-off-by: Kevin Xu <kaiwen...@hulu.com> > >>> --- > >> > >> FWIW, with this patch applied I'm still sometimes seeing: > >> > >> [ 125.928095] unregister_netdevice: waiting for lo to become free. Usage > >> count = 1 > >> > >> -Jakub