1PMDAJSON(1)                 General Commands Manual                PMDAJSON(1)
2
3
4

NAME

6       pmdajson - JSON PMDA
7

DESCRIPTION

9       pmdajson  is  a  Performance  Metrics Domain Agent (PMDA) which exports
10       metrics from arbitrary sources generating  JavaScript  Object  Notation
11       (JSON) syntax.
12
13       At  least  one pair of JSON inputs are required for pmdajson to provide
14       metrics for PCP clients; one describing metric metadata  and  one  con‐
15       taining  metric values data.  Metadata is read once from a file at PMDA
16       startup while the data is read every time a request for  metric  values
17       is  made  by a PCP client.  The data is read either from a JSON file or
18       an external command generating JSON output.  More than one pair of JSON
19       inputs  can  be  used  to support arbitrary number of metric sources in
20       different configured directories.
21
22       The overall JSON format description is at http://www.json.org/.
23

JSON DATA SOURCES

25       pmdajson reads a mandatory JSON configuration file
26
27           · $PCP_PMDAS_DIR/json/config.json
28
29       This file can contain the following PMDA options using the JSON syntax:
30
31           · directory_list
32           · trusted_directory_list
33
34       pmdajson searches the directories listed for these options looking  for
35       files  named  metadata.json and (by default) data.json.  The JSON meta‐
36       data files describe the metric names, types, and other details  of  the
37       associated  JSON metric data.  The JSON data file name is configurable,
38       and can also be an external command instead of a  periodically  updated
39       (by external tools) data file.
40
41       Each of these found JSON file/command pairs form a JSON data source.
42
43       For  example,  let  us  assume the following simple JSON data file that
44       contains values for two metrics, one of type string and one numeric:
45
46         {
47           "string_value": "testing, 1, 2, 3",
48           "read_count": 0
49         }
50
51       For these metrics the metadata file needed by pmdajson would be:
52
53         {
54           "metrics": [
55             {
56               "name": "string_value",
57               "pointer": "/string_value",
58               "type": "string"
59             },
60             {
61               "name": "read_count",
62               "pointer": "/read_count",
63               "type": "integer",
64               "description": "Times values read"
65             }
66           ]
67         }
68
69       For further details on the JSON metadata format and  options,  see  the
70       README file included as part of pmdajson installation.
71

SECURITY MODEL

73       JSON data sources listed for the directory_list option are not trusted,
74       meaning that if external commands to generate the needed JSON data  are
75       used, these commands are run as user nobody.
76
77       JSON  data  sources  listed  for  the trusted_directory_list option are
78       trusted, meaning that if external commands to generate the needed  JSON
79       data are used, these commands are run as user root.
80
81       For  further  details  on  security and description on running external
82       commands, see the README file included as part  of  pmdajson  installa‐
83       tion.
84

INSTALLATION

86       Install the JSON PMDA by using the Install script as root:
87
88           # cd $PCP_PMDAS_DIR/json
89           # ./Install
90
91       To uninstall, do the following as root:
92
93           # cd $PCP_PMDAS_DIR/json
94           # ./Remove
95
96       pmdajson  is launched by pmcd(1) and should never be executed directly.
97       The Install and  Remove  scripts  notify  pmcd(1)  when  the  agent  is
98       installed or removed.
99

FILES

101       $PCP_PMDAS_DIR/json/README
102              additional documentation for pmdajson used JSON files
103
104       $PCP_PMDAS_DIR/json/config.json
105              configuration file for the pmdajson agent
106
107       $PCP_PMDAS_DIR/json/Install
108              installation script for the pmdajson agent
109
110       $PCP_PMDAS_DIR/json/Remove
111              undo installation script for the pmdajson agent
112
113       $PCP_LOG_DIR/pmcd/json.log
114              default log file for messages from the pmdajson agent
115

PCP ENVIRONMENT

117       Environment variables with the prefix PCP_ are used to parameterize the
118       file and directory names used by PCP.  On each installation,  the  file
119       /etc/pcp.conf  contains  the  local  values  for  these variables.  The
120       $PCP_CONF variable may be used to specify an alternative  configuration
121       file, as described in pcp.conf(5).
122

SEE ALSO

124       PCPIntro(1), pmcd(1) and pminfo(1).
125
126
127
128Performance Co-Pilot                  PCP                          PMDAJSON(1)
Impressum