You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If the indexes have defined meaning like in this case, the values can be mapped to multiple metrics by appending the mapping to the --collector.sysctl.include flag:
Using --collector.sysctl.include=net.ipv4.tcp_rmem:min,default,max the collector will expose:
No string sysctl multi values seem to have well defined indexes, so mapping multiple string values to individual metric isn't something we need to support. We might consider it for future proving though.
The text was updated successfully, but these errors were encountered:
@discordianfish by generic you mean we should read a file or somehow rely on procfs?
So if user provided --collector.sysctl.include=vm.user_reserve_kbytes we should open and read /proc/sys/vm/user_reserve_kbytes, or we should somehow take it from procfs?
We should implement a sysctl collector to expose arbitrary sysctl values. For that we need to support the following types of sysctl variables:
Numeric values
Number values get exposed as metric value. The user selects them by using the
--collector.sysctl.include
flag.single values
Using
--collector.sysctl.include=vm.user_reserve_kbytes
:vm.user_reserve_kbytes = 131072
->node_sysctl_vm_user_reserve_kbytes 131072
multiple values
A sysctl can contain multiple values, for example:
Using
--collector.sysctl.include=net.ipv4.tcp_rmem
the collector will expose:If the indexes have defined meaning like in this case, the values can be mapped to multiple metrics by appending the mapping to the --collector.sysctl.include flag:
Using
--collector.sysctl.include=net.ipv4.tcp_rmem:min,default,max
the collector will expose:String Values
String values need to be exposed as info metric. The user selects them by using the
--collector.sysctl.include-info
flag.single values
kernel.core_pattern = core
->node_sysctl_info{key="kernel.core_pattern_info", value="core"} 1
multiple values
Given the following sysctl:
Setting
--collector.sysctl.include-info=kernel.seccomp.actions_avail
will yield:No string sysctl multi values seem to have well defined indexes, so mapping multiple string values to individual metric isn't something we need to support. We might consider it for future proving though.
The text was updated successfully, but these errors were encountered: