- 16 Jan, 2012 2 commits
-
-
Andrey Vagin authored
create_pipe() may restore up to 3 descriptors. They may be both ends of pipes and a target descriptor. The image fd may hold any of them. Signed-off-by:
Andrey Vagin <avagin@openvz.org> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
This reverts commit 46c613cc. Andrey posted a proper fix for it. Moreover, the problem in first place was initiated by a parasite application running during test case, crtools knows nothing about. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
- 15 Jan, 2012 11 commits
-
-
Cyrill Gorcunov authored
It's perfectly fine to reuse descriptors here, since we use plain pipe() call and it migh choose the descriptor which we need after. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Add the -l option to show the list of tests Make the default zdtm/live/ prefix when running individual test Now you can do it like # sh ./zdtm.sh for running all tests # sh ./zdtm.sh -l to list available tests # sh ./zdtm.sh <test> to run test <test>, e.g. "static/pipe00" Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
This makes crtools correctly abort when working on wrong kernel. Otherwise all the open files will have the same (garbage) ID and the subsequent restore will result in broken app. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
The old code carried the path through the stack. Now we have pstree_pid and handy helpers to get one. Tested by pipes00 test from zdtm (it forks). Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
And do not use strcpy, better to stick with strncpy. Moreover, to be on a safe side make proc internal buffer big enough even for "(%16s)" format, it's hardly possible that the kernel ever change stat format but just to be on a safe side. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
To align data with previous callers. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Before # ./crtools -s -f unixsk-12713.img CR_FD_UNIXSK ---------------- fd 8 type 2 state 7 namelen 17 backlog 17 id 79422 peer 0 --> test-socket-conn fd 9 type 2 state 7 namelen 23 backlog 23 id 79423 peer 79423 --> test-socket-bound-conn ---------------- After # ./crtools -s -f unixsk-12713.img CR_FD_UNIXSK ---------------- fd 8 type 2 state 7 namelen 17 backlog 17 id 79422 peer 0 --> test-socket-conn fd 9 type 2 state 7 namelen 23 backlog 23 id 79423 peer 79423 --> test-socket-bound-conn ---------------- Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Leftover from merging stage. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
- 14 Jan, 2012 5 commits
-
-
Cyrill Gorcunov authored
%s specificator eats it and matching stream fails. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Repored-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
No need for the big PATH_MAX here. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Instead of passing self-vma file path to restorer code simply open it before restore_task call and pass descriptor instead. This saves some memory. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
- 13 Jan, 2012 17 commits
-
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
No func changes. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
We will later need other fields of this file, so let's parse it right now in a way, that allows to easily get new fields. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Start with /proc/pid/maps parser Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
* @xemul: crtools: Collect dumping fd parameters into one place crtools: Toss dump_one_fd args around crtools: Rename fd to lfd in dump_one_fd crtools: Sanitize pstree construction crtools: Remove unused printk_registers and co crtools: Deduplicate file info showing code crtools: Merge pstree collecting into showing crtools: Remove unused and wrong arrays from pstree image crtools: Remove lseeks after prep_cr_ calls crtools: Cleanup collect_pstree in cr-show Conflicts: cr-dump.c include/sockets.h sockets.c The conflicts are mostly because of commit 995ef5ecSigned-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
No need to track in a weird way. It's small structure. Moreover, the rest of parasite code doesn't count for space allocated _after_ the main control block. We simply had happened to not hit any problems before. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
This allows us to get rid of open-coded "/proc/pid/X". Based-on-patch-from: Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
It basically reverts e189efc1 which was overdone one. Reported-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com>
-
Stanislav Kinsbursky authored
NLM_F_DUMP is already defined as (NLM_F_ROOT|NLM_F_MATCH) Signed-off-by:
Stanislav Kinsbursky <skinsbursky@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Stanislav Kinsbursky authored
Signed-off-by:
Stanislav Kinsbursky <skinsbursky@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Andrey Vagin authored
Signed-off-by:
Andrey Vagin <avagin@openvz.org> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Sockets are special and we reuse fds in accept jobs. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
[avagin@: Drop redundant fcntl call, and err variable] Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 12 Jan, 2012 5 commits
-
-
Cyrill Gorcunov authored
* @xemul-mails: crtools: Collect dumping fd parameters into one place crtools: Toss dump_one_fd args around crtools: Rename fd to lfd in dump_one_fd crtools: Sanitize pstree construction crtools: Remove unused printk_registers and co crtools: Deduplicate file info showing code crtools: Merge pstree collecting into showing crtools: Remove unused and wrong arrays from pstree image crtools: Remove lseeks after prep_cr_ calls crtools: Cleanup collect_pstree in cr-show Conflicts: cr-show.c Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Introduce the fd_parms structure, that contains all we need to describe open fd during dump -- its name (int), pos, flags and id. The read_fd_parms routing fills one once and passes along the stack. This reduces the amount of arguments significantly. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Make the dump_one_fd fn accept local fd and integer target fd values instead of target fd dir and target fd string name. This saves couple of atoi-s (done once) and makes the next patch simpler. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
This variable is actually a local fd, so reflect this in its name. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Rename find_pstree_entry into add_<one> (since it doesn't find it) and move list adding into it. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-