You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mesos.apache.org by David Mackey <td...@booleanhaiku.com> on 2013/03/01 22:16:46 UTC

Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/
-----------------------------------------------------------

(Updated March 1, 2013, 9:16 p.m.)


Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.


Changes
-------

Converted to flag based enablement per comments.


Description
-------

Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.

CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.

There are 4 approaches one could take:
1) Use the CFS bandwidth limiting if the feature is present
2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
4) Add an additional control flag via some other means

Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.

This diff takes option 1. 


This addresses bug MESOS-315.
    https://issues.apache.org/jira/browse/MESOS-315


Diffs (updated)
-----

  src/slave/cgroups_isolation_module.hpp a04fc46 
  src/slave/cgroups_isolation_module.cpp a779de8 
  src/slave/flags.hpp d4aa045 

Diff: https://reviews.apache.org/r/9464/diff/


Testing
-------

make check + additional testing


Thanks,

David Mackey


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by Ben Mahler <be...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/#review17279
-----------------------------------------------------------


Can you resolve or drop the issues brought up in vinod and my reviews?

- Ben Mahler


On March 1, 2013, 9:24 p.m., David Mackey wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/9464/
> -----------------------------------------------------------
> 
> (Updated March 1, 2013, 9:24 p.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.
> 
> 
> Description
> -------
> 
> Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.
> 
> CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.
> 
> There are 4 approaches one could take:
> 1) Use the CFS bandwidth limiting if the feature is present
> 2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
> 3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
> 4) Add an additional control flag via some other means
> 
> Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
> Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.
> 
> This diff takes option 1. 
> 
> 
> This addresses bug MESOS-315.
>     https://issues.apache.org/jira/browse/MESOS-315
> 
> 
> Diffs
> -----
> 
>   src/slave/cgroups_isolation_module.hpp a04fc46 
>   src/slave/cgroups_isolation_module.cpp a779de8 
>   src/slave/flags.hpp d4aa045 
> 
> Diff: https://reviews.apache.org/r/9464/diff/
> 
> 
> Testing
> -------
> 
> make check + additional testing
> 
> 
> Thanks,
> 
> David Mackey
> 
>


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by Vinod Kone <vi...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/#review17274
-----------------------------------------------------------



src/slave/cgroups_isolation_module.cpp
<https://reviews.apache.org/r/9464/#comment36738>

    period at the end.



src/slave/cgroups_isolation_module.cpp
<https://reviews.apache.org/r/9464/#comment36739>

    s/, your/. Your/ ?



src/slave/cgroups_isolation_module.cpp
<https://reviews.apache.org/r/9464/#comment36740>

    quotes around cfsChanged.



src/slave/cgroups_isolation_module.cpp
<https://reviews.apache.org/r/9464/#comment36743>

    Considering mesos is responsible for manipulating resources, this should be a CHECK.



src/slave/cgroups_isolation_module.cpp
<https://reviews.apache.org/r/9464/#comment36744>

    Move these down to where they are used (line #815)


- Vinod Kone


On March 1, 2013, 9:24 p.m., David Mackey wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/9464/
> -----------------------------------------------------------
> 
> (Updated March 1, 2013, 9:24 p.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.
> 
> 
> Description
> -------
> 
> Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.
> 
> CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.
> 
> There are 4 approaches one could take:
> 1) Use the CFS bandwidth limiting if the feature is present
> 2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
> 3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
> 4) Add an additional control flag via some other means
> 
> Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
> Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.
> 
> This diff takes option 1. 
> 
> 
> This addresses bug MESOS-315.
>     https://issues.apache.org/jira/browse/MESOS-315
> 
> 
> Diffs
> -----
> 
>   src/slave/cgroups_isolation_module.hpp a04fc46 
>   src/slave/cgroups_isolation_module.cpp a779de8 
>   src/slave/flags.hpp d4aa045 
> 
> Diff: https://reviews.apache.org/r/9464/diff/
> 
> 
> Testing
> -------
> 
> make check + additional testing
> 
> 
> Thanks,
> 
> David Mackey
> 
>


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by David Mackey <td...@booleanhaiku.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/#review17289
-----------------------------------------------------------



src/slave/cgroups_isolation_module.cpp
<https://reviews.apache.org/r/9464/#comment36756>

    I replicated this comment from the subsystems loop as it applied here, but given that there's only one object in the list and that I left it assigned it to benh instead of myself I removed it. I'll re-add it.


- David Mackey


On March 2, 2013, 12:13 a.m., David Mackey wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/9464/
> -----------------------------------------------------------
> 
> (Updated March 2, 2013, 12:13 a.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.
> 
> 
> Description
> -------
> 
> Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.
> 
> CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.
> 
> There are 4 approaches one could take:
> 1) Use the CFS bandwidth limiting if the feature is present
> 2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
> 3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
> 4) Add an additional control flag via some other means
> 
> Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
> Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.
> 
> This diff takes option 1. 
> 
> 
> This addresses bug MESOS-315.
>     https://issues.apache.org/jira/browse/MESOS-315
> 
> 
> Diffs
> -----
> 
>   src/slave/cgroups_isolation_module.hpp a04fc46 
>   src/slave/cgroups_isolation_module.cpp a779de8 
>   src/slave/flags.hpp d4aa045 
> 
> Diff: https://reviews.apache.org/r/9464/diff/
> 
> 
> Testing
> -------
> 
> make check + additional testing
> 
> 
> Thanks,
> 
> David Mackey
> 
>


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by David Mackey <td...@booleanhaiku.com>.

> On March 2, 2013, 12:16 a.m., Vinod Kone wrote:
> > src/slave/cgroups_isolation_module.cpp, lines 243-244
> > <https://reviews.apache.org/r/9464/diff/4-5/?file=264295#file264295line243>
> >
> >     Why did you remove this?

I replicated this comment from the subsystems loop as it applied here, but given that there's only one object in the list and that I left it assigned it to benh instead of myself I removed it. I'll re-add it.


- David


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/#review17284
-----------------------------------------------------------


On March 2, 2013, 12:13 a.m., David Mackey wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/9464/
> -----------------------------------------------------------
> 
> (Updated March 2, 2013, 12:13 a.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.
> 
> 
> Description
> -------
> 
> Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.
> 
> CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.
> 
> There are 4 approaches one could take:
> 1) Use the CFS bandwidth limiting if the feature is present
> 2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
> 3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
> 4) Add an additional control flag via some other means
> 
> Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
> Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.
> 
> This diff takes option 1. 
> 
> 
> This addresses bug MESOS-315.
>     https://issues.apache.org/jira/browse/MESOS-315
> 
> 
> Diffs
> -----
> 
>   src/slave/cgroups_isolation_module.hpp a04fc46 
>   src/slave/cgroups_isolation_module.cpp a779de8 
>   src/slave/flags.hpp d4aa045 
> 
> Diff: https://reviews.apache.org/r/9464/diff/
> 
> 
> Testing
> -------
> 
> make check + additional testing
> 
> 
> Thanks,
> 
> David Mackey
> 
>


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by Vinod Kone <vi...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/#review17284
-----------------------------------------------------------

Ship it!



src/slave/cgroups_isolation_module.cpp
<https://reviews.apache.org/r/9464/#comment36753>

    Why did you remove this?


- Vinod Kone


On March 2, 2013, 12:13 a.m., David Mackey wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/9464/
> -----------------------------------------------------------
> 
> (Updated March 2, 2013, 12:13 a.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.
> 
> 
> Description
> -------
> 
> Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.
> 
> CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.
> 
> There are 4 approaches one could take:
> 1) Use the CFS bandwidth limiting if the feature is present
> 2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
> 3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
> 4) Add an additional control flag via some other means
> 
> Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
> Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.
> 
> This diff takes option 1. 
> 
> 
> This addresses bug MESOS-315.
>     https://issues.apache.org/jira/browse/MESOS-315
> 
> 
> Diffs
> -----
> 
>   src/slave/cgroups_isolation_module.hpp a04fc46 
>   src/slave/cgroups_isolation_module.cpp a779de8 
>   src/slave/flags.hpp d4aa045 
> 
> Diff: https://reviews.apache.org/r/9464/diff/
> 
> 
> Testing
> -------
> 
> make check + additional testing
> 
> 
> Thanks,
> 
> David Mackey
> 
>


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by Ben Mahler <be...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/#review18412
-----------------------------------------------------------

Ship it!


Modulo comments below.


src/slave/cgroups_isolator.cpp
<https://reviews.apache.org/r/9464/#comment38611>

    Let's keep this consistent with other messages from initialize(), so:
    
    s/The/Your



src/slave/cgroups_isolator.cpp
<https://reviews.apache.org/r/9464/#comment38615>

    What is the "parent handler"? I think you can just say "Set the cpu shares as well" to be clear as to what the parent handler is doing.



src/slave/cgroups_isolator.cpp
<https://reviews.apache.org/r/9464/#comment38612>

    Does this need to be namespaced?



src/slave/flags.hpp
<https://reviews.apache.org/r/9464/#comment38613>

    s/ (cgroups_enable_cfs=true)//



src/slave/flags.hpp
<https://reviews.apache.org/r/9464/#comment38614>

    s/true/false
    
    We definitely don't want to enable by default initially.


- Ben Mahler


On March 26, 2013, 11:44 p.m., David Mackey wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/9464/
> -----------------------------------------------------------
> 
> (Updated March 26, 2013, 11:44 p.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.
> 
> 
> Description
> -------
> 
> Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.
> 
> CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.
> 
> There are 4 approaches one could take:
> 1) Use the CFS bandwidth limiting if the feature is present
> 2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
> 3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
> 4) Add an additional control flag via some other means
> 
> Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
> Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.
> 
> This diff takes option 1. 
> 
> 
> This addresses bug MESOS-315.
>     https://issues.apache.org/jira/browse/MESOS-315
> 
> 
> Diffs
> -----
> 
>   src/slave/cgroups_isolator.hpp 1732c4e 
>   src/slave/cgroups_isolator.cpp ebc2843 
>   src/slave/flags.hpp 95969ae 
>   third_party/libprocess/third_party/stout/include/stout/multihashmap.hpp a8feabd 
> 
> Diff: https://reviews.apache.org/r/9464/diff/
> 
> 
> Testing
> -------
> 
> make check + additional testing
> 
> 
> Thanks,
> 
> David Mackey
> 
>


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by David Mackey <td...@booleanhaiku.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/
-----------------------------------------------------------

(Updated March 27, 2013, 3:11 a.m.)


Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.


Changes
-------

Updated per comments.


Description
-------

Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.

CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.

There are 4 approaches one could take:
1) Use the CFS bandwidth limiting if the feature is present
2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
4) Add an additional control flag via some other means

Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.

This diff takes option 1. 


This addresses bug MESOS-315.
    https://issues.apache.org/jira/browse/MESOS-315


Diffs (updated)
-----

  src/slave/cgroups_isolator.hpp 1732c4e 
  src/slave/cgroups_isolator.cpp ebc2843 
  src/slave/flags.hpp 95969ae 
  third_party/libprocess/third_party/stout/include/stout/multihashmap.hpp a8feabd 

Diff: https://reviews.apache.org/r/9464/diff/


Testing
-------

make check + additional testing


Thanks,

David Mackey


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by David Mackey <td...@booleanhaiku.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/
-----------------------------------------------------------

(Updated March 26, 2013, 11:44 p.m.)


Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.


Changes
-------

Rebased off trunk and changed flag behavior to be an explicit flag instead of a "feature list." Nested handlers remain.


Description
-------

Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.

CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.

There are 4 approaches one could take:
1) Use the CFS bandwidth limiting if the feature is present
2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
4) Add an additional control flag via some other means

Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.

This diff takes option 1. 


This addresses bug MESOS-315.
    https://issues.apache.org/jira/browse/MESOS-315


Diffs (updated)
-----

  src/slave/cgroups_isolator.hpp 1732c4e 
  src/slave/cgroups_isolator.cpp ebc2843 
  src/slave/flags.hpp 95969ae 
  third_party/libprocess/third_party/stout/include/stout/multihashmap.hpp a8feabd 

Diff: https://reviews.apache.org/r/9464/diff/


Testing
-------

make check + additional testing


Thanks,

David Mackey


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by Ben Mahler <be...@gmail.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/#review17308
-----------------------------------------------------------


Getting close! A few high level comments:

1. I don't think we want to split the handlers, I thought it was cleaner when you were doing all the cpu handling inside cpusChanged(). With this change there are now two handlers and one uses the other. I think to keep things intuitive let's just place the logic inside cpusChanged and guard it with a check of the flag.

2. What else do you anticipate using this flag for? I would consider it to be a temporary measure until we can notify schedulers of the level of cpu isolation available. Hence wanting it to be something simple like --cgroups_enable_cfs. We will then be killing this flag when we make resources first class: https://issues.apache.org/jira/browse/MESOS-338.

- Ben Mahler


On March 2, 2013, 12:49 a.m., David Mackey wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/9464/
> -----------------------------------------------------------
> 
> (Updated March 2, 2013, 12:49 a.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.
> 
> 
> Description
> -------
> 
> Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.
> 
> CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.
> 
> There are 4 approaches one could take:
> 1) Use the CFS bandwidth limiting if the feature is present
> 2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
> 3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
> 4) Add an additional control flag via some other means
> 
> Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
> Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.
> 
> This diff takes option 1. 
> 
> 
> This addresses bug MESOS-315.
>     https://issues.apache.org/jira/browse/MESOS-315
> 
> 
> Diffs
> -----
> 
>   src/slave/cgroups_isolation_module.hpp a04fc46 
>   src/slave/cgroups_isolation_module.cpp a779de8 
>   src/slave/flags.hpp d4aa045 
> 
> Diff: https://reviews.apache.org/r/9464/diff/
> 
> 
> Testing
> -------
> 
> make check + additional testing
> 
> 
> Thanks,
> 
> David Mackey
> 
>


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by David Mackey <td...@booleanhaiku.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/
-----------------------------------------------------------

(Updated March 2, 2013, 12:49 a.m.)


Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.


Changes
-------

Re-add comment.


Description
-------

Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.

CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.

There are 4 approaches one could take:
1) Use the CFS bandwidth limiting if the feature is present
2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
4) Add an additional control flag via some other means

Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.

This diff takes option 1. 


This addresses bug MESOS-315.
    https://issues.apache.org/jira/browse/MESOS-315


Diffs (updated)
-----

  src/slave/cgroups_isolation_module.hpp a04fc46 
  src/slave/cgroups_isolation_module.cpp a779de8 
  src/slave/flags.hpp d4aa045 

Diff: https://reviews.apache.org/r/9464/diff/


Testing
-------

make check + additional testing


Thanks,

David Mackey


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by David Mackey <td...@booleanhaiku.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/
-----------------------------------------------------------

(Updated March 2, 2013, 12:13 a.m.)


Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.


Changes
-------

Vinod's comments


Description
-------

Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.

CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.

There are 4 approaches one could take:
1) Use the CFS bandwidth limiting if the feature is present
2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
4) Add an additional control flag via some other means

Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.

This diff takes option 1. 


This addresses bug MESOS-315.
    https://issues.apache.org/jira/browse/MESOS-315


Diffs (updated)
-----

  src/slave/cgroups_isolation_module.hpp a04fc46 
  src/slave/cgroups_isolation_module.cpp a779de8 
  src/slave/flags.hpp d4aa045 

Diff: https://reviews.apache.org/r/9464/diff/


Testing
-------

make check + additional testing


Thanks,

David Mackey


Re: Review Request: Initial support for CPU limits via CFS Bandwidth Control.

Posted by David Mackey <td...@booleanhaiku.com>.
-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/9464/
-----------------------------------------------------------

(Updated March 1, 2013, 9:24 p.m.)


Review request for mesos, Benjamin Hindman, Vinod Kone, and Ben Mahler.


Changes
-------

Latest revision.


Description
-------

Initial support for CPU "hard limits" via CFS Bandwidth Control in cgroups.

CFS is unique relative to existing Mesos cgroups support in that it is a "subfeature" of an already supported cgroups subsystem, cpu. Also, there are two "tunables" for configuring CFS bandwidth limiting.

There are 4 approaches one could take:
1) Use the CFS bandwidth limiting if the feature is present
2) Expose as separate flag, eg "cpu,cfs,memory,freezer"
3) Add feature flag support to subsystems via an additional delimiter, eg "cpu+cfs,memory,freezer". 
4) Add an additional control flag via some other means

Option 2's downside breaks the 1:1 mapping between cgroups subsystems and a cgroups resource flag.
Option 3's downside is it greatly increases complexity of parsing cgroups subsystem flags.

This diff takes option 1. 


This addresses bug MESOS-315.
    https://issues.apache.org/jira/browse/MESOS-315


Diffs (updated)
-----

  src/slave/cgroups_isolation_module.hpp a04fc46 
  src/slave/cgroups_isolation_module.cpp a779de8 
  src/slave/flags.hpp d4aa045 

Diff: https://reviews.apache.org/r/9464/diff/


Testing
-------

make check + additional testing


Thanks,

David Mackey