[CRIU] custom initialization during restore

CRIU criu criuport at gmail.com
Mon Aug 10 11:42:32 PDT 2015


Can we also use the plugin to call a specific function in the target
process? If yes, does it have to be a fixed address or the plugin could be
made aware of the function address dynamically (linking?)

On Thu, Jun 11, 2015 at 11:27 AM, CRIU criu <criuport at gmail.com> wrote:

> Thanks! Let me take a look.
>
> On Thu, Jun 11, 2015 at 6:01 AM, Pavel Emelyanov <xemul at parallels.com>
> wrote:
>
>> On 06/11/2015 05:06 AM, CRIU criu wrote:
>> > Hi,
>> >
>> > How can I add custom initialization code to restorer before unmap and
>> sigreturn?
>> > I'm trying to checkpoint /restore a single Android process. For
>> external dependencies, I
>> > need to initialize Java objects collected as a part of memory dump by
>> CRIU. The
>> > initialization code involves making a bunch of syscalls. Can I do this
>> by creating a
>> > custom restorer blob or inside cr_restore_tasks() in cr-restore.c?
>> Thanks!
>>
>> Hm :) Nice request. Right now there's no such ability in CRIU and I don't
>> see _easy_ solution. Complex solution can be plugin, that gets loaded into
>> restorer blob and that's called at the very end of restorer, but this
>> would
>> require non-trivial preparation of the plugin itself. We've played with
>> such things before, you can dig deep into the pie/ code and into the
>> compel project (https://github.com/xemul/compel) for details :)
>>
>> -- Pavel
>>
>>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openvz.org/pipermail/criu/attachments/20150810/639aef6d/attachment.html>


More information about the CRIU mailing list