This is the mail archive of the
mailing list for the GDB project.
CRIU and gdb
- From: Ruslan Kuprieiev <kupruser at gmail dot com>
- To: gdb at sourceware dot org, "criu at openvz dot org" <criu at openvz dot org>
- Date: Mon, 06 Apr 2015 18:34:18 +0300
- Subject: CRIU and gdb
- Authentication-results: sourceware.org; auth=none
There is a project called CRIU that implements checkpoint\restore in
It is able to save/restore process to/from files on disk(images).
While working on images->core dump conversion, I realized that criu images
could be used directly by gdb to debug a process. For example, there is
project called google-coredumper that lets applications create core dump
on demand. With CRIU we can achieve same thing but with a lot more data
produced. So I thought that it could be a good idea to teach gdb to use
Here is one of the ways I see it:
1) some process $PID hangs
2) save process state with criu:
criu dump -t $PID -D imgs [other flags]
3) criu-images action will restore process from imgs with --leave-stopped
flag and then attach to it.
(gdb) criu-images imgs
It might also be useful to be able to save state of debugged process by
stopping it, detaching and calling criu to save its state.
What do you guys think about it?