MRTG2PCP(1)

πŸ“¦
version 7.2.2 Β· 2 versions
, in arch rolling, centos-stream 10, centos-stream 9, debian trixie, fedora 43, fedora 44, ubuntu questing, ubuntu resolute, ubuntu stonking

πŸ’– MRTG2PCP πŸ’–

okay bestie, welcome to mrtg2pcp β€” the little Perl icon that slurps up your MRTG logs and spits out a whole Performance Co-Pilot archive. it's giving glow-up, fr fr. ✨


🌸 NAME 🌸

mrtg2pcp β€” import MRTG data and create a PCP archive πŸ¦‹


✨ SYNOPSIS ✨

mrtg2pcp hostname devname timezone infile outfile

πŸ’… DESCRIPTION πŸ’…

so the whole vibe of mrtg2pcp is: it reads an MRTG log file β€” the kind mrtg(1) makes β€” and translates it into a Performance Co-Pilot (PCP) archive whose basename is outfile. that's the main character move. πŸ‘‘

the hostname, devname, and timezone arguments are there to tell it the tea about the system those stats came from. no cap, it needs them.

once you've got your archive, it plays nice with all the PCP client tools:

  • graph subsets of the data with pmchart(1) πŸ“ˆ
  • do data reduction and reporting
  • filter with the PCP inference engine, pmie(1)
  • etc. (iykyk)

a series of physical files gets created with the prefix outfile. lowkey iconic trio:

  • outfile.0 β€” the performance data πŸ“
  • outfile.meta β€” the metadata that describes the performance data
  • outfile.index β€” a temporal index to improve efficiency of replay operations for the archive
🚨 okay important: if any of these files already exists, then mrtg2pcp will not overwrite them, and it will exit with an error message of the form:
__pmLogNewFile: ``blah.0'' already exists, not over-written

mrtg2pcp is a Perl script that uses the PCP::LogImport Perl wrapper around the PCP libpcp_import library. so if you're feeling crafty, it could totally be used as an example to develop new tools to import other types of performance data and create PCP archives. πŸ’œ go off, honestly.


🌈 PCP ENVIRONMENT 🌈

environment variables with the prefix PCP_ are used to parameterize the file and directory names used by PCP. on each installation, the file /etc/pcp.conf contains the local values for these variables. and the $PCP_CONF variable may be used to specify an alternative configuration file, as described in pcp.conf(5). 🌟


πŸŽ€ SEE ALSO πŸŽ€


and that's the whole page, bestie 🫢 this one came straight out of the Performance Co-Pilot era of PCP, page MRTG2PCP(1). mwah, go import something pretty πŸ’–βœ¨

πŸ“¦ where this page comes from