<html><body><div style="color:#000; background-color:#fff; font-family:HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif;font-size:16px"><div id="yui_3_16_0_1_1438224649167_10827"><span>Hi,</span></div><div id="yui_3_16_0_1_1438224649167_10827"><span><br></span></div><div id="yui_3_16_0_1_1438224649167_10827"><span id="yui_3_16_0_1_1438224649167_10927">I've tried on 1.6 and 2 problems encountered. </span></div><div id="yui_3_16_0_1_1438224649167_10827" dir="ltr"><span id="yui_3_16_0_1_1438224649167_10887">1. opts.manage_cgroups was set as CG_MODE_IGNORE.</span></div><div id="yui_3_16_0_1_1438224649167_10827" dir="ltr"><span id="yui_3_16_0_1_1438224649167_10928">2. After workaround above issue, migration still failed for same cause.</span></div><div id="yui_3_16_0_1_1438224649167_10827" dir="ltr"><span>Log attached.</span></div><div id="yui_3_16_0_1_1438224649167_10827" dir="ltr"><span><br></span></div><div id="yui_3_16_0_1_1438224649167_10827" dir="ltr"><span>Best Regards</span></div><div id="yui_3_16_0_1_1438224649167_10827" dir="ltr"><span>Zhang Fan</span></div><br> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;" id="yui_3_16_0_1_1438224649167_10832"> <div style="font-family: HelveticaNeue, Helvetica Neue, Helvetica, Arial, Lucida Grande, sans-serif; font-size: 16px;" id="yui_3_16_0_1_1438224649167_10831"> <div dir="ltr" id="yui_3_16_0_1_1438224649167_10830"> <hr size="1" id="yui_3_16_0_1_1438224649167_11004"> <font size="2" face="Arial" id="yui_3_16_0_1_1438224649167_10835"> <b id="yui_3_16_0_1_1438224649167_10834"><span style="font-weight:bold;" id="yui_3_16_0_1_1438224649167_10833">From:</span></b> Cyrill Gorcunov <gorcunov@gmail.com><br> <b><span style="font-weight: bold;">To:</span></b> Z F <full015zf@yahoo.com> <br><b><span style="font-weight: bold;">Cc:</span></b> "criu@openvz.org" <criu@openvz.org> <br> <b><span style="font-weight: bold;">Sent:</span></b> Friday, July 24, 2015 4:41 PM<br> <b><span style="font-weight: bold;">Subject:</span></b> Re: [CRIU] Fw: Restore Error in Cgroup Systemd<br> </font> </div> <div class="y_msg_container" id="yui_3_16_0_1_1438224649167_10860"><br>On Thu, Jul 23, 2015 at 06:46:34AM +0000, Z F wrote:<div class="qtdSeparateBR"><br><br></div><div class="yqt9573374367" id="yqtfd20685"><br clear="none">> <br clear="none">> Hi,<br clear="none">> <br clear="none">> I am trying migrating a simple shell job between hosts and failed in<br clear="none">> restore as:<br clear="none">> <br clear="none">> (00.042759) 38289: Error (cgroup.c:908): cg: Can't move into<br clear="none">> systemd//user.slice/user-0.slice/session-741.scope/tasks (-1/-1): No such<br clear="none">> file or directory<br clear="none">> (00.043022) Error (cr-restore.c:1193): 38289 exited, status=1<br clear="none">> (00.044078) Error (cr-restore.c:1867): Restoring FAILED.<br clear="none">> <br clear="none">> The environments:<br clear="none">> [<a shape="rect" ymailto="mailto:root@compute1" href="mailto:root@compute1">root@compute1</a> criu-br-1.5-stable]# uname -a<br clear="none">> Linux compute1 3.12.44 #1 SMP Mon Jul 20 09:16:11 CST 2015 x86_64 x86_64<br clear="none">> x86_64 GNU/Linux<br clear="none">> [<a shape="rect" ymailto="mailto:root@compute1" href="mailto:root@compute1">root@compute1</a> criu-br-1.5-stable]# ./criu -V<br clear="none">> Version: 1.5.2<br clear="none">> [<a shape="rect" ymailto="mailto:root@compute1" href="mailto:root@compute1">root@compute1</a> criu-br-1.5-stable]# ./criu restore --images-dir<br clear="none">> /mnt/nfs/home/zf/criutest/dumps/ --shell-job -v4 <br clear="none">> Restore log attached.<br clear="none">> <br clear="none">> The cause is that for each session in the system a directory created as<br clear="none">> /sys/fs/cgroup/system/user.slice/user-x.slice/session-y.scope/. While the<br clear="none">> source and destination have different sessions.<br clear="none">> <br clear="none">> Would you please help to solve the problem? Thank you very much.</div><br clear="none"><br clear="none">Please switch to criu 1.6 at least, there were a number of fixes for<br clear="none">cgroups code. To migrate between systemd based nodes you need to prepare<br clear="none">special slice for systemd on source node. See our vzctl tool which<br clear="none">does such thing (<a shape="rect" href="https://src.openvz.org/projects/OVZ/repos/vzctl/browse" target="_blank">https://src.openvz.org/projects/OVZ/repos/vzctl/browse</a>)<br clear="none">In short you need to prepare own slice for your container/application<br clear="none">to be able to migrate it.<div class="yqt9573374367" id="yqtfd63064"><br clear="none"></div><br><br></div> </div> </div> </div></body></html>