Github user HeartSaVioR commented on a diff in the pull request:

    https://github.com/apache/storm/pull/1054#discussion_r51072040
  
    --- Diff: documentation/cgroups_in_storm.md ---
    @@ -0,0 +1,61 @@
    +# CGroups in Storm
    +
    +CGroups are used by Storm to limit the resource usage of workers to 
guaratee fairness and QOS.  
    +
    +**Please note: CGroups is currently supported only on Linux platforms** 
    +
    +## Setup
    +
    +To use CGroups make sure to to install cgroups and configure cgroups 
correctly.  For more information about seting up and configuring, please visit:
    +
    
+https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Resource_Management_Guide/ch-Using_Control_Groups.html
    +
    +A sample/default cgconfig.conf file is supplied in the <stormroot>/conf 
directory.  The contents are as follows:
    +
    +```
    +mount {
    +   cpuset  = /cgroup/cpuset;
    +   cpu     = /cgroup/storm_resources;
    +   cpuacct = /cgroup/cpuacct;
    +   memory  = /cgroup/storm_resources;
    +   devices = /cgroup/devices;
    +   freezer = /cgroup/freezer;
    +   net_cls = /cgroup/net_cls;
    +   blkio   = /cgroup/blkio;
    +}
    +
    +group storm {
    +       perm {
    +               task {
    +                      uid = 500;
    +                      gid = 500;
    +               }
    +               admin {
    +                      uid = 500;
    +                      gid = 500;
    +               }
    +       }
    +       cpu {
    +       }
    +}
    +```
    +
    +# Settings Related To CGroups in Storm
    +
    +| Setting                       | Function                                 
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
                                                                           |
    
+|-------------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|
    +| cgroup.enable                 | This config is used to set whether or 
not cgroups will be used.  Set "true" to enable use of cgroups.  Set "false" to 
not use cgroups. When this config is set to false, unit tests related to 
cgroups will skipped. Default set to "false"                                    
                                                                                
                                                                                
                                                                                
     |
    +| cgroup.storm.hierarchy.dir    | The path to the cgroup hierarchy that 
storm will use.  Default set to "/cgroup/storm_resources"                       
                                                                                
                                                                                
                                                                                
                                                                                
                                                                              |
    +|     cgroup.storm.resources    | A list of subsystems that will be 
regulated by CGroups. Default set to cpu and memory                             
                                                                                
                                                                                
                                                                                
                                                                                
                                                                                
  |
    +| cgroup.supervisor.rootdir     | The root cgroup used by the supervisor.  
The path to the cgroup will be 
<cgroup.storm.hierarchy.dir>/<cgroup.supervisor.rootdir>.  Default set to 
"storm"                                                                         
                                                                                
                                                                                
                                                                                
                                                  |
    +| cgroup.cgexec.cmd             | Absolute path to the cgexec command used 
to launch workers within a cgroup. Default set to "/bin/cgexec"                 
                                                                                
                                                                                
                                                                                
                                                                                
                                                                           |
    +| cgroup.worker.memory.mb.limit | The memory limit in MB for each worker.  
This can be set on a per supervisor node basis.  This config is used to set the 
cgroup config memory.limit_in_bytes.  For more details about 
memory.limit_in_bytes, please visit:  
https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Resource_Management_Guide/sec-memory.html.
    Please note, if you are using the Resource Aware Scheduler, please do NOT 
set this config as this config will override the values calculated by the 
Resource Aware Scheduler |
    +| cgroup.worker.cpu.limit       | The cpu share for each worker. This can 
be set on a per supervisor node basis.  This config is used to set the cgroup 
config cpu.share. For more details about cpu.share, please visit:   
https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/6/html/Resource_Management_Guide/sec-cpu.html.
 Please note, if you are using the Resource Aware Scheduler, please do NOT set 
this config as this config will override the values calculated by the Resource 
Aware Scheduler.                                       |
    +
    +Since limiting CPU usuage via cpu.shares only limits the proportional CPU 
usage of a process, to limit the amout of CPU usage of all the worker processes 
on a supervisor node, please set the config supervisor.cpu.capacity. Where each 
increment represents 1% of a core thus if a user sets supervisor.cpu.capacity: 
200, the user is indicating the use of 2 cores.
    --- End diff --
    
    usuage -> usage


---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at [email protected] or file a JIRA ticket
with INFRA.
---

Reply via email to