Also, can you explain a bit more on what your "tasks" are? Since tasks are
essentially units of work, it seems odd that you want to have tasks that do
not take up any cpu/mem. If a task is a unix process, it has to use some
cpu/mem.


On Thu, Aug 29, 2013 at 8:09 PM, Benjamin Mahler
<[email protected]>wrote:

> Does that mean your framework only works correctly with slaves using
> process isolation? With the technique you mentioned, the tasks will get
> very little cpu when cgroups isolation is running on the slave. Perhaps it
> would be better to choose some sensible defaults for cpu and memory?
>
>
> On Thu, Aug 29, 2013 at 2:51 PM, Li Jin <[email protected]> wrote:
>
>> I see. Things are easier when the users can always specify cpu and mem.
>> However, one use case I would like to support in my framework is to allow
>> users to not specify cpu and mem, and just use the process isolation. I am
>> wondering if this is a supported use case. One way to make it work now is
>> to use somethig like cpu=0.00001 but that feels pretty hacky.
>>
>> Li
>>
>>
>> On Thu, Aug 29, 2013 at 5:13 PM, Benjamin Hindman <
>> [email protected]> wrote:
>>
>>> Resources like cpu and memory are "grandfathered in" as first-class
>>> resources. We won't be adding any other resource values like that unless
>>> the community felt otherwise. Instead, as we add new resources we'll have
>>> sensible defaults so your framework won't break by you might not get the
>>> performance you want unless you explicitly set the resource value yourself.
>>> But this should at least give you a sensible path to upgrade your framework!
>>>
>>>
>>> On Thu, Aug 29, 2013 at 1:47 PM, Li Jin <[email protected]> wrote:
>>>
>>>> Ben,
>>>>
>>>> Thanks for the reply. So my understanding is if some isolation module
>>>> (in this case cgroups) needs certain resource values to be specified, I
>>>> would need to specify those even if I am using a different isolation
>>>> module, is that right? I am a bit worried that future releases might
>>>> require other resource values to be specified that would break my 
>>>> framework.
>>>>
>>>> Li
>>>>
>>>>
>>>> On Thu, Aug 29, 2013 at 3:10 PM, Benjamin Hindman <
>>>> [email protected]> wrote:
>>>>
>>>>> When we attempt to isolate the resources via control groups on Linux
>>>>> we need at least some value. That being said, isolation is coarser grained
>>>>> than what you can specify with a double, and 0.0001 gets rounded to a
>>>>> different value (via cpu shares). I could imagine doing validation on cpu
>>>>> resources to not allow something below the granularity that we can 
>>>>> actually
>>>>> isolate. How does that sound?
>>>>>
>>>>>
>>>>> On Thu, Aug 29, 2013 at 8:58 AM, Li Jin <[email protected]> wrote:
>>>>>
>>>>>> Hello guys,
>>>>>>
>>>>>> I have observed this behavior:
>>>>>>
>>>>>> (1) If I launchTasks with a task with no resource spec, mesos says
>>>>>> "Error validating task 6901953 : Task uses no resources"
>>>>>> (2) If I launchTasks with a task with cpu=0.00001 and no other
>>>>>> resource spec, mesos launches the task
>>>>>>
>>>>>> These two seem to be practically the same, I am wondering what's the
>>>>>> rationale to have different behavior for these two cases.
>>>>>>
>>>>>> Thanks,
>>>>>> Li
>>>>>>
>>>>>
>>>>>
>>>>
>>>
>>
>

Reply via email to