4

I know how to read statistics about the configured network interfaces, for example via cat /proc/net/dev.

Is there a way to read similar byte counters of PCI or PCIe traffic?

Apparently, according to https://www.intel.com/content/dam/www/public/us/en/documents/design-guides/xeon-e5-2600-uncore-guide.pdf there should be a metric PCIE_DATA_BYTES, traceable for example via ucevent: https://github.com/andikleen/pmu-tools/blob/master/ucevent/README.md

If I run

ucevent.py -I 2000 CBO.PCIE_DATA_BYTES sleep 10

I obtain

unknown event CBO.PCIE_DATA_BYTES

I tried this on two servers:

Intel(R) Xeon(R) CPU E5-2630 v4 @ 2.20GHz
Intel(R) Xeon(R) CPU E5-2640 v4 @ 2.40GHz

Any suggestions or help please?

perde
  • 41
  • 2
  • 1
    I don't think there is a native "counter" for it, but you can try `dtrace`, `uncore` and / or something like this: https://github.com/andikleen/pmu-tools/blob/master/ucevent/README.md – Lenniey Nov 13 '18 at 08:08
  • This looks very promising. I will try it. Thank you! – perde Nov 13 '18 at 09:00
  • 1
    The Linux kernel maintains a performance counters subsystem, some of which may be relevant for you. They can be queried with the bundled [`perf`](https://perf.wiki.kernel.org/index.php/Main_Page) tool http://www.brendangregg.com/perf.html has some examples – HBruijn Nov 13 '18 at 09:50
  • Thank you! `perf` seems to provide some general information about PCI, for example maximal PCIe bandwidth, but I cannot find a suitable counter for the actually transfered amount of data. Is there any? – perde Nov 13 '18 at 16:38
  • I cannot find information about how to use `dtrace` or `perf` for this specific issue – perde Nov 15 '18 at 21:58

0 Answers0