PMFETCHARCHIVE(3) - man page online | library functions

Get performance metrics directly from an archive log.

PMFETCHARCHIVE(3)                    Library Functions Manual                   PMFETCHARCHIVE(3)


pmFetchArchive - get performance metrics directly from an archive log


#include <pcp/pmapi.h> int pmFetchArchive(pmResult **result); cc ... -lpcp


pmFetchArchive is a variant of pmFetch(3) that may only be used when the current Perfor‐ mance Metrics Application Programming Interface (PMAPI) context is associated with an ar‐ chive log. The result is instantiated with all of the metrics (and instances) from the next archive record, consequently there is no notion of a list of desired metrics, and the instance profile of the PMAPI context is ignored. It is expected that pmFetchArchive would be used to create utilities that scan archive logs, while the more common access to the archives would be via the pmFetch(3) interface. To skip records within the archive log, use pmSetMode(3) to change the collection time within the current PMAPI context, then call pmFetchArchive. Note that the result returned by pmFetchArchive is dynamically allocated, and must be released using pmFreeResult(3), not free(3C). See pmFetch(3) and pmFreeResult(3) for fur‐ ther details. pmFetchArchive returns zero on success.


PMAPI(3), pmFetch(3), pmFreeResult(3), pmNewContext(3), pmSetMode(3) and pmTrimNameS‐ pace(3).


PM_ERR_NOTARCHIVE the current PMAPI context is not associated with an archive log
Performance Co-Pilot PCP PMFETCHARCHIVE(3)
This manual Reference Other manuals
pmFetchArchive(3) referred by PCPIntro(3) | pmFetch(3) | pmGetArchiveEnd(3) | pmRegisterDerived(3) | pmSetMode(3)
refer to malloc(3) | PMAPI(3) | pmFetch(3) | pmFreeResult(3) | pmNewContext(3) | pmSetMode(3)