[CRIU] Standard stream is not terminal

Cyrill Gorcunov gorcunov at gmail.com
Mon Sep 1 10:52:35 PDT 2014


On Mon, Sep 01, 2014 at 09:35:07PM +0400, Pavel Emelyanov wrote:
> >>>
> >>> We require stdin to be a terminal to inherit it when we're migrating pty. Look,
> >>
> >> Wait wait wait. The -j option is required _only_ when the task we dump
> > 
> > This has nothing to do with -j option. What we're doing is
> > 
> > crtools_prepare_shared
> >   tty_prep_fds
> >     trying to reserve stdin for future possible use
> 
> This is to inherit terminal from parent. Why do we want this in Sanidhya case?

Because we can :-) Just kidding. Look, it's simply how it's done now -- we don't
know if we will ever need it or no -- and we reserve/check it early. The patch
I sent to Sanidhya does the trick -- we reserve this descriptor but instead of
testing it immediately if it's tty or not, we defer testing, thus if criu won't
need to inherit terminal during the whole restore procedure, the problem Sanidhya
is getting simply go away (if I don't miss something obvious what we do now is
simply a nit and should be fixed with the patch I sent).


More information about the CRIU mailing list