Skip to content
This repository has been archived by the owner on Apr 12, 2022. It is now read-only.

Commit

Permalink
Overrides cgroup path
Browse files Browse the repository at this point in the history
The virtual file /proc/self/cgroup should list the current cgroup
membership. For each hierarchy, you can follow the cgroup path from
this file to the cgroup filesystem (usually /sys/fs/cgroup/) and
introspect the statistics for the cgroup for the given
hierarchy. Alas, Docker breaks this by mounting the container
statistics at the root while leaving the cgroup paths as the actual
paths. Therefore, Kibana provides a mechanism to override
reading the cgroup path from /proc/self/cgroup and instead uses the
cgroup path defined the configuration properties
cpu.cgroup.path.override and cpuacct.cgroup.path.override.
Therefore, we set this value here so that cgroup statistics are
available for the container this process will run in.

Signed-off-by: Tyler Smalley <[email protected]>
  • Loading branch information
Tyler Smalley authored and Toby McLaughlin committed May 2, 2017
1 parent 39c7fa5 commit 63113fd
Showing 1 changed file with 14 additions and 1 deletion.
15 changes: 14 additions & 1 deletion build/kibana/bin/kibana-docker
Original file line number Diff line number Diff line change
Expand Up @@ -120,4 +120,17 @@ for kibana_var in ${kibana_vars[*]}; do
fi
done

exec /usr/share/kibana/bin/kibana ${longopts}
# The virtual file /proc/self/cgroup should list the current cgroup
# membership. For each hierarchy, you can follow the cgroup path from
# this file to the cgroup filesystem (usually /sys/fs/cgroup/) and
# introspect the statistics for the cgroup for the given
# hierarchy. Alas, Docker breaks this by mounting the container
# statistics at the root while leaving the cgroup paths as the actual
# paths. Therefore, Kibana provides a mechanism to override
# reading the cgroup path from /proc/self/cgroup and instead uses the
# cgroup path defined the configuration properties
# cpu.cgroup.path.override and cpuacct.cgroup.path.override.
# Therefore, we set this value here so that cgroup statistics are
# available for the container this process will run in.

exec /usr/share/kibana/bin/kibana --cpu.cgroup.path.override=/ --cpuacct.cgroup.path.override=/ ${longopts}

0 comments on commit 63113fd

Please sign in to comment.