标签:
Hope we can find Avatar and goal in.
Program: simple client/server, loopback
Tools: CRIU does checkpoint/restore work
ps -ef
liuqius+ 20052 2464 0 22:00 pts/6 00:00:00 ./server 7022
liuqius+ 20053 2464 0 22:00 pts/6 00:00:00 ./client 127.0.0.1 7022
When I start server and client, and then use CRIU to do checkpoint:
root@liuqiushan-K43SA:/home/liuqiushan/BCMatrix/criu/deps/criu-x86_64#
criu dump -D checkpoint -t 20052 –shell-job –tcp-established
Though it can generate the checkpoint image files, but some errors happen:
Error (parasite-syscall.c:389): si_code=1 si_pid=20114 si_status=0
Error (parasite-syscall.c:389): si_code=1 si_pid=20119 si_status=0
So let’s see parasite-syscall.c:
I think we can ignore the Error, because it uses SIGCHLD to do exit.
Continue.
We finish the dump work on server and client respectively. If we restore them at once, then it will succeed. But if we reboot the laptop, we will encounter the following Errors:
root@liuqiushan-K43SA:/home/liuqiushan/BCMatrix/criu/deps/criu-x86_64#
criu restore -d -D checkpoint –shell-job –tcp-established
iptables: Bad rule (does a matching rule exist in that chain?).
Error (util.c:580): exited, status=1
Error (netfilter.c:69): Iptables configuration failed: No such file or directory
iptables: Bad rule (does a matching rule exist in that chain?).
Error (util.c:580): exited, status=1
Error (netfilter.c:69): Iptables configuration failed: No such file or directory
Can’t read socket: Connection reset by peer
root@liuqiushan-K43SA:/home/liuqiushan/BCMatrix/criu/deps/criu-x86_64# criu restore -d -D checkpoint_client –shell-job –tcp-established
iptables: Bad rule (does a matching rule exist in that chain?).
Error (util.c:580): exited, status=1
Error (netfilter.c:69): Iptables configuration failed: No such file or directory
iptables: Bad rule (does a matching rule exist in that chain?).
Error (util.c:580): exited, status=1
Error (netfilter.c:69): Iptables configuration failed: No such file or directory
PP 26 -> -1
Pay attention to :
iptables: Bad rule (does a matching rule exist in that chain?).
And also through util.c and netfilter.c, we can focus on the problem of iptables.
More importantly, the server can restore successfully, but the client, it seems that:
the client also restores, but after ‘PP 26->-1 (above)’, it exit abnormally.
We should pay attention to these information:
According to SIGCHLD mentioned above, I try such work:
first dump client. then server,
and restore server, then client
Also failed.
A little confusing.
2015-02-28
Avatar: TCP connection migration with CRIU
标签:
原文地址:http://blog.csdn.net/bluecloudmatrix/article/details/43990631