- 29 Apr, 2012 1 commit
-
-
Pavel Emelyanov authored
Calculate the best width for address and print them all with it. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 03 May, 2012 2 commits
-
-
Andrey Vagin authored
A few of our functions use buffer and string functions. All these functions require that a string contains '\0' at the end. Before this patch we didn't guarantee that. I've seen segmentation fault in parse_pid_stat_small. v2: simplify code v3: remove assignment, because it's redundant and a size of object file become bigger. Signed-off-by:
Andrey Vagin <avagin@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>
-
- 28 Apr, 2012 11 commits
-
-
Pavel Emelyanov authored
This test is very basic :( Need more work on it. One note about --close arg to crtools -- bash leaves all fds open when laucnhing progams, and for restore this is critical, as one of them can be busy. Iterating over all the possibel fds and closing them is "do not want" thing. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Only manual mode at the moment. Need to automate it later. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
What it does is uses the tcp repair engine from the kernel. On dump the connection is locked with netfilter, socket is put in the repair state and then its internals are dumped. On restore we create a socket, put it into repair, dress it up and then unlock all the connections at the very end. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
When dump finished with error we should unlock all locked previously connections. When restoring we should collect connctions and unlock them all at the end. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Introduce the image file for tcp info, its entry and the show method. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Between dump and restore of a tcp conn we have to keep the connection blocked, since the socket doesn't exists in the kernel at this time and any packet from peer will result in RST. Thus, add the -j DROP rule for every connection we're about to repair. Later, when we support containers, this will be extended to stop the whole networking in a CT instead of cherry-peeking connections. It does system("iptables ...") for this, but I'd prefer using the libnetfilter-devel sometime in the future. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
First of all -- to make crtools dump/restore established tcp sockets you have to specify the --tcp-established options. By doing so you inform crtools that a) you know, that after dump there will be a netfilter rules blocking the dumped connections b) you guarantee, that before restore this netfilter block is still there What else this patch does is simple -- collects establised sockets and calls the dump/restore tcp function (now empty) where appropriate. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Just a codemove. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
After reopen_fd_as the original fd is closed. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 26 Apr, 2012 8 commits
-
-
Pavel Emelyanov authored
Funny, but after this git thinks, that I've renamed the sockets.c file into sk-unix.c one and fixed it a little bit %) Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
For simpler unix socket code move. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
For simpler unix socket code move. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Rename the fn and fix indentation. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Collect all unix sockets in a list while dumping to check whether we've missed something early (at the restore time it can be already late for roll-back). Plus, fix the checks for external stream sockets. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
This is common, that opened fd fix its fowner and flags. Make a cuntion for this. Those that obtain fd with open() don't need to restore flags though. A thought -- do we need yet another abstraction between fdinfo and type-d files? Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
The conn job misses fowner restoratio. Other places are ok, but toss the code for easier next patching. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 25 Apr, 2012 7 commits
-
-
Cyrill Gorcunov authored
The kernel patch titled c/r: prctl: Simplify PR_SET_MM on mm::code/data assignment (which now in linux-next) allows us to setup code/data addresses without requirement of underlied VMA. So revert commit 090513d5 and make code more simplier Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
Kernel 3.4-rc4 has two formats for stack "[stack]" and "[stack:%d]" (for threads) so adopt our parsing routine for both. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
To reflect the change in kernel v3.4-rc4 update PR_GET_TID_ADDR and rename it to PR_GET_TID_ADDRESS as it named in kernel. [xemul: this fixes futex test broken with 3.4 rebase] Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Some of them (FC12 I debug on) doesn't have fown_ex stuff in their libc. Add the missing declarations. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
Since 3.4-rc the seize-devel flag is removed, the stop event is renamed (great) and the way si_code should be parsed has been fixed. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Pavel Emelyanov authored
The getsid/getpig require _GNU_SOURCE on some libc-s. Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 24 Apr, 2012 1 commit
-
-
Konstantin Khlebnikov authored
printf() has standard flag for adding "0x" prefix before hexadecimal integer. MOD='[-+]\?[0-9]*.\?[0-9]*[lL]*' git grep -l "0x%${MOD}x" | xargs -n1 sed -e "s/0x%\(${MOD}\)x/%#\1x/g" -i Signed-off-by:
Konstantin Khlebnikov <khlebnikov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 23 Apr, 2012 7 commits
-
-
Cyrill Gorcunov authored
Easier to read. [ xemul: There's a silent change in how sk buffer is read in -- before the patch there was a static buffer for data, now this thing is xrealloc-ed ] 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>
-
Cyrill Gorcunov authored
Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
Needed for IPv6. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
To be in same form as collected sockets. 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>
-
Cyrill Gorcunov authored
Will need it for IPv6 Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
- 19 Apr, 2012 3 commits
-
-
Cyrill Gorcunov authored
This allows to have more detailed control over files generated and might be extended in future. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
No need to duplicate variable for pie.lds.S. Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-
Cyrill Gorcunov authored
Should be -fpie (actually it's not a problem at moment since asm files have simple code and work even without -fpie passed, but better to fix it anyaway). Signed-off-by:
Cyrill Gorcunov <gorcunov@openvz.org> Signed-off-by:
Pavel Emelyanov <xemul@parallels.com>
-