PMDADAEMON - Online Linux Manual PageSection : 3
Updated : PCP
Source : Performance Co-Pilot

NAMEpmdaDaemon − initialize the PMDA to run as a daemon

C SYNOPSIS#include <pcp/pmapi.h>
#include <pcp/pmda.h> void pmdaDaemon(pmdaInterface *dispatch, int interface, const char *name, int domain, const char *logfile, const char *helptext); cc ... −lpcp_pmda −lpcp

DESCRIPTIONpmdaDaemon initializes the pmdaInterface structure to use the interface extensions assuming the PMDA(3) is to be run as a daemon. The pmdaInterface structure is initialized with: name  The name of the agent. domain  The default domain number of the agent which uniquely identifies this PMDA from other running PMDAs. This may be subsequently changed by a command line option −d (see pmdaGetOpt(3)). logfile  The default path to the log file. This may be replaced by the −l command line option if using pmdaGetOpt. logfile will be copied with strdup(3), so the storage associated with logfile may be released after the call to pmdaDaemon. helptext  The default path to the help text (see pmdaText(3). This may be replaced by the −h command line option if using pmdaGetOpt(3). If no help text is installed, or you are not using pmdaText(3), then this should be set to NULL, otherwise helptext will be copied with strdup(3), so the storage associated with helptext may be released after the call to pmdaDaemon. The callbacks are initialized to pmdaProfile(3), pmdaFetch(3), pmdaDesc(3), pmdaText(3), pmdaInstance(3) and pmdaStore(3).

DIAGNOSTICSUnable to allocate memory for pmdaExt structure  In addition, the dispatch->status field is set to a value less than zero. PMDA interface version interface not supported  The interface version is not supported by pmdaDaemon.

CAVEATThe PMDA must be using PMDA_INTERFACE_2 or later. Once pmdaDaemon has been called, it is expected that the pmdaInterface structure pointed to by dispatch will remain accessible to the routines in libpcp_pmda (not reclaimed off the stack, not freed or oherwise released, etc.). If the caller needs to move or relocate the pmdaInterface structure for any reason, then after the move pmdaInterfaceMoved(3) must be called to resestablish the internal integrity of the pmdaInterface structure at the new location before any other routine in libpcp_pmda is called.

SEE ALSOPMAPI(3), PMDA(3), pmdaDSO(3), pmdaGetOpt(3), pmdaInterfaceMoved(3) and pmdaText(3).
0
Johanes Gumabo
Data Size   :   9,987 byte
man-pmdaDaemon.3Build   :   2024-12-05, 20:55   :  
Visitor Screen   :   x
Visitor Counter ( page / site )   :   3 / 184,956
Visitor ID   :     :  
Visitor IP   :   3.146.255.135   :  
Visitor Provider   :   AMAZON-02   :  
Provider Position ( lat x lon )   :   39.962500 x -83.006100   :   x
Provider Accuracy Radius ( km )   :   1000   :  
Provider City   :   Columbus   :  
Provider Province   :   Ohio ,   :   ,
Provider Country   :   United States   :  
Provider Continent   :   North America   :  
Visitor Recorder   :   Version   :  
Visitor Recorder   :   Library   :  
Online Linux Manual Page   :   Version   :   Online Linux Manual Page - Fedora.40 - march=x86-64 - mtune=generic - 24.12.05
Online Linux Manual Page   :   Library   :   lib_c - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Online Linux Manual Page   :   Library   :   lib_m - 24.10.03 - march=x86-64 - mtune=generic - Fedora.40
Data Base   :   Version   :   Online Linux Manual Page Database - 24.04.13 - march=x86-64 - mtune=generic - fedora-38
Data Base   :   Library   :   lib_c - 23.02.07 - march=x86-64 - mtune=generic - fedora.36

Very long time ago, I have the best tutor, Wenzel Svojanovsky . If someone knows the email address of Wenzel Svojanovsky , please send an email to johanes_gumabo@yahoo.co.id .
If error, please print screen and send to johanes_gumabo@yahoo.co.id
Under development. Support me via PayPal.