NAME

       pmGetContextHostName - return the hostname associated with
       a Performance Co-Pilot context identifier


C SYNOPSIS

       #include <pcp/pmapi.h>

       const char *pmGetContextHostName(int id)

       cc ... -lpcp


DESCRIPTION

       Given a valid PCP context  identifier  previously  created
       with  pmNewContext(3) or pmDupContext(3), the pmGetContex­
       tHostName function returns the  hostname  associated  with
       id.   The  context id may be associated with either a live
       (host) or archive source of data.  In the latter case, the
       hostname  returned  is  extracted  from  the archive label
       using pmGetArchiveLabel(3).


RETURN VALUE

       If id is not a valid PCP context identifier, this function
       returns a zero length string and hence never fails.


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.  The $PCP_CONF  variable
       may  be used to specify an alternative configuration file,
       as described in pcp.conf(4).  Values for  these  variables
       may  be  obtained programatically using the pmGetConfig(3)
       function.


SEE ALSO

       PCPIntro(1),  PMAPI(3),  pmDupContext(3),  pmGetArchiveLa­
       bel(3), pmNewContext(3), pcp.conf(4) and pcp.env(4).


Man(1) output converted with man2html