Difference between revisions of "Plugin:exec-solusvm-bandwidth.sh"

From collectd Wiki
Jump to: navigation, search
m (Jolt moved page Plugin:exec-solus-bandwidth to Plugin:exec-solusvm-bandwidth: clarify title)
 
(4 intermediate revisions by 2 users not shown)
Line 1: Line 1:
 
{{Infobox Plugin
 
{{Infobox Plugin
   | Name=collectd-solus-bw.sh
+
   | Name=collectd-solusvm-bw.sh
 
   | Type=read
 
   | Type=read
 
   | Callbacks=''n/a''
 
   | Callbacks=''n/a''
Line 6: Line 6:
 
   | FirstVersion=''n/a''
 
   | FirstVersion=''n/a''
 
   | Copyright=''2016'' Fredrik Lundhag
 
   | Copyright=''2016'' Fredrik Lundhag
   | License={{MIT}}
+
   | License={{MIT License}}
 
   | Manpage=''n/a''
 
   | Manpage=''n/a''
 
}}
 
}}
  
'''collectd-solus-bw.sh''' is a shell script which read bandwidth statistics from ''SolusVM'', a common platform for VPS providers. The script requires the {{Plugin|Exec}}, [http://curl.haxx.se/ curl] and grep with -P ''(--perl-regexp'' support) to run and was written by ''Fredrik Lundhag''.
+
'''[https://gist.github.com/joltcan/718653fe18cf431612895b7c5a86f74b#file-collectd-solusvm-bw-sh collectd-solusvm-bw.sh]''' is a shell script which read bandwidth statistics from ''SolusVM'', a common platform for VPS providers. The script requires the {{Plugin|Exec}}, [http://curl.haxx.se/ curl] and grep with -P ''(--perl-regexp'' support) to run and was written by ''Fredrik Lundhag''.
  
 
== Synopsis ==
 
== Synopsis ==
  
 
To use this script, do the following:
 
To use this script, do the following:
* Download or copy the gist [https://gist.github.com/joltcan/718653fe18cf431612895b7c5a86f74b collectd-solus-bw.sh] from GitHub into /etc/collectd.
+
* Download or copy the gist [https://gist.github.com/joltcan/718653fe18cf431612895b7c5a86f74b#file-collectd-solusvm-bw-sh collectd-solusvm-bw.sh] from GitHub into /etc/collectd.
 
* Enable API in the VPS SolusVM control panel, then copy your API key + hash and put them into the script together with the path to the API.
 
* Enable API in the VPS SolusVM control panel, then copy your API key + hash and put them into the script together with the path to the API.
 
* I recommend you to run the script manually first to make sure that the output looks correct and that the API URL works.
 
* I recommend you to run the script manually first to make sure that the output looks correct and that the API URL works.
Line 22: Line 22:
 
  LoadPlugin exec
 
  LoadPlugin exec
 
  <Plugin exec>
 
  <Plugin exec>
     Exec <user>[:group] "/etc/collectd/collectd-solus-bw.sh"  
+
     Exec <user>[:group] "/etc/collectd/collectd-solusvm-bw.sh"  
 
  </Plugin>
 
  </Plugin>
  
Line 42: Line 42:
 
[[Category:Plugins]]
 
[[Category:Plugins]]
 
[[Category:Exec Plugins]]
 
[[Category:Exec Plugins]]
{{DEFAULTSORT:collectd-solus-bw.sh}}
+
{{DEFAULTSORT:exec-solusvm-bandwidth.sh}}

Latest revision as of 01:35, 12 March 2020

collectd-solusvm-bw.sh plugin
Type: read
Callbacks: n/a
Status: external
First version: n/a
Copyright: 2016 Fredrik Lundhag
License: MIT license
Manpage: n/a
List of Plugins

collectd-solusvm-bw.sh is a shell script which read bandwidth statistics from SolusVM, a common platform for VPS providers. The script requires the Exec plugin, curl and grep with -P (--perl-regexp support) to run and was written by Fredrik Lundhag.

Synopsis

To use this script, do the following:

  • Download or copy the gist collectd-solusvm-bw.sh from GitHub into /etc/collectd.
  • Enable API in the VPS SolusVM control panel, then copy your API key + hash and put them into the script together with the path to the API.
  • I recommend you to run the script manually first to make sure that the output looks correct and that the API URL works.
  • Add the section below the configuration of the Exec plugin:
LoadPlugin exec
<Plugin exec>
    Exec <user>[:group] "/etc/collectd/collectd-solusvm-bw.sh" 
</Plugin>

Example graphs

Collectd-Solus-bw.png

Dependencies

See also