[CRIU] [PATCH v3 0/5] c/r non-dev net syctls
Pavel Tikhomirov
ptikhomirov at virtuozzo.com
Thu Jul 14 06:51:09 PDT 2016
This is a try to migrate /proc/sys/net static sysctls -
the ones on netns but not per-device. The same way can be applyed
to all other static sysctls, but they need to be put on proper
namespace image.
I added full path to sysctl entry in protobuf as it is easier than
hardcoding these entries in code, and I lookup them just before dump.
Actually the test is not yet full as we need to find the right
limits for a bunch of sysctls, now I use 0-default range for most of
them, so some "high" values will not get in.
/proc/sys/net/netfilter/nf_log/xx sysctls are hard to set - see
patch 2/4 so skiping NONE case. Made fix for kernel it is in nf-next:
http://git.kernel.org/cgit/linux/kernel/git/pablo/nf-next.git/commit/?id=c6ac37d8d8843fb1fdc34e4a2a41a4f027ab670c
Touching igmp_link_local_mcast_reports is unsafe in v4.3-v4.5 kernels
so don't do it.
v2: remove non-writable in netns sysctls from test
v3: fix igmp_link_local_mcast_reports problem, add more sysctls from
kernel v4.6 to test
https://jira.sw.ru/browse/PSBM-48397
Pavel Tikhomirov (5):
sysctl: append '\0' in sysctl_read_char
net/sysctl: add sysctl_igmp_link_local_mcast_reports_safe check
net/sysctl: c/r all except *.conf.* and *.neigh.*
zdtm: add irand_range helper and use it in netns-dev test
zdtm/sysctls: test all net.xxx except conf and neigh
criu/include/kerndat.h | 1 +
criu/include/sysctl.h | 16 ++
criu/kerndat.c | 40 ++++
criu/net.c | 224 ++++++++++++++++++++++
criu/sysctl.c | 125 ++++++++++++-
images/netdev.proto | 14 +-
images/sysctl.proto | 5 +
test/zdtm/lib/Makefile | 2 +-
test/zdtm/lib/randrange.c | 36 ++++
test/zdtm/lib/randrange.h | 13 ++
test/zdtm/static/Makefile | 1 +
test/zdtm/static/netns-dev.c | 46 +----
test/zdtm/static/netns-sysctls.c | 364 ++++++++++++++++++++++++++++++++++++
test/zdtm/static/netns-sysctls.desc | 1 +
14 files changed, 843 insertions(+), 45 deletions(-)
create mode 100644 test/zdtm/lib/randrange.c
create mode 100644 test/zdtm/lib/randrange.h
create mode 100644 test/zdtm/static/netns-sysctls.c
create mode 100644 test/zdtm/static/netns-sysctls.desc
--
2.5.5
More information about the CRIU
mailing list