When restoring a container using runc, it does not stop immediately if the CRIU version does not meet requirements. #4365
Unanswered
yangzhao02
asked this question in
Q&A
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
In
runc/libcontainer/criu_linux.go
, there is the following Restore function (line 618-line 796).On line 716-line 718, there is the following content:
This function will call the handleRestoringNamespaces function in
runc/libcontainer/criu_linux.go
(line 209-line 246), and on line 219, it will further call handleRestoringExternalNamespaces (runc/libcontainer/criu_linux.go
line 247-line 276). On line 248, there is the following code:This
criuSupportsExtNS
function is located atrunc/libcontainer/criu_linux.go
: line 167-line 181, with the following content:When the CRIU version is lower than the minVersion,
criuSupportsExtNS
will return false, and handleRestoringExternalNamespaces will return nil. Consequently, in theRestore
function (line 716-line 718), it will evaluateerr == nil
and then continue executing the subsequent logic of theRestore
function. However, if the CRIU version does not meet the requirements, will continuing the execution of the Restore function (runc/libcontainer/criu_linux.go
: line 716-line 718) lead to some unpredictable behaviors? Should we consider directly terminating the execution of the Restore function and return an appropriate error message when the CRIU version does not satisfy the runc requirements?Beta Was this translation helpful? Give feedback.
All reactions