udev.postinst does not work in LXC container

Bug #632740 reported by Tamas Papp on 2010-09-07
16
This bug affects 3 people
Affects Status Importance Assigned to Milestone
udev (Ubuntu)
Undecided
Unassigned

Bug Description

Binary package hint: udev

Vservers are handled, but in an LXC containers mknod also cannot be used.

This is a small fix:

--- udev.postinst.orig 2010-09-07 21:57:32.000000000 +0000
+++ udev.postinst 2010-09-07 22:00:45.000000000 +0000
@@ -78,6 +78,10 @@
        return
     fi

+ if grep -v -q "/$" /proc/1/cgroup;then
+ return
+ fi
+
     rm -f /lib/udev/devices/fd
     ln -sn /proc/self/fd /lib/udev/devices/fd

Feel free to modify it for your taste. Please modify the official version of the script.

Tamas Papp (tompos) wrote :

I correct myself, this suppose to work correctly even if cgroup not mounted:

--- udev.postinst.orig 2010-09-07 21:57:32.000000000 +0000
+++ udev.postinst 2010-09-07 22:46:10.000000000 +0000
@@ -78,6 +78,10 @@
       return
    fi

+ if grep -q ":/[[:alnum:]]" /proc/1/cgroup;then
+ return
+ fi
+
    rm -f /lib/udev/devices/fd
    ln -sn /proc/self/fd /lib/udev/devices/fd

Changed in udev (Ubuntu):
status: New → Confirmed
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers