[CRIU] [PATCH RFC 00/12] Restore nested mount namespaces
Andrey Vagin
avagin at openvz.org
Fri Jan 10 05:49:54 PST 2014
Systemd is able to execute a service in a new mount namespace.
It's used by Fedora and probably will be used in RHEL7.
All nested mount namespaces are restored as sub-trees of the root
namespace. A namespace is restored by a task with minimal pid in this
namespace. The task unshares mount namespace and makes pivot_root in a
proper sub-tree. All other task from the namespace attaches to the
namespace by calling setns().
Andrey Vagin (12):
initialize root before dumping mount namespace
namespace: move struct ns_id into namespace.h
mounts: allow to customize root path for cr_pivot_root
restore: add mount id-s in the ns_ids list
mounts: mark local root-s in the list of mount points
mounts: connect sub-root to the main root
mounts: handle propogation for the global root
mounts: bind mount one root for all namespaces
namespace: add a function to search an ns_id item by id
mounts: create a temporary directory for restoring non-root mntns
crtools: restore nested mount namespaces
mount: allow to dump and restore nested mount namespaces
cr-restore.c | 34 +++++--
include/mount.h | 4 +
include/namespaces.h | 12 +++
include/proc_parse.h | 1 +
mount.c | 280 ++++++++++++++++++++++++++++++++++++++++++++-------
namespaces.c | 52 ++++++++--
pstree.c | 7 +-
7 files changed, 335 insertions(+), 55 deletions(-)
--
1.8.3.1
More information about the CRIU
mailing list