Plugin:Intel PMU/tests
From collectd Wiki
This page contains tests instructions for the Intel_PMU plugin. This page is meant to aid in testing at release time and be a guide for developing automated tests. Please add any tests that you have run when testing this plugin.
OPNFV Barometer
These tests are specified by the high level design guide in Barometer. They are run manually.
Summary | collectd.conf | Steps | Results | |
---|---|---|---|---|
1 | Verify intel_pmu compilation is skipped and collectd is successfully compiled and installed when jevents is installed without cFPIC flag | n/a |
cd jevents make make install
./build.sh ./configure --enable-syslog --enable-logfile --prefix=/root/orest/install --enable-debug make make install
|
Collectd compilation fails and intel_pmu plugin compilation is not skipped. |
2 | Verify intel_pmu compilation is not skipped and collectd is successfully compiled and installed when jevents is installed with cFPIC flag - | n/a |
cd jevents make CFLAGS+='-fPIC' make install CFLAGS+='-fPIC'
./build.sh ./configure --enable-syslog --enable-logfile --prefix=/root/orest/install --enable-debug make make install
|
Collectd installation is completed and intel_pmu is compiled successfully. |
3 | Verify only HWCacheEvents is collected when related field is set to True. |
<Plugin intel_pmu> HWCacheEvents true KernelPMUEvents false SWEvents false </Plugin> |
|
HWCacheEvents are collected. |
4 | Verify only KernelPMUEvents is collected when related field is set to True. |
<Plugin intel_pmu> HWCacheEvents false KernelPMUEvents true SWEvents false </Plugin> |
|
KernelPMUEvents are collectd. |
5 | Verify only SWEvents is collected when related field is set to True. |
<Plugin intel_pmu> HWCacheEvents false KernelPMUEvents false SWEvents true </Plugin> |
|
SWEvents are collected. |
6 | Verify only HWSpecificEvents is collected when related field is set to specific values. |
<Plugin intel_pmu> HWCacheEvents false KernelPMUEvents false SWEvents false HWSpecificEvents "L2_RQSTS.CODE_RD_HIT" </Plugin> |
|
|
7 | Verify that all metrics are collected when all fields have enabled flags. |
<Plugin intel_pmu> HWCacheEvents true KernelPMUEvents true SWEvents true HWSpecificEvents "L2_RQSTS.CODE_RD_HIT,L2_RQSTS.CODE_RD_MISS" </Plugin> |
|
Make sure that events related to HWCacheEvents , KernelPMUEvents, SWEvents, HWSpecificEvents are collected. |
8 | Verify number of counters for HWCacheEvents matches number of events defined in OPNFV metrics page. |
<Plugin intel_pmu> HWCacheEvents true KernelPMUEvents false SWEvents false HWSpecificEvents "" </Plugin> |
|
Number of counters for HWCacheEvents matches number of events defined in OPNFV metrics page. |
9 | Verify number of counters for KernelPMUEvents matches number of events defined in OPNFV metrics page. |
<Plugin intel_pmu> HWCacheEvents false KernelPMUEvents true SWEvents false HWSpecificEvents "" </Plugin> |
|
Number of counters for KernelPMUEvents matches number of events defined in OPNFV metrics page. |
10 | Verify number of counters for SWEvents matches number of events defined in OPNFV metrics page. |
<Plugin intel_pmu> HWCacheEvents false KernelPMUEvents false SWEvents true HWSpecificEvents "" </Plugin> |
|
Number of counters for SWEvents matches number of events defined in OPNFV metrics page. PASS |
11 | Verify that HWCacheEvents counters are incremented. |
<Plugin intel_pmu> HWCacheEvents true KernelPMUEvents false SWEvents false HWSpecificEvents "" </Plugin> |
|
|
12 | Verify that KernelPMUEvents counters are incremented. |
<Plugin intel_pmu> HWCacheEvents false KernelPMUEvents true SWEvents true HWSpecificEvents "" </Plugin> |
|
|
13 | Verify that SWEvents counters are incremented. |
<Plugin intel_pmu> HWCacheEvents false KernelPMUEvents false SWEvents true HWSpecificEvents "" </Plugin> |
|
|
14 | Verify that HWSpecificEvents counters are incremented. |
<Plugin intel_pmu> HWCacheEvents false KernelPMUEvents false SWEvents false HWSpecificEvents "L2_RQSTS.CODE_RD_HIT,L2_RQSTS.CODE_RD_MISS" </Plugin> |
|
|
15 | Verify values reported for HWCacheEvents are in range of actual values reported by perf tool. |
<Plugin intel_pmu> HWCacheEvents true KernelPMUEvents false SWEvents false HWSpecificEvents "" </Plugin> |
|
|
16 | Verify values reported for KernelPMUEvents are in range of actual values reported by perf tool. |
<Plugin intel_pmu> HWCacheEvents false KernelPMUEvents true SWEvents false HWSpecificEvents "" </Plugin> |
perf stat -A -C 1,5,20 -e <events> sleep 20
|
|
17 | Verify values reported for SWEvents are in range of actual values reported by perf tool |
<Plugin intel_pmu> HWCacheEvents false KernelPMUEvents false SWEvents true HWSpecificEvents "" </Plugin> |
perf stat -A -C 1,5,20 -e <events> sleep 20
|
|
18 | Verify values reported for HWSpecificEvents are in range of actual values reported by perf tool |
<Plugin intel_pmu> HWCacheEvents false KernelPMUEvents false SWEvents false HWSpecificEvents "L2_RQSTS.CODE_RD_HIT,L2_RQSTS.CODE_RD_MISS" </Plugin> |
perf stat -A -C 1,5,20 -e <events> sleep 20
|
|
19 | Verify intel_pmu counters are reported per each core and per all cores |
<Plugin intel_pmu> HWCacheEvents {} KernelPMUEvents {} SWEvents {} HWSpecificEvents {} </Plugin> |
|
|
20 | Verify intel_pmu counters are not reported for unsupported events per core and per all cores. |
<Plugin intel_pmu> HWCacheEvents true KernelPMUEvents false SWEvents false HWSpecificEvents "" </Plugin> |
|
Unsupported events are collected per all cores. |
21 | Config-less testing - invalid HWCacheEvents field |
<Plugin intel_pmu> HWCacheEvents incorrect KernelPMUEvents true SWEvents false HWSpecificEvents "" </Plugin> |
Values to test = ['None', '', '1', 'incorrect']
|
|
22 | Config-less testing - invalid KernelPMUEventsfield |
<Plugin intel_pmu> HWCacheEvents true KernelPMUEvents invalid_value SWEvents false HWSpecificEvents "" </Plugin> |
Values to test = ['None', '', '1', 'incorrect']
|
|
23 | Config-less testing - invalid SWEventsfield |
<Plugin intel_pmu> HWCacheEvents true KernelPMUEvents false SWEvents invalid_value HWSpecificEvents "" </Plugin> |
Values to test = ['None', '', '1', 'incorrect']
|
|
24 | Config-less testing - invalid HWSpecificEventsfield |
<Plugin intel_pmu> HWCacheEvents true KernelPMUEvents false SWEvents false HWSpecificEvents </Plugin> |
Values to test = ['']
|
|
25 | Config-less testing - invalid field name |
<Plugin intel_pmu> HWCacheEvents true KernelPMUEvents false SWEvents false HWSpecificEvents "" IncorrectField true </Plugin> |
Values to test = ['None', '', '1', 'true']
|