[CRIU] [PATCH] restore: Allow to ignore resource limits from image

Pavel Emelyanov xemul at parallels.com
Tue Jul 2 08:08:07 EDT 2013


On 07/02/2013 04:03 PM, Cyrill Gorcunov wrote:
> On Tue, Jul 02, 2013 at 03:58:58PM +0400, Pavel Emelyanov wrote:
>> On 07/02/2013 03:52 PM, Cyrill Gorcunov wrote:
>>> On Tue, Jul 02, 2013 at 03:51:36PM +0400, Pavel Emelyanov wrote:
>>>>
>>>> So, your only problem is RLIM_NLIMITS is 15 in your setup?
>>>
>>> Exactly
>>>
>>
>> Why not use openvz kernel headers with 16?
> 
> Again, you miss the point -- this RLIM_NLIMITS comes into criu source
> code not from kernel headers but from libc headers. So even if I install
> headers from latest vanilla kernel the program still see old value = 15.
> 
> Thus what I think we should do -- provide own reasource.h in include/asm-generic,
> where define CR_RLIM_NLIMITS = 16 and use it instead. Also we will use
> 
> 	BUILD_BUG_ON (CR_RLIM_NLIMITS < RLIM_NLIMITS);
> 
> thus if someday libc increas this value to 17 or something -- we will note
> this immediately and update our code as well.
> 
> Sounds good?
> .
> 

If this means declaring the task_args->rlims array to be CR_MAX_RLIMS == 16
elements size and trying to restore all the rlims, that came from image, then
yes.


More information about the CRIU mailing list