Hi Weng,

On Thu, Oct 24, 2013 at 10:58 PM, Dhaval Giani <dhaval.gi...@gmail.com> wrote:
> On Thu, Oct 24, 2013 at 10:52 PM, Weng Meiling
> <wengmeiling.w...@huawei.com> wrote:
>> On 2013/10/24 21:04, Dhaval Giani wrote:
>>> On Thu, Oct 24, 2013 at 3:50 AM, Weng Meiling
>>> <wengmeiling.w...@huawei.com> wrote:
>>>> On 2013/10/24 1:04, Dhaval Giani wrote:
>>>>> Hi Weng,
>>>>>
>>>>> Would something similar to the attached patch help you? This of course
>>>>> is completely untested (it seems to build).
>>>>>
>>>>> Ideally the list I have made would be setup better, and extensible,
>>>>> and we just track the dependencies there for specific controllers.
>>>>> That way we are limiting the churn needed. (And probably prefer using
>>>>> something better than bubble sort :P)
>>>>>
>>>>> Thanks!
>>>>> Dhaval
>>>>>
>>>>
>>>> Hi Dhaval,
>>>>
>>>> Thanks for your patch! But there is a little problem when I test
>>>> the patch, cgconfigparser command report "Segmentation fault".
>>>> It seems caused by the following code:
>>>>
>>>
>>> Heh :-). I am not surprised. I was more interested in hearing your
>>> comments on if you think something like this would fix your problem? I
>>> will respin a tested version later this evening and post it.
>>>
>>> thanks!
>>> Dhaval
>>>
>>>
>> This patch can fix my problem :-), thanks!
>>
>> With more test, the same problem will occur when using cgset --copy-from.
>>
>> This is example:
>>
>> # cgget -r memory.limit_in_bytes -r memory.memsw.limit_in_bytes test1
>> test1:
>> memory.limit_in_bytes: 3145728
>> memory.memsw.limit_in_bytes: 4194304
>>
>> # cgget -r memory.limit_in_bytes -r memory.memsw.limit_in_bytes test2
>> test2:
>> memory.limit_in_bytes: 18446744073709551615
>> memory.memsw.limit_in_bytes: 18446744073709551615
>>
>> # cgset --copy-from test1 test2
>>
>> # cgget -r memory.limit_in_bytes -r memory.memsw.limit_in_bytes test2
>> test2:
>> memory.limit_in_bytes: 3145728
>> memory.memsw.limit_in_bytes: 18446744073709551615
>>
>>
>> The memory.memsw.limit_in_bytes of test2 can't be copied by cgset 
>> --copy-from,
>> but memory.limit_in_bytes can. What do you think about this behavior? Is it
>> also a problem?
>
> We will have to fixup modify_cgroup to sort the cgroup struct. But it
> would be just one more line there I imagine.
>

I apologize for not sending a patch earlier. Does this patch fix all
your issues?

Thanks!
Dhaval
------------------------------------------------------------------------------
November Webinars for C, C++, Fortran Developers
Accelerate application performance with scalable programming models. Explore
techniques for threading, error checking, porting, and tuning. Get the most 
from the latest Intel processors and coprocessors. See abstracts and register
http://pubads.g.doubleclick.net/gampad/clk?id=60136231&iu=/4140/ostg.clktrk
_______________________________________________
Libcg-devel mailing list
Libcg-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/libcg-devel

Reply via email to