From mboxrd@z Thu Jan 1 00:00:00 1970 From: "Daniel P. Berrange" Subject: Virtualizing /proc/sys/kernel/random/boot_id per container ? Date: Thu, 30 Aug 2012 14:18:32 -0700 Message-ID: <20120830211832.GA3297@redhat.com> Reply-To: "Daniel P. Berrange" Mime-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Return-path: Content-Disposition: inline List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: containers-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Errors-To: containers-bounces-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org To: containers-cunTk1MwBs9QetFLy7KEm3xJsTq8ys+cHZ5vskTnxNA@public.gmane.org Cc: "Eric W. Biederman" List-Id: containers.vger.kernel.org One of the features that SystemD folks have asked us to fix in LXC, is to make sure that /proc/sys/kernel/random/boot_id changes each time a container is started. The current semantics are that this file produces a new random UUID each time the host OS is booted. Obviously each time we start a container now, they just see the host's random boot_id, so from a container's POV this does not change each time it starts. There seems to be general agreement that, aside from the PID directories, changes to data in proc should be done by a FUSE filesystem overlay of some kind. We could use that mechanism to fix 'boot_id' in userspace, but I'm wondering if this is a better candidate for dealing with in kernel space, since as well as the /proc/sys tree, the data is also visible via the sysctl() system call which a FUSE overlay won't address. The kernel doesn't have a real concept of a 'container' to associate a boot_id value with as such, but maybe it is reasonable to associate a boot_id value with each PID namespace ? Regards, Daniel -- |: http://berrange.com -o- http://www.flickr.com/photos/dberrange/ :| |: http://libvirt.org -o- http://virt-manager.org :| |: http://autobuild.org -o- http://search.cpan.org/~danberr/ :| |: http://entangle-photo.org -o- http://live.gnome.org/gtk-vnc :|