2
0
mirror of https://github.com/checkpoint-restore/criu synced 2025-08-31 06:15:24 +00:00

ns: Add c/r for /proc/$pid/ns/$ids references

Based on work done by Cyrill Corcunov (many thanks for that).

In this commit we implement c/r for files which have opened
/proc/$pid/ns/$ids entries.

The idea is rather simple one

Checkpoint
==========

- Check if the file name is the one of known to be ns ref
- If match then write protobuf entry

Restore
=======

- Read all ns entries from the image
- When criu tries to open one we lookup over process
  tree to figure out which PID should be used in path
  and then just open it

Signed-off-by: Pavel Emelyanov <xemul@parallels.com>
This commit is contained in:
Pavel Emelyanov
2013-05-18 04:00:05 +04:00
parent a49325b524
commit ec50a07727
5 changed files with 219 additions and 7 deletions

View File

@@ -124,6 +124,9 @@ static int root_prepare_shared(void)
if (collect_reg_files())
return -1;
if (collect_ns_files())
return -1;
if (collect_pipes())
return -1;