[CRIU] How does criu work with dynamic share library

Pavel Emelyanov xemul at parallels.com
Wed Dec 9 05:16:52 PST 2015


On 12/09/2015 03:15 PM, Jason Lee wrote:
> Hi,all!
> 
> I am doing C/R on target process with a large of dynamic share libraries.
> Although criu works well,I don't know how does criu work in this situation.
> criu will checkpoint the whole libraries into img?

Well, CRIU will note what libraries and their parts are mapped into the
process address space and remember the files' paths. Then it will scan
for the memory regions themselves and pick the pages, that are not shared
with the lib files.

> How does criu deal with process which is running in a function of library?

If the code in question is in a page, that is shared with lib file, then 
the page in question is skipped on dump. If the page is not shared, then
the page contents is saved and then restored back.

> In this time,the .got.plt section of process has address about
> function of library.

AFAIU those pages are typically un-shared from files, so they will likely
get copied into the images.

-- Pavel



More information about the CRIU mailing list