• Saied Kazemi's avatar
    rework criu check logic · 70cb4326
    Saied Kazemi authored
    The "criu check" command to check if the kernel is properly configured
    to run criu is broken.
    
    The "criu check --ms" command used to be the way to tell criu to check
    only for features that have been merged upstream.  But recent kernels
    have a set of features whose presence doesn't necessarily mean that
    dump or restore will fail but rather *may* fail depending on whether
    the process tree uses those features.
    
    This patch deprecates --ms and introduces --extra, --experimental,
    and --all.  See "criu --help" or "man criu" for more info.
    
    Typical use cases are:
    
    	$ sudo criu check
    	<zero or more warnings and errors...>
    	Looks good.
    	$ echo $?
    	0
    
    	$ sudo criu check --extra
    	<zero or more warnings and errors...>
    	Looks good.
    	$ echo $?
    	1
    
    	$ sudo criu check --extra
    	<one or more warnings...>
    	Looks good but some kernel features are missing
    	which, depending on your process tree, may cause
    	dump or restore failure.
    	$ echo $?
    	1
    
    	$ sudo criu check --feature list
    	mnt_id aio_remap timerfd tun userns fdinfo_lock seccomp_suspend \
    		seccomp_filters loginuid cgroupns
    
    	$ sudo criu check --feature mnt_id
    	Warn  (cr-check.c:283): fdinfo doesn't contain the mnt_id field
    	$ echo $?
    	1
    
    	$ sudo criu check --feature tun
    	tun is supported
    	$ echo $?
    	0
    Signed-off-by: 's avatarSaied Kazemi <saied@google.com>
    Signed-off-by: 's avatarPavel Emelyanov <xemul@virtuozzo.com>
    70cb4326
Name
Last commit
Last update
..
.gitattributes Loading commit data...
.gitignore Loading commit data...
HOWTO.cross-compile Loading commit data...
Makefile Loading commit data...
asciidoc.conf Loading commit data...
criu.txt Loading commit data...