[CRIU] [PHAUL] Question Regarding RPC Interface

Mike Rapoport rppt at linux.vnet.ibm.com
Wed Feb 28 10:53:12 MSK 2018


On Mon, Feb 26, 2018 at 03:10:09PM -0700, John Goen wrote:
> I have a question regarding the RPC interfaces with CRIU and their application
> to P.Haul.
> 
> As of now, it looks like P.Haul does all of its interaction with CRIU through
> the RPC interface defined in protocol buffers. However, there seems to be
> certain fields/arguments missing from the protobuf interface that would be
> necessary to invoke post-copy migration functionality through P.Haul.
> 
> From what I can understand, these are the steps necessary to conduct proper
> post-copy live migration through CRIU:
> 
>     - Tell CRIU to perform the initial dump at the source, having the
> lazy-pages flag set (this can be easily passed in a criu_req with lazy_pages=
> TRUE in the criu_opts protobuf message and with criu_req_type=DUMP)
>
>     - Bring up the lazy-pages daemon on the destination with the lazy-pages
> flag set (currently there seems no means of passing this through the protobuf
> RPC interface, though I feel something like having a new criu_req_type like
> LP_DAEMON with proper handling on the CRIU side would work, but I don't know
> the CRIU side of the code well enough to be sure this is the case)

Yeah, the LP_DAEMON, or LAZY_PAGES is missing in the RPC and it would be
great if you could add it.

The lazy-pages daemon will need page-server and optionally address and port
flags, so that it will request the pages from the source host.
 
>     - Call restore with the lazy-pages flag set (much like the initial dump,
> this seems to be fully doable through current protobuf RPC interfaces)
>
> Does this sound right to anyone?

Yep :) 

> If so, I'm fully willing to go in and try adding the RPC protobuf field
> and interaction necessary to get CRIU to work in this way, but I'm unsure
> where exactly this code would need to live or where to start with it.

Ideally, the first step would be implementing LP_DAEMON/LAZY_PAGES request
type in CRIU. The RPC handling is done in criu/cr-service.c and I believe
that handling of the lazy-pages RPC request will be quite similar to
handling of the page-server.
 
> Thanks,
> John

-- 
Sincerely yours,
Mike.



More information about the CRIU mailing list