Skip to content
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

A "--tcp-established" Error ? #2535

Open
maglna1 opened this issue Dec 4, 2024 · 11 comments
Open

A "--tcp-established" Error ? #2535

maglna1 opened this issue Dec 4, 2024 · 11 comments

Comments

@maglna1
Copy link

maglna1 commented Dec 4, 2024

1、First try:
(1) command:
docker checkpoint create sufen-t-05 sufen-t-05-ck1

(2)Error:
Error response from daemon: Cannot checkpoint container sufen-t-04: runc did not terminate sucessfully: criu failed: type NOTIFY errno 0 path= /run/containerd/io.containerd.runtime.v1.linux/moby/c81365be49b12e82b367a98530cb6c03a6ffb39ecdbbd1e8947eb759d33fb4ac/criu-dump.log: unknown

(00.031195) Error (criu/sk-inet.c:181): Connected TCP socket, consider using --tcp-established option.
(00.031241) ----------------------------------------
(00.031255) Error (criu/cr-dump.c:1344): Dump files (pid: 13164) failed with -1

2、Second try:
(1)command:
docker checkpoint create --tcp-established sufen-t-05 sufen-t-05-ck1
(2)Error:
unknown flag: --tcp-established
See 'docker checkpoint create --help'.

3、env
docker version : 19.03.13
criu : 3.10

4、Question:how to solve this error or how to use "--tcp-established option"?

@adrianreber
Copy link
Member

This sounds like a docker problem. You should submit a patch to get the --tcp-established parameter added.

You could try Podman which exposes the --tcp-established parameter to the user (https://docs.podman.io/en/latest/markdown/podman-container-checkpoint.1.html#tcp-established) or try the a configuration file: https://criu.org/Docker#Passing_additional_options

@maglna1
Copy link
Author

maglna1 commented Dec 4, 2024

1、Sorry, docker containers must be used in my business environment.

What should I do?

Add tcp-established to the "/etc/criu/runc.conf" / "~/.criu/default.conf" / "/etc/criu/default.conf" file?

2、I have done these:

master:/home/sufen/criu/criu-3.10 # cat /etc/criu/runc.conf
tcp-established

master:/home/sufen/criu/criu-3.10 # cat ~/.criu/default.conf
tcp-established

master:/home/sufen/criu/criu-3.10 # cat /etc/criu/default.conf
tcp-established

3、But I also got the error:
(1)command:
master:/home/sufen/criu/criu-3.10 # docker checkpoint create sufen-t-06 sufen-t-06-ck1
(2)error:
Error response from daemon: Cannot checkpoint container sufen-t-06: runc did not terminate sucessfully: criu failed: type NOTIFY errno 0 path= /run/containerd/io.containerd.runtime.v1.linux/moby/31b8e64c30097587300df014085a1f926c04e51e4eef58d89c4bf5b5bb1ed24e/criu-dump.log: unknown
(3)criu-dump.log:
(00.030803) Error (criu/sk-inet.c:181): Connected TCP socket, consider using --tcp-established option.
(00.030852) ----------------------------------------
(00.030863) Error (criu/cr-dump.c:1344): Dump files (pid: 31809) failed with -1

4、What should I do next to fix this error?

@adrianreber
Copy link
Member

You docker version is from 2020 and CRIU is from 2018. This just too old. Update to the latest versions.

@maglna1
Copy link
Author

maglna1 commented Dec 4, 2024

Unfortunately, my company uses Docker 18.09.0 as the container for the entire system, so I can't use the advanced Docker version.

1、my runc verion is 1.1.5, is that a runc problem?

(1)command:
master:/home/sufen/criu/criu-3.10 # runc --version
runc version 1.1.5
commit: v1.1.5-0-gf19387a6bec4
spec: 1.0.2-dev
go: go1.19.7
libseccomp: 2.5.3

2、by the way, which criu version should I choose? Can you recommend a criu version to me? ty

@adrianreber
Copy link
Member

Can you recommend a criu version to me?

The latest

@maglna1
Copy link
Author

maglna1 commented Dec 4, 2024

1、Okay, is the latest version 4.0? When I use "make", I got an error.

(1)command:
master:/home/sufen/criu/criu-4.0 # make
Note: Building without setproctitle() and strlcpy() support.
Install libbsd-devel (RPM) / libbsd-dev (DEB) to fix.
Note: Building without amdgpu_plugin.
Install libdrm-devel (RPM) or libdrm-dev (DEB) to fix.
Note: Building without GnuTLS support.
Install gnutls-devel (RPM) or gnutls-dev (DEB) to fix.
Warn: Building without nftables support.
Install nftables-devel (RPM) or libnftables-dev (DEB) to fix.
fatal: Not a git repository (or any parent up to mount point /)
Stopping at filesystem boundary (GIT_DISCOVERY_ACROSS_FILESYSTEM not set).
make[1]: Nothing to be done for 'all'.
make[1]: 'images/built-in.o' is up to date.
make[1]: 'compel/plugins/std.lib.a' is up to date.
make[1]: 'compel/plugins/fds.lib.a' is up to date.
CC compel/src/lib/infect.o
compel/src/lib/infect.c: In function ‘parasite_memfd_exchange’:
compel/src/lib/infect.c:865:19: error: ‘MAP_FIXED_NOREPLACE’ undeclared (first use in this function); did you mean ‘_IOS_NOREPLACE’?
remote_flags |= MAP_FIXED_NOREPLACE;
^~~~~~~~~~~~~~~~~~~
_IOS_NOREPLACE
compel/src/lib/infect.c:865:19: note: each undeclared identifier is reported only once for each function it appears in
compel/src/lib/infect.c: At top level:
cc1: error: unrecognized command line option ‘-Wno-unknown-warning-option’ [-Werror]
cc1: error: unrecognized command line option ‘-Wno-dangling-pointer’ [-Werror]
cc1: all warnings being treated as errors
make[1]: *** [/home/sufen/criu/criu-4.0/scripts/nmk/scripts/build.mk:215: compel/src/lib/infect.o] Error 1
make: *** [Makefile.compel:35: compel/libcompel.a] Error 2

(2)How can I solve this error?

(3)by the way, Can you recommend a version mapping between docker and criu to me? i will try. ty

@adrianreber
Copy link
Member

Please let us know which OS you are using. You are making it really difficult without providing some information about your environment. But it seems like everything is just too old.

@maglna1
Copy link
Author

maglna1 commented Dec 4, 2024

im using SUSE 15 & 4.12.14-23-default

@maglna1
Copy link
Author

maglna1 commented Dec 4, 2024

(1)Can you recommend a linux system version + docker version + criu version mapping table to me? I will reinstall my linux system so that I can successfully use criu for my docker container?

(2)And one more question, Do you know that the Euler system can use the CRIU function? For example, the 5.10.0-136.12.0.86.h1903.eulerosv2r12.x86_64 version

@adrianreber
Copy link
Member

I use it on Fedora. The combination with Podman works pretty good.

Copy link

github-actions bot commented Jan 4, 2025

A friendly reminder that this issue had no activity for 30 days.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants