<div dir="ltr"><div>When i test :<br><i>Now let's see how to dump the same program when it is just started from
the shell without any additional setsid and stdio redirection.
For that we need to execute our test script or another program (e.g.
"top") from a terminal without any redirection.
</i><br></div><div>Part 2 of: <a href="http://criu.org/Simple_loop">http://criu.org/Simple_loop</a><br></div><div><br></div>i can restart several times :<br>root@thouraya-Lenovo-3000-N500:/home/thouraya# cd imgDir1<br>root@thouraya-Lenovo-3000-N500:/home/thouraya/imgDir1# criu restore -vvvv -o restore.log --shell-job<br>
mardi 15 juillet 2014, 18:25:07 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:08 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:09 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:10 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:11 (UTC+0100)<br>
mardi 15 juillet 2014, 18:25:12 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:13 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:14 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:15 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:16 (UTC+0100)<br>
mardi 15 juillet 2014, 18:25:17 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:18 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:19 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:20 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:21 (UTC+0100)<br>
mardi 15 juillet 2014, 18:25:22 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:23 (UTC+0100)<br><br>root@thouraya-Lenovo-3000-N500:/home/thouraya/imgDir1# criu restore -vvvv -o restore.log --shell-job<br>mardi 15 juillet 2014, 18:25:26 (UTC+0100)<br>
mardi 15 juillet 2014, 18:25:27 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:28 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:29 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:30 (UTC+0100)<br>mardi 15 juillet 2014, 18:25:31 (UTC+0100)<br>
mardi 15 juillet 2014, 18:25:32 (UTC+0100)<br><br><div><div><br></div><div>Bests. <br></div></div></div><div class="gmail_extra"><br><br><div class="gmail_quote">2014-07-15 17:35 GMT+01:00 Thouraya TH <span dir="ltr"><<a href="mailto:thouraya87@gmail.com" target="_blank">thouraya87@gmail.com</a>></span>:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div dir="ltr"><div>Ok, thanks for answer.<br>For a second restore, it didn't work:<div class=""><br>root@thouraya-Lenovo-3000-N500:/home/thouraya# cd imgDir/<br>
root@thouraya-Lenovo-3000-N500:/home/thouraya/imgDir# criu restore -d -vvv -o restore.log && echo OK<br></div>
--> it doesn't display OK <br><br></div><div>Have you an idea ?<br></div><div><br></div>Best Regards. <br></div><div class="gmail_extra"><br><br><div class="gmail_quote">2014-07-15 17:31 GMT+01:00 Pavel Emelyanov <span dir="ltr"><<a href="mailto:xemul@parallels.com" target="_blank">xemul@parallels.com</a>></span>:<div>
<div class="h5"><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div><div>On 07/15/2014 08:21 PM, Thouraya TH wrote:<br>
> root@thouraya-Lenovo-3000-N500:/home/thouraya# cd imgDir/<br>
> root@thouraya-Lenovo-3000-N500:/home/thouraya/imgDir# criu restore -d -vvv -o restore.log && echo OK<br>
> OK<br>
> root@thouraya-Lenovo-3000-N500:/home/thouraya/imgDir# ls<br>
> cgroup.img fifo-data.img netlinksk.img sigacts-20099.img<br>
> core-19654.img fifo.img ns-files.img signalfd.img<br>
> core-20099.img filelocks-19654.img packetsk.img signal-p-19654.img<br>
> creds-19654.img filelocks-20099.img pagemap-19654.img signal-p-20099.img<br>
> creds-20099.img fs-19654.img pagemap-20099.img signal-s-19654.img<br>
> dump.log fs-20099.img pages-1.img signal-s-20099.img<br>
> eventfd.img ids-19654.img pages-2.img sk-queues.img<br>
> eventpoll.img ids-20099.img pipes-data.img stats-dump<br>
> eventpoll-tfd.img inetsk.img pipes.img stats-restore<br>
> ext-files.img inotify.img pstree.img tty.img<br>
> fanotify.img inotify-wd.img reg-files.img tty-info.img<br>
> fanotify-mark.img inventory.img remap-fpath.img tunfile.img<br>
> fdinfo-2.img mm-19654.img restore.log unixsk.img<br>
> fdinfo-3.img mm-20099.img sigacts-19654.img<br>
> root@thouraya-Lenovo-3000-N500:/home/thouraya/imgDir# vim restore.log<br>
><br>
><br>
> i have a new file restore.log ,<br>
> Here is the initial code:<br>
><br>
> $ cat > test.sh <<-EOF<br>
> #!/bin/sh<br>
> while :; do<br>
> sleep 1<br>
> date<br>
> done<br>
> EOF<br>
> $ chmod +x test.sh<br>
> $ setsid ./test.sh < /dev/null &> test.log &<br>
><br>
> My question: besides this file, what I must have ?<br>
<br>
</div></div>The restored processes.<br>
<div><br>
> the time should increment in the test.log file ?<br>
<br>
</div>Yes, after some time.<br>
</blockquote></div></div></div><br></div>
</blockquote></div><br></div>