[CRIU] [PATCH v1 00/12] criu gc command implementation

Eugene Batalov eabatalov89 at gmail.com
Wed Jul 27 22:14:36 PDT 2016


Hello.

The aim of this patch set is to implement new criu gc command.
criu gc removes objects left in the system after dump was performed.
Its main use case is to cleanup on node where dump was
performed but restore isn't planned.

CRIU gc accepts dump dir path as an input and removes:
1. Link remaps created for ps tree
2. Netfilter rules that drop ps tree tcp packets
Currently this is all that CRIU dump leaves in the system.

--show option changes gc command behavior. It only
shows what was left in the system without objects removal.

== V1 changes ==
- Fix python lint errors in zdtm.py

Eugene Batalov (11):
  mount: save fs root fd of ps tree root mnt ns in its ns_id
  gc: implement link remaps deletion
  gc: implement link remaps show
  gc: implement unlocking of tcp connections
  gc: implement locked tcp connections show
  zdtm: implement capturing of criu action stdout and stderr
  zdtm: implement capturing of test hooks stdout and stderr
  zdtm: extract cr and state checking logic into function
  zdtm: implement criu gc tests
  jenkins: add script to run all gc aware tests
  zdtm: add host flavor to unlink_regular00 test

Maxim Kuzmin (1):
  gc: mock implementation of new gc command

 criu/Makefile.crtools                  |   1 +
 criu/cr-gc.c                           | 149 +++++++++++++++++++++++++++++++++
 criu/crtools.c                         |  12 +++
 criu/files-reg.c                       |  75 +++++++++++++++--
 criu/include/cr_options.h              |   1 +
 criu/include/crtools.h                 |   1 +
 criu/include/files-reg.h               |   2 +
 criu/include/net.h                     |   1 +
 criu/include/sk-inet.h                 |   3 +-
 criu/mount.c                           |   7 +-
 criu/net.c                             |  12 +++
 criu/sk-tcp.c                          |  47 ++++++++++-
 test/jenkins/criu-gc.sh                |  10 +++
 test/zdtm.py                           | 140 +++++++++++++++++++++++++------
 test/zdtm/static/mntns_link_remap.hook |  10 +++
 test/zdtm/static/socket-tcp.hook       |   9 ++
 test/zdtm/static/socket-tcp6.hook      |   9 ++
 test/zdtm/static/unlink_regular00.desc |   2 +-
 test/zdtm/static/unlink_regular00.hook |   9 ++
 19 files changed, 462 insertions(+), 38 deletions(-)
 create mode 100644 criu/cr-gc.c
 create mode 100755 test/jenkins/criu-gc.sh
 create mode 100755 test/zdtm/static/mntns_link_remap.hook
 create mode 100755 test/zdtm/static/socket-tcp.hook
 create mode 100755 test/zdtm/static/socket-tcp6.hook
 create mode 100755 test/zdtm/static/unlink_regular00.hook

-- 
1.9.1



More information about the CRIU mailing list