- 16 Dec, 2015 19 commits
-
-
Evgeniy Akimov authored
First stage of finalize_restore unmaps the restorer blob, second stage detaches from processes. After first stage process tree is completely restored and processes are ready to continue run through sigreturn. This splitting allows us to execute something between these stages (e.g. restore freezer cgroup state). Signed-off-by:
Evgeniy Akimov <geka666@gmail.com> Signed-off-by:
Eugene Batalov <eabatalov89@gmail.com> Acked-by:
Andrew Vagin <avagin@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Evgeniy Akimov authored
CRIU sets freezer.state to "THAWED" during process tree dumping. That's why we can't simply save freezer.state file contents to cgroups image. New special function get_real_freezer_state() returns freezer cgroup state observed before CRIU dumping start. Patch puts its return value to dump file. Signed-off-by:
Evgeniy Akimov <geka666@gmail.com> Signed-off-by:
Eugene Batalov <eabatalov89@gmail.com> Acked-by:
Andrew Vagin <avagin@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
This one prints the /proc/pid/maps-like output, but with slightly more details. Like this 1 exe /zdtm/live/static/maps00 00400000-00406000 r-x /zdtm/live/static/maps00 00605000-00606000 r-- /zdtm/live/static/maps00 + 0x5000 00606000-00607000 rw- /zdtm/live/static/maps00 + 0x6000 7f4037845000-7f40379f9000 r-x /lib64/libc.so.6 7f40379f9000-7f4037bf8000 --- /lib64/libc.so.6 + 0x1b4000 7f4037bf8000-7f4037bfc000 r-- /lib64/libc.so.6 + 0x1b3000 7f4037bfc000-7f4037bfe000 rw- /lib64/libc.so.6 + 0x1b7000 7f4037bfe000-7f4037c03000 rw- 7f4037c03000-7f4037c23000 r-x /lib64/ld-linux-x86-64.so.2 7f4037e1e000-7f4037e22000 rw- 7f4037e22000-7f4037e23000 r-- /lib64/ld-linux-x86-64.so.2 + 0x1f000 7f4037e23000-7f4037e24000 rw- /lib64/ld-linux-x86-64.so.2 + 0x20000 7f4037e24000-7f4037e25000 rw- 7fff34652000-7fff34699000 rw- [stack?] 7fff346e2000-7fff346e4000 r-- 7fff346e4000-7fff346e6000 r-x [vdso] ffffffffff600000-ffffffffff601000 r-x [vsyscall] * Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Shows files opened by tasks. The output is like 1 0: /dev/null 1: /zdtm/live/static/session00.outns 2: /zdtm/live/static/session00.outns cwd: /zdtm/live/static root: / 6 0: /dev/null 1: /zdtm/live/static/session00.out.inprogress 2: /zdtm/live/static/session00.out.inprogress 3: pipe[18305] cwd: /zdtm/live/static root: / 10 0: /dev/null 1: /zdtm/live/static/session00.out.inprogress 2: /zdtm/live/static/session00.out.inprogress 3: pipe[18308] cwd: /zdtm/live/static root: / Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Appreciated-by: avagin@openvz.org
-
Pavel Emelyanov authored
Shows process tree from image. The output is like PID PGID SID COMM 1 1 1 session00 4 4 4 session00 7 7 7 session00 8 4 4 session00 11 11 11 session00 12 4 4 session00 13 13 13 session00 14 14 14 session00 15 4 4 session00 6 4 4 session00 10 9 9 session00 (the above is for session00 test). Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Appreciated-by: avagin@openvz.org
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Appreciated-by: avagin@openvz.org
-
Andrew Vagin authored
In this case it has an external master_id and we want to test that criu can handle it correctly. Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
The thread_bomb test was rewrited and ZDTM_THREAD_BOMB should be equal 5 now. Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
It works for tests which are executed in a separate pidns Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
It's an external one and it's already created and we don't have proper shared mount. Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Andrew Vagin authored
We don't need to remount a mount as private, when a source mount and a new mount has the same master_id and shared_id Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Dmitry Safonov authored
Signed-off-by:
Dmitry Safonov <dsafonov@odin.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Dmitry Safonov authored
Signed-off-by:
Dmitry Safonov <dsafonov@odin.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Dmitry Safonov authored
The value of loginuid cannot be changed inside container, with the exception if it was not set yet. This value is inherited on fork() from parent. So, to restore original loginuid values for all tasks: - unset the container parent loginuid - all children will have this value unsetted - on child restore set value from dump See http://lxr.free-electrons.com/source/kernel/audit.c#L635 https://jira.sw.ru/browse/PSBM-41993Signed-off-by:
Dmitry Safonov <dsafonov@odin.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Dmitry Safonov authored
https://jira.sw.ru/browse/PSBM-41993Signed-off-by:
Dmitry Safonov <dsafonov@odin.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Dmitry Safonov authored
https://jira.sw.ru/browse/PSBM-41993Signed-off-by:
Dmitry Safonov <dsafonov@odin.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 15 Dec, 2015 5 commits
-
-
Cyrill Gorcunov authored
Standalone criu target should not be used here because it doesn't carry all prerequisites needed. Instead simply use @all. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Acked-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Tycho Andersen authored
Signed-off-by:
Tycho Andersen <tycho.andersen@canonical.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
When running test in ns/uns flavor zdtm.py builds a temp root in test/ directory. The new action allows to remove all this stuff automatically. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Rodrigo Bruno authored
Signed-off-by: Rodrigo Bruno <rbruno at gsd.inesc-id.pt> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Rodrigo Bruno authored
This will be required for page-cache and page-proxy set. Signed-off-by: Rodrigo Bruno <rbruno at gsd.inesc-id.pt> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 14 Dec, 2015 3 commits
-
-
Andrew Vagin authored
A freezer cgroup can contain tasks which will be not dumped, criu unfreezes the group, so we need to freeze all extra task with ptrace like we do for target tasks. Currently we attache and send an interrupt signals to these tasks, but we don't call waitpid() for them, so then waitpid(-1, ...) returns these tasks where we don't expect to see them. v2: execute freezer_detach() only if opts.freeze_cgroup is set calculate extra tasks in a freezer cgroup correctly v3: s/frozen_processes/processes_to_wait/ Signed-off-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Stanislav Kinsburskiy authored
It will be used to mount AutoFS, because context creation is required in addition to actual mount operation. Signed-off-by:
Stanislav Kinsburskiy <skinsbursky@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Stanislav Kinsburskiy authored
This patch introduces three helpers: 1) pstree_item_by_real() - search for pstree item by real pid. 2) pstree_item_by_virt() - search for pstree item by virtual pid. 3) pid_to_virt() - return virtual pis by real one. Note: pstree_item_by_virt() and pid_to_virt() will be used to migrate AutoFS. Signed-off-by:
Stanislav Kinsburskiy <skinsbursky@virtuozzo.com> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 11 Dec, 2015 13 commits
-
-
Pavel Emelyanov authored
The head test is zdtm/lib/group, so it is impossible to run several instances of it in parallel Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
This is to make groups test start in uns flavors Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
When run in groups ip-freebind and ip-freebind-false fail to start simultaneously. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Dmitry Safonov authored
tty_find_restoring_task will prepare control terminal (by tcsetpgrp) only if tty is master. By a chance it's possible to pick slave terminal as a control, which will refrain restoring control terminal. https://jira.sw.ru/browse/PSBM-42093Signed-off-by:
Dmitry Safonov <dsafonov@odin.com> Reviewed-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
Reported-by:
Andrew Vagin <avagin@virtuozzo.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Running crit tool 4 times per test (decode, encode, decode --pretty and encode back again) is way too slow. The majority of time, as it turned out, goes on python load and arguments parsing. The en- and de-coding works pretty fast. So doing re-code logic in one python script for ALL images is way way faster -- ~1 hour vs ~1 minute on my box. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
There are loads and dumps method in pycriu.images that work with strings, instead of open()-ed files. For simplicity strings are turned into streams with io.BytesIO and the files are then pushed into regular load/dump methods. The problem is that array.array object doesn't work with io object in .fromfile/.tofile methods, so we have to read/write the data from them explicitly and use .fromstring/.tostring for arrays. With this the crit test finally passes :D Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Acked-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
Typical output | { | "magic": "IPCNS_MSG", | "entries": [ | { | "desc": { | "key": 2181112128, | "uid": 18943, | "gid": 58467, | "cuid": 18943, | "cgid": 58467, | "mode": 438, | "id": 0 | }, | "qbytes": 16384, | "qnum": 2, | "extra": [ | { | "mtype": 1, | "msize": 15 | }, | "VGVzdCBzeXN2NSBtc2cA\n", | { | "mtype": 26538, | "msize": 27 | }, | "WWV0IGFub3RoZXIgdGVzdCBzeXN2NSBtc2cA\n" | ] | } | ] | } Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-