- 02 Mar, 2012 12 commits
-
-
Kir Kolyshkin authored
No need to hardcode it. Signed-off-by:
Kir Kolyshkin <kir@openvz.org> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kir Kolyshkin authored
Makes invocation way easier. Signed-off-by:
Kir Kolyshkin <kir@openvz.org> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kir Kolyshkin authored
1. We need to regenerate *-blob.h files if generating script changes 2. Do not use hardcoded script name Signed-off-by:
Kir Kolyshkin <kir@openvz.org> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kir Kolyshkin authored
There is no need to make .d files for restorer-blob.h Signed-off-by:
Kir Kolyshkin <kir@openvz.org> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kir Kolyshkin authored
These changes are mostly for better readability and style. The only actual difference (in the output produced) is the last item. (1) Use UPPERCASE variable names (2) Simplify names (get rid of name_ prefix for everything) (3) Rename variables: - name_ifndef to INC_GUARD, - name_prefix_offset to PREFIX, - name_bin to BINARY. (4) Replace sed with tr for simplicity (5) Replace grep with awk condition (6) Don't escape every $ and " inside AWK_CMD, just quote the full string (7) Use cat and 'here document' instead of many echoes (8) Simplify hexdump arguments, use single -e option (9) Insert our name into 'Generated by' comment. Signed-off-by:
Kir Kolyshkin <kir@openvz.org> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Otherwise I'm getting errors like CR_FD_SK_QUEUES ---------------- Error (./include/util.h:102): Can't read img file: Bad file descriptor ---------------- Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Cyrill Gorcunov authored
Due to code sharing, especially in IPC area, the unbinding is done via helper macros and sysclt engine tuning (new CTL_SHOW action added). Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 01 Mar, 2012 15 commits
-
-
Cyrill Gorcunov authored
The messages are filtered by their type LOG_MSG - plain messages, they escape any (!) log level filtration and go to stdout LOG_ERROR - error messages LOG_WARN - warning messages LOG_INFO - informative messages LOG_DEBUG - debug messages By default the LOG_WARN log level is used, thus LOG_INFO and LOG_DEBUG messages will not appear in output stream. pr_panic helper was replaced with pr_err, pr_warning shorthanded to pr_warn and old printk if rather pr_msg now. Because we share messages between "show" and "dump" actions, before the "show" action proceed we need to tune up log level and set it to LOG_INFO. Also note that printing of VMA and siginfo now became LOG_INFO messages, it was not that correct to print them regardless the log level. 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
We have a few helper functions which all do setup logfd but in different program flow context. So rename them for grepability. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
When seizing a task and waiting for it to stop, we can receive an event from kernel, that the task didn't stop, but caught a signal. Don't treat this as an error, let the victim handle it and proceed. The transition/fork test should work OK now. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Empty list on scan error means, that the very top task ran away from us. There's no point in trying to catch one. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
This can happen while dumping a pid-namespace (we can't do it now), thus put this check not to forget one in the future. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Tasks can fork or die while we try to seize them. It's much more simpler and much more reliably to unseize what was seized and walk the tree again in case of some tree check failed. Yes, this makes it impossible to suspend a big tree which constantly forks :( but I'd prefer fixing more urgent issues before. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Remove CR_TASK_XXX states, use the TASK_XXX ones (for image). This is required to unseize tasks properly in the next patches. Plus, make sure that pstree_list and the seized set coincide (i.e. handle error in collect_task). Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
When we've seized all the tasks and threads found in /proc check for the /proc contents be the same. Do it one-by-one as we descend the tree. This is OK, since tasks cannot create kids for anyone but themselves or their parents (reparent will be handled later). Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
It's in item already. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
While we try to seize task it can die and give its pid to somebody else. This can break pstree consistency. Check for parent being valid after task is seized. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Move proc checks for Z-state into seize_task(). Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Merge two calls into one helper. For future. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Pavel Emelyanov authored
Signals shouldn't come to parasite after we've blocked them. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Without the patch all files starting with "." will be ommited. Use of strcmp() - explicit check for "." and ".." looks clearer. Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
- 29 Feb, 2012 12 commits
-
-
Cyrill Gorcunov authored
- drop double file-ids.h inclusion - rename fd_id_entry to plain entry, it's used just in a couple of lines only, no need for complex name Reported-by:
Kir Kolyshkin <kir@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Small cleanup patch Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Based on xemul@ patches. Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Based on xemul@ patches. Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
Based on xemul@ patches. Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
This patch was designed to be generic and thus usable for all kinds of sockets. Not sure, thah this goal has been reached, but at least I tried. Key ideas: 1) sockets queue dump file have to be readed first and then packets entries with offset for it's data in image will be collected in doubly linked list by read_sockets_queue() function. Note: list will contain sockets queues for all (!) the sockets of the task. 2) socket queue can be restored by restore_socket_queue(), which selects packets from the list by passed id and use sendfile() top send them to the passed socket. It also removes packet from the list and frees it. Based on xemul@ patches. Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
This patch was designed to be generic and thus usable for all kinds of sockets. Not sure, thah this goal has been reached, but at least I tried. Key ideas: 1) On-stack structure for collecting sockets queues and then passing them to parasite code. 2) Singly linked list is used for collecting structures, representing sockets of any kind (!) with queues. Based on xemul@ patches. Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
This patch adds sockets queue dump functionality. Key ideas 1) sockets info is passed as plain array in parasite args. 2) new socket option SO_PEEK_OFF with MSG_PEEK is used to read the get the queue's packets. 3) Buffer for packet will be allocated for each socket separately and with size of socket sending buffer. For stream sockets is means, that it's queue will be dumped in chunks of this size. Note: loop around sys_msgrcv() is required for DGRAM sockets - sys_msgrcv() with MSG_PEEK will return only one packet. Based on xemul@ patches. Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
This test is based on original version by xemul@ - second message to queue added. Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
Kinsbursky Stanislav authored
This is a cleanup patch. Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-
- 28 Feb, 2012 1 commit
-
-
Kinsbursky Stanislav authored
Signed-off-by:
Stanislav Kinsbursky <skinsbursky@openvz.org> Acked-by:
Pavel Emelyanov <xemul@parallels.com> Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org>
-