You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@storm.apache.org by "Robert Joseph Evans (JIRA)" <ji...@apache.org> on 2017/02/27 16:05:45 UTC
[jira] [Resolved] (STORM-2333) CGroup Metrics
[ https://issues.apache.org/jira/browse/STORM-2333?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Robert Joseph Evans resolved STORM-2333.
----------------------------------------
Resolution: Fixed
Fix Version/s: 2.0.0
Merged this into master
> CGroup Metrics
> --------------
>
> Key: STORM-2333
> URL: https://issues.apache.org/jira/browse/STORM-2333
> Project: Apache Storm
> Issue Type: Improvement
> Components: storm-core
> Reporter: Robert Joseph Evans
> Assignee: Robert Joseph Evans
> Fix For: 2.0.0
>
> Time Spent: 4h 20m
> Remaining Estimate: 0h
>
> Now that we have isolation through cgroups it would be really nice if we could also do some monitoring of various usage metrics from the cgroups.
> For the most part this looks like reading some special files if they exist.
> We should be able to read /proc/self/cgroup to see which cgroup we are a part of (or if we are in a CGroup). And then read in the config about where the CGroup is mounted storm.cgroup.hierarchy.dir
> After that we can read
> https://lwn.net/Articles/529927/
> memory.usage_in_bytes - current usage in bytes
> memory.limit_in_bytes - current limit in bytes
> https://kernel.googlesource.com/pub/scm/linux/kernel/git/glommer/memcg/+/cpu_stat/Documentation/cgroups/cpu.txt
> cpuacct.usage - The aggregate CPU time, in nanoseconds, consumed by all tasks in this group.
> OR cpuacct.stat - aggregate user and system time consumed by tasks in this group.
> The format is
> user: x
> system: y
> NOTE: cpuacct does not need to be mounted for cgroup support to work, so if those files don't exist don't register the metric (or just don't report anything).
--
This message was sent by Atlassian JIRA
(v6.3.15#6346)