1PMGETCONTEXTHOSTNAME(3) Library Functions Manual PMGETCONTEXTHOSTNAME(3)
2
3
4
6 pmGetContextHostName - return the hostname associated with a Perfor‐
7 mance Co-Pilot context identifier
8
10 #include <pcp/pmapi.h>
11
12 const char *pmGetContextHostName(int id)
13
14 cc ... -lpcp
15
17 Given a valid PCP context identifier previously created with pmNewCon‐
18 text(3) or pmDupContext(3), the pmGetContextHostName function returns
19 the hostname associated with id. The context id may be associated with
20 either a live (host) or archive source of data. In the latter case,
21 the hostname returned is extracted from the archive label using
22 pmGetArchiveLabel(3).
23
25 If id is not a valid PCP context identifier, this function returns a
26 zero length string and hence never fails.
27
29 Environment variables with the prefix PCP_ are used to parameterize the
30 file and directory names used by PCP. On each installation, the file
31 /etc/pcp.conf contains the local values for these variables. The
32 $PCP_CONF variable may be used to specify an alternative configuration
33 file, as described in pcp.conf(4). Values for these variables may be
34 obtained programatically using the pmGetConfig(3) function.
35
37 PCPIntro(1), PMAPI(3), pmDupContext(3), pmGetArchiveLabel(3), pmNewCon‐
38 text(3), pcp.conf(4) and pcp.env(4).
39
40
41
42Performance Co-Pilot SGI PMGETCONTEXTHOSTNAME(3)