Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[RFE] pcp dstat utility configurable filtering #2017

Open
natoscott opened this issue Jul 12, 2024 · 0 comments
Open

[RFE] pcp dstat utility configurable filtering #2017

natoscott opened this issue Jul 12, 2024 · 0 comments
Assignees

Comments

@natoscott
Copy link
Member

Issue #2016 describes a problem where root cause is the way pcp-dstat.py has hard-coded mappings between instance filtering command line options and the specific plugins they apply to.

A cleaner solution would allow the plugin configuration files to specify this mapping. That way, as new config files are added (in PCP or by the user locally), the python code does not need to be changed to add the plugin names.

For example, the disk-util plugin from /etc/pcp/dstat/disk might gain a filter mapping specification something like:

[disk-util]
label = %I
width = 4
**filtertype = disk**
grouptype = 1
printtype = f
colorstep = 34
util = 100 * rate(disk.dev.avactive)

These are the all of the relevant command line options that provide "filtertype" values:

  -c, --cpu             enable cpu stats
     -C 0,3,total          include cpu0, cpu3 and total
  -d, --disk            enable disk stats
     -D total,sda          include sda and total
  --dm, --device-mapper enable device mapper stats
     -L root,home,total    include root, home and total
  --md, --multi-device  enable multi-device driver stats
     -M total,md-0         include md-0 and total
  --part, --partition   enable disk partition stats
     -P total,sdb2         include sdb2 and total
  -i, --int             enable interrupt stats
     -I 9,CAL              include int9 and function call interrupts
  -n, --net             enable network stats
     -N eth1,total         include eth1 and total
  -s, --swap            enable swap stats
     -S swap1,total        include swap1 and total
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants