Monitoring: add collectd configs
This commit is contained in:
parent
9e8a21b6f7
commit
f59a3cb007
|
@ -0,0 +1,239 @@
|
||||||
|
##############################################################################
|
||||||
|
# Global #
|
||||||
|
#----------------------------------------------------------------------------#
|
||||||
|
# Global settings for the daemon. #
|
||||||
|
##############################################################################
|
||||||
|
|
||||||
|
#Hostname "localhost"
|
||||||
|
FQDNLookup false
|
||||||
|
#BaseDir "/var/lib/collectd"
|
||||||
|
#PluginDir "/usr/lib/collectd"
|
||||||
|
TypesDB "/usr/share/collectd/types.db" "/etc/collectd/openwrt.db"
|
||||||
|
|
||||||
|
#----------------------------------------------------------------------------#
|
||||||
|
# Interval at which to query values. This may be overwritten on a per-plugin #
|
||||||
|
# base by using the 'Interval' option of the LoadPlugin block: #
|
||||||
|
# <LoadPlugin foo> #
|
||||||
|
# Interval 60 #
|
||||||
|
# </LoadPlugin> #
|
||||||
|
#----------------------------------------------------------------------------#
|
||||||
|
Interval 30
|
||||||
|
|
||||||
|
#Timeout 2
|
||||||
|
#ReadThreads 5
|
||||||
|
# avoid race conditions if multiple datapoints are packed in a single packet
|
||||||
|
WriteThreads 1
|
||||||
|
|
||||||
|
# Logging
|
||||||
|
LoadPlugin syslog
|
||||||
|
<Plugin syslog>
|
||||||
|
LogLevel info
|
||||||
|
</Plugin>
|
||||||
|
|
||||||
|
# now start collecting
|
||||||
|
LoadPlugin cpu
|
||||||
|
|
||||||
|
# free space
|
||||||
|
LoadPlugin df
|
||||||
|
<Plugin df>
|
||||||
|
# Ignore listed filesystems
|
||||||
|
IgnoreSelected true
|
||||||
|
# and select all virtual crap
|
||||||
|
FSType bdev
|
||||||
|
FSType binfmt_misc
|
||||||
|
FSType cgroup
|
||||||
|
FSType cpuset
|
||||||
|
FSType debugfs
|
||||||
|
FSType devpts
|
||||||
|
FSType devtmpfs
|
||||||
|
FSType hugetlbfs
|
||||||
|
FSType mqueue
|
||||||
|
FSType pipefs
|
||||||
|
FSType proc
|
||||||
|
FSType pstore
|
||||||
|
FSType ramfs
|
||||||
|
FSType rootfs
|
||||||
|
FSType rpc_pipefs
|
||||||
|
FSType securityfs
|
||||||
|
FSType sockfs
|
||||||
|
FSType sysfs
|
||||||
|
FSType tmpfs
|
||||||
|
</Plugin>
|
||||||
|
|
||||||
|
# IOPS
|
||||||
|
LoadPlugin disk
|
||||||
|
|
||||||
|
# LOADAVG
|
||||||
|
LoadPlugin load
|
||||||
|
|
||||||
|
# Ram utilisation
|
||||||
|
LoadPlugin memory
|
||||||
|
|
||||||
|
# SWAP
|
||||||
|
LoadPlugin swap
|
||||||
|
|
||||||
|
# Logged in
|
||||||
|
LoadPlugin users
|
||||||
|
|
||||||
|
# traffic
|
||||||
|
LoadPlugin interface
|
||||||
|
|
||||||
|
# temp, voltage, current, fans via ipmi
|
||||||
|
# all sensors monitored by default
|
||||||
|
LoadPlugin ipmi
|
||||||
|
<Plugin ipmi>
|
||||||
|
# disable some sensors collection
|
||||||
|
IgnoreSelected true
|
||||||
|
Sensor "VRM 2 processor_module (9.2)"
|
||||||
|
Sensor "VRM 1 processor_module (9.1)"
|
||||||
|
Sensor "Power Supply 1 power_supply (10.1)"
|
||||||
|
Sensor "Power Supply 2 power_supply (10.2)"
|
||||||
|
Sensor "Power Supplies power_supply (10.3)"
|
||||||
|
Sensor "UID Light system_chassis (23.1)"
|
||||||
|
Sensor "Int. Health LED system_chassis (23.2)"
|
||||||
|
Sensor "Ext. Health LED system_chassis (23.3)"
|
||||||
|
</Plugin>
|
||||||
|
|
||||||
|
# pick up the lm_sensors stuff
|
||||||
|
LoadPlugin sensors
|
||||||
|
|
||||||
|
# IRQ
|
||||||
|
LoadPlugin irq
|
||||||
|
|
||||||
|
# nginx stats
|
||||||
|
LoadPlugin nginx
|
||||||
|
<Plugin nginx>
|
||||||
|
URL "http://localhost/of2016status"
|
||||||
|
</Plugin>
|
||||||
|
|
||||||
|
# now lets listen/send some data here and there
|
||||||
|
# def port 25826
|
||||||
|
LoadPlugin network
|
||||||
|
<Plugin network>
|
||||||
|
# multicast
|
||||||
|
Listen "239.192.74.66"
|
||||||
|
Listen "ff18::efc0:4a42"
|
||||||
|
# All local interfaces
|
||||||
|
#Listen "0.0.0.0"
|
||||||
|
# listen on test vlans
|
||||||
|
#Listen "10.200.0.1"
|
||||||
|
#Listen "10.203.0.1"
|
||||||
|
#Listen "10.204.0.1"
|
||||||
|
|
||||||
|
# listen on prod vlans
|
||||||
|
#Listen "10.100.0.1"
|
||||||
|
#Listen "10.103.0.1"
|
||||||
|
#Listen "10.104.0.1"
|
||||||
|
Listen "*"
|
||||||
|
ReportStats true
|
||||||
|
</Plugin>
|
||||||
|
|
||||||
|
# entropy statistics
|
||||||
|
LoadPlugin entropy
|
||||||
|
|
||||||
|
# and finaly save the data in graphite
|
||||||
|
LoadPlugin write_graphite
|
||||||
|
<Plugin write_graphite>
|
||||||
|
<Node "localhost">
|
||||||
|
Host "localhost"
|
||||||
|
Port "10001"
|
||||||
|
Protocol "tcp"
|
||||||
|
Prefix "received."
|
||||||
|
LogSendErrors true
|
||||||
|
# store raw numbers and let frontend deal with them
|
||||||
|
StoreRates false
|
||||||
|
# be verbose with metrics store
|
||||||
|
AlwaysAppendDS true
|
||||||
|
</Node>
|
||||||
|
</Plugin>
|
||||||
|
|
||||||
|
LoadPlugin ConnTrack
|
||||||
|
LoadPlugin ContextSwitch
|
||||||
|
|
||||||
|
|
||||||
|
### try to monitor the switches too (SNMP)
|
||||||
|
LoadPlugin snmp
|
||||||
|
<Plugin snmp>
|
||||||
|
# data points
|
||||||
|
<Data "std_traffic">
|
||||||
|
Type "if_octets"
|
||||||
|
Table true
|
||||||
|
Instance "IF-MIB::ifName"
|
||||||
|
Values "IF-MIB::ifHCInOctets" "IF-MIB::ifHCOutOctets"
|
||||||
|
</Data>
|
||||||
|
|
||||||
|
<Data "std_errors">
|
||||||
|
Type "if_errors"
|
||||||
|
Table true
|
||||||
|
Instance "IF-MIB::ifName"
|
||||||
|
Values "IF-MIB::ifInErrors" "IF-MIB::ifOutErrors"
|
||||||
|
</Data>
|
||||||
|
|
||||||
|
# now gather my minnion
|
||||||
|
<Host "coresw">
|
||||||
|
Address "10.20.0.11"
|
||||||
|
Version 2
|
||||||
|
Community "password"
|
||||||
|
Collect "std_traffic" "std_errors"
|
||||||
|
Interval 60
|
||||||
|
</Host>
|
||||||
|
|
||||||
|
<Host "mrvocsw">
|
||||||
|
Address "10.20.0.21"
|
||||||
|
Version 2
|
||||||
|
Community "password"
|
||||||
|
Collect "std_traffic" "std_errors"
|
||||||
|
Interval 60
|
||||||
|
</Host>
|
||||||
|
|
||||||
|
<Host "srvocsw">
|
||||||
|
Address "10.20.0.22"
|
||||||
|
Version 2
|
||||||
|
Community "password"
|
||||||
|
Collect "std_traffic" "std_errors"
|
||||||
|
Interval 60
|
||||||
|
</Host>
|
||||||
|
|
||||||
|
<Host "receptionsw">
|
||||||
|
Address "10.20.0.26"
|
||||||
|
Version 2
|
||||||
|
Community "password"
|
||||||
|
Collect "std_traffic" "std_errors"
|
||||||
|
Interval 60
|
||||||
|
</Host>
|
||||||
|
|
||||||
|
<Host "nocsw">
|
||||||
|
Address "10.20.0.23"
|
||||||
|
Version 2
|
||||||
|
Community "password"
|
||||||
|
Collect "std_traffic" "std_errors"
|
||||||
|
Interval 60
|
||||||
|
</Host>
|
||||||
|
|
||||||
|
<Host "uplinksw">
|
||||||
|
Address "172.31.42.64"
|
||||||
|
Version 2
|
||||||
|
Community "password"
|
||||||
|
Collect "std_traffic" "std_errors"
|
||||||
|
Interval 60
|
||||||
|
</Host>
|
||||||
|
</Plugin>
|
||||||
|
|
||||||
|
# monitor unbound by exec
|
||||||
|
####LoadPlugin exec
|
||||||
|
####<Plugin exec>
|
||||||
|
#### Exec "unbound" "/usr/local/bin/unbound-collectd.sh"
|
||||||
|
####</Plugin>
|
||||||
|
|
||||||
|
# See collectd.conf(5)
|
||||||
|
LoadPlugin unixsock
|
||||||
|
|
||||||
|
<Plugin unixsock>
|
||||||
|
SocketFile "/tmp/collectd.sock"
|
||||||
|
SocketGroup "nagios"
|
||||||
|
SocketPerms "0770"
|
||||||
|
</Plugin>
|
||||||
|
|
||||||
|
LoadPlugin uptime
|
||||||
|
LoadPlugin processes
|
||||||
|
|
|
@ -0,0 +1,4 @@
|
||||||
|
stations value:GAUGE:0:256
|
||||||
|
signal_noise_mw value:GAUGE:0:U
|
||||||
|
signal_power_mw value:GAUGE:0:U
|
||||||
|
|
Loading…
Reference in New Issue