PMISETHOSTNAME(3)
π pmiSetHostname β bestie edition π
okay so this is a page from the Library Functions Manual, section 3, and it's literally all about pmiSetHostname β¨ (the name is right there in the title bestie, we're not being subtle).
πΈ NAME πΈ
pmiSetHostname β set the source host name for a LOGIMPORT archive π«Ά
β¨ C SYNOPSIS β¨
#include <pcp/pmapi.h>
#include <pcp/import.h>
int pmiSetHostname(const char *value);
cc ... -lpcp_import -lpcp
π Perl SYNOPSIS π
use PCP::LogImport;
pmiSetHostname($value);
π¦ Python SYNOPSIS π¦
from pcp import pmi
log.pmiSetHostname(value)
π DESCRIPTION π
So here's the tea: this function is part of the Performance Co-Pilot Log Import API (go check LOGIMPORT(3) if you wanna see the whole vibe, iykyk), and pmiSetHostname sets the source hostname in the current context to be value. That's it. That's the whole job. Iconic, honestly.
And if you just... never call pmiSetHostname? Not me forgetting π β then the source hostname lowkey defaults to the hostname of the localhost. No cap, it just does that on its own. π β¨
π DIAGNOSTICS π
pmiSetHostname returns zero on success, else a negative value β and bestie, you can turn that negative value into an actual error message by calling pmiErrStr(3). Don't just stare at the negative number, go get the lore. π
π SEE ALSO π
π«Ά and that's the whole page, fr fr. shoutout to Performance Co-Pilot for bringing us this one β go set some hostnames, bestie, you got this πβ¨π
π¦ where this page comes from
- arch rolling: pcp 7.2.2-2 Β· GPL-2.0-or-later AND LGPL-2.1-or-later AND CC-BY-3.0
- fedora 43: pcp-doc 7.2.1-1.fc43
- fedora 43: pcp-doc 7.2.2-1.fc43
- fedora 43: pcp-doc 7.2.2-2.fc43 Β· GPL-2.0-or-later AND CC-BY-3.0
- fedora 44: pcp-doc 7.2.1-1.fc44
- fedora 44: pcp-doc 7.2.2-1.fc44
- fedora 44: pcp-doc 7.2.2-2.fc44 Β· GPL-2.0-or-later AND CC-BY-3.0
- ubuntu stonking: libpcp4-dev 7.2.1-2build1
- Copyright (c) 2010 Ken McDonell. All Rights Reserved
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms