[CRIU] Problem of restore by RPC

Jingchao Sun jcsun at asu.edu
Mon Jul 27 07:24:22 MSK 2020


Dear all,

I'm trying to restore a checkpoint by RPC, and got the error message as
follows,

(00.018045)  33670: Opening fdinfo-s
(00.018048)  33670: tty: open driver pts id 0xc8 index 3 (master 0 sid
11261 pgrp 33670 inherit 1)
(00.018051)  33670: Error: tty: Don't have tty to inherit session from,
aborting
(00.018060)  33670: Error: Unable to open fd=0 id=0xc8
(00.022727) Error: 33670 killed by signal 9: Killed
(00.022767) Unlink remap dev/shm/mvm-zb.cr.1.ghost
(00.022780) Unlink remap tmp/#102696195.cr.2.ghost
(00.022808) Error: Restoring FAILED.

I'm running CRIU (v3.14) as a daemon service ( criu service --daemon -o
xxx.log -v4 --address /var/run/criu_service.socket) and receiving RPC from
client to checkpoint and restore. Checkpoint works well, but restore got no
luck. The error is related to the following code, where STDIN_FILENO is not
considered as a tty. Any suggestion on solving this issue? Thanks!

int tty_prep_fds(void)
{
    if (!opts.shell_job)
        return 0;

    if (!isatty(STDIN_FILENO))
        pr_info("Standard stream is not a terminal, may fail later\n");
    else
        stdin_isatty = true;

    self_stdin_fdid = fdstore_add(STDIN_FILENO);
    if (self_stdin_fdid < 0) {
        pr_err("Can't place stdin fd to fdstore\n");
        return -1;
    }

    return 0;
}

Best regards,

Steven
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openvz.org/pipermail/criu/attachments/20200726/215a8937/attachment.html>


More information about the CRIU mailing list