[CRIU] [PATCH] namespace: mark mount namespaces as populated after the forking stage
Cyrill Gorcunov
gorcunov at gmail.com
Sun Jun 12 06:15:01 PDT 2016
On Sat, Jun 11, 2016 at 09:01:45PM +0300, Andrey Vagin wrote:
> From: Andrew Vagin <avagin at virtuozzo.com>
>
> Currently we mark a mount namespaces as populated when a target process
> (ns_pid) switches into it. But if a process inherited the right
> namespace from a parent, it doesn't call do_restore_task_mnt_ns()
> and a namespace can remain unmarked.
>
> af55c059fb6 ("mount: fix a race between restoring namespaces and file mappings")
> After this patch we could simplify logic around ns_populated. Currently
> it's a futex, but nodoby waits on it. We can set ns_populated when we
> are going to close namespace descriptors. To avoid additional locks, we
> can do this when all task pass the forking stage and don't start the
> next stage.
>
> https://jira.sw.ru/browse/PSBM-48222
>
> Signed-off-by: Andrew Vagin <avagin at virtuozzo.com>
Tested-by: Cyrill Gorcunov <gorcunov at openvz.org>
More information about the CRIU
mailing list