Debian Codegraph @

gmond/modules/perl/README

raw
1 This document is Work In Progress until mod_perl is fully implemented and tested.
2 For now, please refer to the README in gmond/modules/python for basic setup/configuration
3 instructions as the Perl DSO implementation is very close to the Python one.
4
5 Quickstart
6 - Build Ganglia with mod_perl support (it will be automatically built if /usr/bin/perl
7 is found)
8 - Copy Perl metric modules to /usr/lib/ganglia/perl_modules
9 (eg. gmond/perl_modules/example/example.pl)
10 - Copy Perl metric module configurations to /etc/ganglia/conf.d
11 (eg. gmond/perl_modules/conf.d/example.plconf)
12 - Start gmond
13
14 Major differences between Python and Perl DSO:
15 - Instead of a .py suffix, Perl modules are identified by .pl suffix
16 - Similarly, instead of .pyconf suffix, Perl module configurations are identified by
17 .plconf suffix
18 - In Python DSO, the callback is an actual function, for Perl DSO, it is simply
19 the name of the callback function
20 - Perl does not seem to differentiate between double and float
21 - In order to load Perl global variables into C, the entire script needs to be loaded
22 and interperted. Since Perl cannot do if __name__ == '__main__', debugging code
23 that prints to stdout will also be executed when the module is loaded by gmond.
24 The current workaround is simply pipe all stdout of the script to /dev/null
25
26 Known Issues:
27 - Currently you cannot load more than one Perl metric module at a time. Loading
28 multiple modules with different callback function names may lead to gmond crashing
29 since it cannot find the correct handler function (issue with namespace perhaps)
30 - perl_metric_cleanup() function has not yet been fully implemented