linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* clone() with CLONE_NEWNET breaks kobject_uevent_env()
@ 2011-08-18  9:45 Milan Broz
  2011-08-19  7:52 ` Milan Broz
  2011-08-19  9:13 ` [dm-devel] " Eric W. Biederman
  0 siblings, 2 replies; 13+ messages in thread
From: Milan Broz @ 2011-08-18  9:45 UTC (permalink / raw)
  To: Linux Kernel Mailing List
  Cc: device-mapper development, Kay Sievers, David S. Miller

Hi,

after analysing very strange report (with running chromium
some device-mapper ioctl functions started to fail) I found
interesting problem:

If you run clone() with CLONE_NEWNET (which is chromium using
for sanboxing), udev namespace is cloned too (newly registered
in uevent_sock_list) and netlink send (except the first in list)
fails with -ESRCH.

This causes that _every_ call of kobject_uevent_env() return failure.

Most of users silently ignores  kobject_uevent() return value,
so the problem was invisible for long time.

Unfortunately dm checks return value and reports failure,
taking the wrong error path.

How is this supposed to work?

Why cloning net namespace breaks the udev netlink subsystem?

Is it bug or we need to do something differently?
(I do not think ignoring return value is the proper way...)

Thanks,
Milan

^ permalink raw reply	[flat|nested] 13+ messages in thread

end of thread, other threads:[~2011-08-22 20:05 UTC | newest]

Thread overview: 13+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-08-18  9:45 clone() with CLONE_NEWNET breaks kobject_uevent_env() Milan Broz
2011-08-19  7:52 ` Milan Broz
2011-08-19  9:13 ` [dm-devel] " Eric W. Biederman
2011-08-19 10:22   ` Milan Broz
2011-08-19 11:43     ` Eric W. Biederman
2011-08-19 11:59       ` Milan Broz
2011-08-19 18:39         ` Eric W. Biederman
2011-08-19 20:41           ` Milan Broz
2011-08-22 13:51             ` [PATCH] kobj_uevent: Ignore if some listeners cannot handle message Milan Broz
2011-08-22 16:24               ` Kay Sievers
2011-08-22 19:49               ` Eric W. Biederman
2011-08-22 20:05                 ` Milan Broz
2011-08-19 10:26   ` [dm-devel] clone() with CLONE_NEWNET breaks kobject_uevent_env() Kay Sievers

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).