Maintain Platform App - app-power-metrics

Fixed spaces and formatting
Updated Patchset 1 comments
Story: 2011065
Task: 50262

Change-Id: Id5d1f2e8d9f36fd2dbb7def72f816e6d673f23c1
Signed-off-by: Juanita Balaraj <juanita.balaraj@windriver.com>
This commit is contained in:
Juanita Balaraj
2024-06-04 15:58:38 +00:00
parent f8daad8b39
commit 6430c50b51

View File

@@ -1,8 +1,8 @@
.. _install-power-metrics-application-a12de3db7478: .. _install-power-metrics-application-a12de3db7478:
====================================================== =================================
Technology Preview - Install Power Metrics Application Install Power Metrics Application
====================================================== =================================
The Power Metrics app deploys two containers, cAdvisor and Telegraf that The Power Metrics app deploys two containers, cAdvisor and Telegraf that
collect metrics about hardware usage. This document describes the technical collect metrics about hardware usage. This document describes the technical
@@ -76,7 +76,7 @@ Source: https://github.com/influxdata/telegraf/issues/13098#issuecomment-1512585
[sysadmin@controller-0 (keystone_admin)]$ system application-show power-metrics [sysadmin@controller-0 (keystone_admin)]$ system application-show power-metrics
#. Assign a label to the node: #. Assign a label to the node.
.. note:: .. note::
@@ -103,7 +103,7 @@ be up and running.
cadvisor-v76zx 1/1 Running 0 26h cadvisor-v76zx 1/1 Running 0 26h
telegraf-mc6vd 1/1 Running 0 4d7h telegraf-mc6vd 1/1 Running 0 4d7h
It is possible to change some configurations via override. It is possible to change some configurations via overrides.
-------- --------
Telegraf Telegraf
@@ -112,7 +112,7 @@ Telegraf
Enable and disable Intel PMU metrics Enable and disable Intel PMU metrics
------------------------------------ ------------------------------------
You can activate the Intel PMU plugin with the following command: You can activate the Intel |PMU| plugin with the following command:
.. code-block:: none .. code-block:: none
@@ -158,12 +158,14 @@ Example of overriding the powerstat plugin:
[sysadmin@controller-0 ~(keystone_admin)]$ cat telegraf-powerstat.yaml [sysadmin@controller-0 ~(keystone_admin)]$ cat telegraf-powerstat.yaml
config: config:
intel_powerstat: inputs:
read_method: "sequential" intel_powerstat:
cpu_metrics: ["cpu_frequency","cpu_busy_frequency","cpu_temperature","cpu_c0_state_residency","cpu_c1_state_residency","cpu_c6_state_residency","cpu_busy_cycles"] read_method: "sequential"
package_metrics: ["current_power_consumption","current_dram_power_consumption","thermal_design_power","cpu_base_frequency"] cpu_metrics: ["cpu_frequency","cpu_busy_frequency","cpu_temperature","cpu_c0_state_residency","cpu_c1_state_residency","cpu_c6_state_residency","cpu_busy_cycles"]
package_metrics: ["current_power_consumption","current_dram_power_consumption","thermal_design_power","cpu_base_frequency"]
[sysadmin@controller-0 ~(keystone_admin)]$ system helm-override-update power-metrics telegraf power-metrics --values telegraf-powerstat.yaml [sysadmin@controller-0 ~(keystone_admin)]$ system helm-override-update power-metrics telegraf power-metrics --values telegraf-powerstat.yaml
+----------------+--------------------------------------+ +----------------+--------------------------------------+
| Property | Value | | Property | Value |
+----------------+--------------------------------------+ +----------------+--------------------------------------+
@@ -188,7 +190,7 @@ Example of overriding the powerstat plugin:
| | | | | |
+----------------+--------------------------------------+ +----------------+--------------------------------------+
Then, you can re-apply the app: Re-apply the app.
.. code-block:: none .. code-block:: none
@@ -200,7 +202,7 @@ Add input plugins
You can add new plugins overriding the plugins column. You can add new plugins overriding the plugins column.
#. Add the cgroups plugin: #. Add the cgroups plugin.
.. code-block:: none .. code-block:: none
@@ -211,7 +213,7 @@ You can add new plugins overriding the plugins column.
paths: ["/sys/fs/cgroup/cpu","/sys/fs/cgroup/cpu/*","/sys/fs/cgroup/cpu/*/*",] paths: ["/sys/fs/cgroup/cpu","/sys/fs/cgroup/cpu/*","/sys/fs/cgroup/cpu/*/*",]
files: ["cpuacct.usage", "cpuacct.usage_percpu", "cpu.cfs_period_us", "cpu.cfs_quota_us", "cpu.shares", "cpu.stat"] files: ["cpuacct.usage", "cpuacct.usage_percpu", "cpu.cfs_period_us", "cpu.cfs_quota_us", "cpu.shares", "cpu.stat"]
#. Then apply the override: #. Apply the override.
.. code-block:: none .. code-block:: none
@@ -239,13 +241,13 @@ You can add new plugins overriding the plugins column.
| | | | | |
+----------------+--------------------------------+ +----------------+--------------------------------+
#. After you can re-apply the app: #. Re-apply the application.
.. code-block:: none .. code-block:: none
[sysadmin@controller-0 ~(keystone_admin)]$ system application-apply power-metrics [sysadmin@controller-0 ~(keystone_admin)]$ system application-apply power-metrics
#. If needed, add configmap and volumes via override: #. If required, add configmap and volumes via override.
.. code-block:: none .. code-block:: none
@@ -266,6 +268,43 @@ For more information on Telegraf plugins, see
https://github.com/influxdata/telegraf#documentation. https://github.com/influxdata/telegraf#documentation.
Remove input plugins
--------------------
You can remove plugins by setting their value to false in the plugins column.
#. Remove the cgroups plugin.
.. code-block:: none
[sysadmin@controller-0 ~(keystone_admin)]$ cat telegraf-cgroups.yaml
config:
inputs:
- cgroup: false
#. Apply the override.
.. code-block:: none
[sysadmin@controller-0 ~(keystone_admin)]$ system helm-override-update power-metrics telegraf power-metrics --values ./telegraf-cgroups.yaml
+----------------+-------------------+
| Property | Value |
+----------------+-------------------+
| name | telegraf |
| namespace | power-metrics |
| user_overrides | config: |
| | inputs: |
| | - cgroup: false |
| | |
+----------------+-------------------+
#. Re-apply the application.
.. code-block:: none
[sysadmin@controller-0 ~(keystone_admin)]$ system application-apply power-metrics
Modify Telegraf data collection interval Modify Telegraf data collection interval
---------------------------------------- ----------------------------------------
@@ -297,7 +336,7 @@ To enable or disable Perf Events on cAdvisor, use the following command:
| | | | | |
+----------------+-------------------+ +----------------+-------------------+
After that, reapply the power-metrics app, and wait until the pod restarts: Finally, re-apply the power-metrics app, and wait until the pod restarts.
.. code-block:: none .. code-block:: none