[CRIU] [PATCH] Fix restoring cgroup across hosts

Pavel Emelyanov xemul at parallels.com
Mon Aug 10 09:58:32 PDT 2015


On 08/10/2015 07:43 PM, Hui Kang wrote:
> 
> 
> On Mon, Aug 10, 2015 at 12:35 PM, Pavel Emelyanov <xemul at parallels.com <mailto:xemul at parallels.com>> wrote:
> 
>     On 08/10/2015 06:00 PM, Hui Kang wrote:
>     > The process to be restored may not have certain cgroup dir, e.g
>     > cpu/[PID]/cpu.shares. Currently restoring  will fail in closing
>     > the file. If this is the case, the fileno is -1 and we can ignore
>     > this and let the restore proceed.
> 
>     If the file is missing then the fopen() itself should return -1.
> 
> Hi, Pavel
> The file is not missing in the destination, e.g., cpu/cpu.shares. The open and write are
> successful, e.g., fileno returning 5. Only fclose return error. But if you check fileno(f) 
> after fclose, it returns -1. That's why I added the additional check for this.

I see, but this means, that we have actually failed to restore the cgroup property.
I would find out why write() fails, that's the real bug we have.

-- Pavel



More information about the CRIU mailing list