michelgokan / collectd-top Goto Github PK
View Code? Open in Web Editor NEWcollectd-top: A plugin to measure and send top processes by CPU or Memory
Home Page: http://gokan.me
collectd-top: A plugin to measure and send top processes by CPU or Memory
Home Page: http://gokan.me
I installed your plugin following the readme step by step. Collectd starts and other plugins are working as usual. Yours is not recording data and I see the following traces in the journal.
Ubuntu 18.04.3 LTS (GNU/Linux 3.16.78-48 aarch64)
Collectd 5.7.2
Perl 5.26.1
Jan 27 19:24:29 xxx collectd[19950]: sort: write failed: 'standard output': Broken pipe
Jan 27 19:24:29 xxx collectd[19950]: sort: write error
Jan 27 19:24:29 xxx collectd[19950]: sort: write failed: 'standard output': Broken pipe
Jan 27 19:24:29 xxx collectd[19950]: sort: write error
Jan 27 19:24:39 xxx collectd[19950]: sort: write failed: 'standard output': Broken pipe
Jan 27 19:24:39 xxx collectd[19950]: sort: write error
Jan 27 19:24:39 xxx collectd[19950]: sort: write failed: 'standard output': Broken pipe
Jan 27 19:24:39 xxx collectd[19950]: sort: write error
Jan 27 19:24:49 xxx collectd[19950]: sort: write failed: 'standard output': Broken pipe
Jan 27 19:24:49 xxx collectd[19950]: sort: write error
Jan 27 19:24:59 xxx collectd[19950]: sort: write failed: 'standard output': Broken pipe
Jan 27 19:24:59 xxx collectd[19950]: sort: write error
Please see the following errors:
$perl Makefile.PL
Checking if your kit is complete...
Warning: the following files are missing in your kit:
README
Please inform the author.
WARNING: Setting VERSION via file 'lib/Collectd/Plugins/Top.pm' failed
at /usr/share/perl/5.22/ExtUtils/MakeMaker.pm line 651.
WARNING: Setting ABSTRACT via file 'lib/Collectd/Plugins/Top.pm' failed
at /usr/share/perl/5.22/ExtUtils/MakeMaker.pm line 663.
Generating a Unix-style Makefile
Writing Makefile for Collectd::Plugins::Top
Writing MYMETA.yml and MYMETA.json
NOTE:
perl --version
This is perl 5, version 22, subversion 1 (v5.22.1) built for x86_64-linux-gnu-thread-multi
(with 69 registered patches, see perl -V for more detail)
Hi,
I am running Collectd-5.1.0 on CentOS 5.8 , perl v5.8.2.
commented line 'use 5.018002;' since I wanted to use the default version. Compiled and Installed the module successfully. No errors
Receiving 'segfault' in syslog after executing 'service collectd stop'. Collectd starts fine and loads the plugin, but stopping produces the error
collectd[3070]: segfault at 0000000000000000 rip 0000003faf078900 rsp 00007fff53ef02d8 error 4
.........................
Jun 20 17:01:40 CentOS5.8_VM collectd[15329]: perl: Initializing Perl interpreter...
Jun 20 17:01:40 CentOS5.8_VM collectd[15329]: TOP CONF - Inside foreach topprocessescountbymemory / 4
Jun 20 17:01:40 CentOS5.8_VM collectd[15329]: TOP CONF - Inside foreach topprocessescountbycpu / 5
Jun 20 17:01:40 CentOS5.8_VM collectd[15330]: Initialization complete, entering read-loop.
Jun 20 17:02:39 CentOS5.8_VM collectd[15330]: Exiting normally.
Jun 20 17:02:39 CentOS5.8_VM collectd[15330]: collectd: Stopping 5 read threads.
Jun 20 17:02:39 CentOS5.8_VM kernel: collectd[15330]: segfault at 0000000000000000 rip 00000032a2a79ba0 rsp 00007fffb424d4b8 error 4
Thanks
AjaY
make test
PERL_DL_NONLAZY=1 "/usr/bin/perl" "-MExtUtils::Command::MM" "-MTest::Harness" "-e" "undef Test::Harness::Switches; test_harness(0, 'blib/lib', 'blib/arch')" t/.t
t/Collectd-Plugins-Top.t .. 1/1
t/Collectd-Plugins-Top.t .. Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/1 subtests
t/Collectd-top.t .......... Array found where operator expected at t/Collectd-top.t line 12, at end of line
(Do you need to predeclare top?)
t/Collectd-top.t .......... 1/1
t/Collectd-top.t .......... Dubious, test returned 1 (wstat 256, 0x100)
Failed 1/1 subtests
t/Collectd-Plugins-Top.t (Wstat: 256 Tests: 1 Failed: 1)
Failed test: 1
Non-zero exit status: 1
t/Collectd-top.t (Wstat: 256 Tests: 1 Failed: 1)
Failed test: 1
Non-zero exit status: 1
Files=2, Tests=2, 0 wallclock secs ( 0.02 usr 0.01 sys + 0.03 cusr 0.00 csys = 0.06 CPU)
Result: FAIL
Failed 2/2 test programs. 2/2 subtests failed.
Makefile:805: recipe for target 'test_dynamic' failed
make: *** [test_dynamic] Error 1
Is there any way to add the active running process name to this?
Thanks,
Siddharth
Plugin loading failed while starting collectd server, this is my collectd logs
Jan 31 07:54:56 localhost collectd[5517]: plugin_load: plugin "syslog" successfully loaded.
Jan 31 07:54:56 localhost collectd[5517]: type = syslog, key = LogLevel, value = info
Jan 31 07:54:56 localhost collectd[5517]: plugin_load: plugin "perl" successfully loaded.
Jan 31 07:54:56 localhost collectd[5517]: perl: Initializing Perl interpreter...
Jan 31 07:54:56 localhost collectd[5517]: perl: init_pi: Unable to bootstrap Collectd: lock can only be used on shared values at /usr/share/perl/5.18/perl5db.pl line 4100.
Jan 31 07:54:56 localhost collectd[5517]: perl: Configuration failed with a fatal error - plugin disabled!
Jan 31 07:54:56 localhost collectd[5517]: plugin_load: plugin "cpu" successfully loaded.
Jan 31 07:54:56 localhost collectd[5517]: plugin_load: plugin "csv" successfully loaded.
Jan 31 07:54:56 localhost collectd[5517]: plugin_load: plugin "df" successfully loaded.
Jan 31 07:54:56 localhost collectd[5517]: plugin_load: plugin "load" successfully loaded.
Jan 31 07:54:56 localhost collectd[5517]: plugin_load: plugin "memory" successfully loaded.
Jan 31 07:54:56 localhost collectd[5517]: plugin_load: plugin "write_http" successfully loaded.
Jan 31 07:54:56 localhost collectd[5517]: plugin_load: plugin "swap" successfully loaded.
Jan 31 07:54:56 localhost collectdmon[5505]: Warning: collectd terminated with exit status 1
Jan 31 07:54:56 localhost collectdmon[5505]: Warning: restarting collectd
Jan 31 07:54:56 localhost collectd[5518]: plugin_load: plugin "syslog" successfully loaded.
Jan 31 07:54:56 localhost collectd[5518]: type = syslog, key = LogLevel, value = info
Jan 31 07:54:56 localhost collectd[5518]: plugin_load: plugin "perl" successfully loaded.
Jan 31 07:54:56 localhost collectd[5518]: perl: Initializing Perl interpreter...
Jan 31 07:54:56 localhost collectd[5518]: perl: init_pi: Unable to bootstrap Collectd: lock can only be used on shared values at /usr/share/perl/5.18/perl5db.pl line 4100.
Jan 31 07:54:56 localhost collectd[5518]: perl: Configuration failed with a fatal error - plugin disabled!
My Perl version
root@localhost:~# perl -v
This is perl 5, version 18, subversion 2 (v5.18.2) built for x86_64-linux-gnu-thread-multi
(with 55 registered patches, see perl -V for more detail)
My Top plugin config:
Globals true IncludeDir "/usr/local/share/perl/5.18.2/Collectd/Plugins" BaseName "Collectd::Plugins" EnableDebugger "" LoadPlugin "Top" <Plugin Top>
</Plugin>
root@localhost:/etc/init.d# lsb_release -a
No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 14.04.1 LTS
Release: 14.04
Codename: trusty
Could you check issue
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.