[CRIU] [PATCH 0/4] fix fails of the ipc_namespace test
Andrey Vagin
avagin at openvz.org
Wed Aug 13 06:51:01 PDT 2014
A few days ago we started to execute tests concurrently and
the ipc_namespace test started to fail with the following error.
------------------------------------------------------------------------------
13:42:54.072: 84: ERR: ipc_namespace.c:356: IPC's differ
(errno = 11 (Resource temporarily unavailable))
13:42:54.073: 84: ERR: ipc_namespace.c:303: msg_ctlmni differs: 524651311 ---> 845
(errno = 11 (Resource temporarily unavailable))
------------------------------------- END -------------------------------------
The reason is partly due to auto_msgmni, which is set in a random value.
If it is enalbed, the value of msgmni is recalculated each time,
when ipns is created or destroyed in a system.
But it isn't all. When I set it to zero, the ipc_namespace test
continued to report the same error. One more bug was found in
the kernel. The new value of auto_msgmni isn't applied, if a buffer
contains extra symbols.
Below you can find two examples. In the new value has not been
handled properly.
$ strace ./a.out
open("/proc/sys/kernel/auto_msgmni", O_WRONLY) = 3
write(3, "0\n\0", 3) = 2
close(3) = 0
exit_group(0)
$ cat /sys/kernel/debug/tracing/trace
$strace ./a.out
open("/proc/sys/kernel/auto_msgmni", O_WRONLY) = 3
write(3, "0\n", 2) = 2
close(3) = 0
$ cat /sys/kernel/debug/tracing/trace
a.out-697 [000] .... 3280.998235: unregister_ipcns_notifier <-proc_ipcauto_dointvec_minmax
https://lkml.org/lkml/2014/8/13/394
Andrey Vagin (4):
zdtm/ipc_namespaces: don't extra symbols in a sysctl file
ipc: set the msgmni sysctl after auto_msgmni
sysctl: don't write '\0' at the end of buffer in a sysctl file
zdtm/ipc_namespace: set the auto_msgmni sysctl to zero
ipc_ns.c | 2 +-
sysctl.c | 5 ++---
test/zdtm/live/static/ipc_namespace.c | 4 ++--
3 files changed, 5 insertions(+), 6 deletions(-)
--
1.9.3
More information about the CRIU
mailing list