[CRIU] Help dumping and restoring a process

Jose Atiles jxatiles at hotmail.com
Sat Aug 18 05:32:03 MSK 2018


Hi, I'm interested in using criu to do debugging in games, saving a checkpoint to recreate bugs. Also to provide saving to games who do not have this feature.
My end target is saving a game that is being executed with wine. I'm currently using Linux mint 19 Mate 19.

I have tried to dump a process but have failed.
Also, criu check --extra says Looks good.

I did a small test trying to checkpoint a calculator, a text editor and Firefox, but none seem to work. Can you provide me some usage examples? can you tell me one basic type of application which I could use to test CRIU?

The following is my log file, please help me!

ies at mint:~$ sudo su
[sudo] password for aries:
root at mint:/home/aries# criu dump -D checkpoint -t 7909
Warn  (criu/kerndat.c:659): Can't load /run/criu.kdat
Error (criu/image.c:416): Can't open dir checkpoint: No such file or directory
root at mint:/home/aries# criu dump -D /home/aries/Documents/test -t 7909
Error (criu/namespaces.c:408): Can't dump nested net namespace for 8026
Error (criu/namespaces.c:626): Can't make netns id
Error (criu/cr-dump.c:1709): Dumping FAILED.
root at mint:/home/aries# criu dump -D "/home/aries/Documents/test" -t 7909
Error (criu/namespaces.c:408): Can't dump nested net namespace for 8026
Error (criu/namespaces.c:626): Can't make netns id
Error (criu/cr-dump.c:1709): Dumping FAILED.
root at mint:/home/aries# criu dump -D /home/aries/Documents/test -t 7909
Error (criu/namespaces.c:408): Can't dump nested net namespace for 8026
Error (criu/namespaces.c:626): Can't make netns id
Error (criu/cr-dump.c:1709): Dumping FAILED.
root at mint:/home/aries# criu dump -D /home/aries/Documents/test -t 17604
Warn  (compel/arch/x86/src/lib/infect.c:249): Will restore 17604 with interrupted system call
Warn  (compel/arch/x86/src/lib/infect.c:249): Will restore 17608 with interrupted system call
Warn  (compel/arch/x86/src/lib/infect.c:249): Will restore 17609 with interrupted system call
Warn  (compel/arch/x86/src/lib/infect.c:249): Will restore 17610 with interrupted system call
Error (criu/cr-dump.c:431): Task 17604 with SysVIPC shmem map @7fb97f613000 doesn't live in IPC ns
Error (criu/cr-dump.c:1411): Dump mappings (pid: 17604) failed with -1
Error (criu/cr-dump.c:1709): Dumping FAILED.
root at mint:/home/aries# criu restore -d  -D /home/aries/Documents/test
Error (criu/util.c:596): Can't read link of fd -404: No such file or directory
Error (criu/protobuf.c:75): Unexpected EOF on (null)
root at mint:/home/aries# criu restore -d -D /home/aries/Documents/test
Error (criu/util.c:596): Can't read link of fd -404: No such file or directory
Error (criu/protobuf.c:75): Unexpected EOF on (null)
root at mint:/home/aries# criu restore -d  /home/aries/Documents/test
Error: excessive parameter for command restore

Usage:
  criu dump|pre-dump -t PID [<options>]
  criu restore [<options>]
  criu check [--feature FEAT]
  criu page-server
  criu service [<options>]
  criu dedup
  criu lazy-pages -D DIR [<options>]

Commands:
  dump           checkpoint a process/tree identified by pid
  pre-dump       pre-dump task(s) minimizing their frozen time
  restore        restore a process/tree
  check          checks whether the kernel support is up-to-date
  page-server    launch page server
  service        launch service
  dedup          remove duplicates in memory dump
  cpuinfo dump   writes cpu information into image file
  cpuinfo check  validates cpu information read from image file

Try -h|--help for more info
root at mint:/home/aries# criu restore -D /home/aries/Documents/test
Error (criu/util.c:596): Can't read link of fd -404: No such file or directory
Error (criu/protobuf.c:75): Unexpected EOF on (null)
root at mint:/home/aries# criu dump -D ./home/aries/Documents/test -t 17604
Error (criu/image.c:416): Can't open dir ./home/aries/Documents/test: No such file or directory
root at mint:/home/aries# cd /home/aries/Documents/test
root at mint:/home/aries/Documents/test# criu dump -D /home/aries/Documents/test -t 17604
Warn  (compel/arch/x86/src/lib/infect.c:249): Will restore 17604 with interrupted system call
Warn  (compel/arch/x86/src/lib/infect.c:249): Will restore 17608 with interrupted system call
Warn  (compel/arch/x86/src/lib/infect.c:249): Will restore 17609 with interrupted system call
Warn  (compel/arch/x86/src/lib/infect.c:249): Will restore 17610 with interrupted system call
Error (criu/cr-dump.c:431): Task 17604 with SysVIPC shmem map @7fb97f613000 doesn't live in IPC ns
Error (criu/cr-dump.c:1411): Dump mappings (pid: 17604) failed with -1
Error (criu/cr-dump.c:1709): Dumping FAILED.
root at mint:/home/aries/Documents/test# criu check --extra
Looks good.
root at mint:/home/aries/Documents/test# test/zdtm.py run -a
bash: test/zdtm.py: No such file or directory
root at mint:/home/aries/Documents/test# cd ..
root at mint:/home/aries/Documents# cd ..
root at mint:/home/aries# cd ..
root at mint:/home# cd ..
root at mint:/# test/zdtm.py run -a
bash: test/zdtm.py: No such file or directory
root at mint:/# cd home
root at mint:/home# test/zdtm.py run -a
bash: test/zdtm.py: No such file or directory
root at mint:/home# cd aries
root at mint:/home/aries# test/zdtm.py run -a
bash: test/zdtm.py: No such file or directory
root at mint:/home/aries#

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openvz.org/pipermail/criu/attachments/20180818/da10acad/attachment-0001.html>


More information about the CRIU mailing list