-
Notifications
You must be signed in to change notification settings - Fork 609
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Checkpoint/restore of ICMP sockets is not supported #2557
Comments
I am not 100% sure, but taking a quick look at source code it seems CRIU cannot checkpoint ICMP sockets. My ping does the following, to open a socket: CRIU has following code: /* Make sure it's a proto we support */
switch (proto) {
case IPPROTO_IP:
case IPPROTO_TCP:
case IPPROTO_UDP:
case IPPROTO_UDPLITE:
break;
default:
pr_err("Unsupported proto %d for socket %x\n", proto, ino);
return 0;
}
|
@adrianreber Yeah, i am doing a test. Thanks very much for your reply! Hope IPPROTO_ICMP will be supported some day |
Best way would be to contribute this feature yourself. Please close the ticket if you have no more questions. |
It might good to keep the issue open. |
Currently there is no option to checkpoint/restore programs that use ICMP sockets, such as `ping`. This patch adds support for the same. Fixes checkpoint-restore#2557 Signed-off-by: समीर सिंह Sameer Singh <[email protected]>
@kissaxin572 The patch in #2558 seems to work. Since ICMP is a stateless protocol, the checkpoint/restore implementation is very similar to that of UDP. |
Description
My environment is Ubuntu20.04 with Docker version 27.4.0, Criu version 4.0. I tried to checkpoint a container running a command "ping www.baidu.com", but i failed. From the logs, it seems to be related to the ICMP protocol. When i tried to checkpoint a container running a command "tcpdump", it also failed.
Steps to reproduce the issue:
Describe the results you received:
root@ubuntu20:/home/ubuntu20/Workspace/Scripts# docker run -d --name base --privileged --security-opt seccomp:unconfined pure_ubuntu20 /bin/bash -c "ping www.baidu.com; tail -f /dev/null"
baea6deb367e3f341b46d5f8e40bba5fc6b250beda63fc3af5727b6276f001ea
root@ubuntu20:/home/ubuntu20/Workspace/Scripts# docker ps
CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES
baea6deb367e pure_ubuntu20 "/bin/bash -c 'ping …" 2 seconds ago Up 2 seconds base
root@ubuntu20:/home/ubuntu20/Workspace/Scripts# docker checkpoint create --leave-running=true base ck1
Error response from daemon: Cannot checkpoint container base: runc did not terminate successfully: exit status 1: criu failed: type DUMP errno 0 path= /run/containerd/io.containerd.runtime.v2.task/moby/baea6deb367e3f341b46d5f8e40bba5fc6b250beda63fc3af5727b6276f001ea/criu-dump.log: unknown
Describe the results you expected:
Additional information you deem important (e.g. issue happens only occasionally):
CRIU logs and information:
CRIU full dump/restore logs:
Output of `criu --version`:
Output of `criu check --all`:
Additional environment details:
root@ubuntu20:/home/ubuntu20/Workspace/Scripts# uname -r
5.15.0-125-generic
root@ubuntu20:/home/ubuntu20/Workspace/Scripts# docker --version
Docker version 27.4.0, build bde2b89
The text was updated successfully, but these errors were encountered: