Documentation ¶
Overview ¶
Package collector includes all individual collectors to gather and export system metrics.
Index ¶
- Variables
- func BusinessMonitorHttpHandle(w http.ResponseWriter, r *http.Request)
- func LogMonitorHttpHandle(w http.ResponseWriter, r *http.Request)
- func ProcessMonitorHttpHandle(w http.ResponseWriter, r *http.Request)
- type Collector
- func BusinessMonitorCollector() (Collector, error)
- func NewARPCollector() (Collector, error)
- func NewBcacheCollector() (Collector, error)
- func NewBondingCollector() (Collector, error)
- func NewBuddyinfoCollector() (Collector, error)
- func NewCPUCollector() (Collector, error)
- func NewCPUFreqCollector() (Collector, error)
- func NewConntrackCollector() (Collector, error)
- func NewDiskstatsCollector() (Collector, error)
- func NewEdacCollector() (Collector, error)
- func NewEntropyCollector() (Collector, error)
- func NewFileFDStatCollector() (Collector, error)
- func NewFilesystemCollector() (Collector, error)
- func NewHwMonCollector() (Collector, error)
- func NewIPVSCollector() (Collector, error)
- func NewInfiniBandCollector() (Collector, error)
- func NewInterruptsCollector() (Collector, error)
- func NewKsmdCollector() (Collector, error)
- func NewLoadavgCollector() (Collector, error)
- func NewLogMonitorCollector() (Collector, error)
- func NewLogindCollector() (Collector, error)
- func NewMdadmCollector() (Collector, error)
- func NewMeminfoCollector() (Collector, error)
- func NewMeminfoNumaCollector() (Collector, error)
- func NewMountStatsCollector() (Collector, error)
- func NewNFSdCollector() (Collector, error)
- func NewNetClassCollector() (Collector, error)
- func NewNetDevCollector() (Collector, error)
- func NewNetStatCollector() (Collector, error)
- func NewNfsCollector() (Collector, error)
- func NewNtpCollector() (Collector, error)
- func NewPerfCollector() (Collector, error)
- func NewPressureStatsCollector() (Collector, error)
- func NewProcessMonitorCollector() (Collector, error)
- func NewProcessStatCollector() (Collector, error)
- func NewQdiscStatCollector() (Collector, error)
- func NewRunitCollector() (Collector, error)
- func NewSchedstatCollector() (Collector, error)
- func NewSockStatCollector() (Collector, error)
- func NewStatCollector() (Collector, error)
- func NewSupervisordCollector() (Collector, error)
- func NewSystemdCollector() (Collector, error)
- func NewTCPStatCollector() (Collector, error)
- func NewTextFileCollector() (Collector, error)
- func NewThermalZoneCollector() (Collector, error)
- func NewTimeCollector() (Collector, error)
- func NewTimexCollector() (Collector, error)
- func NewWifiCollector() (Collector, error)
- func NewXFSCollector() (Collector, error)
- func NewZFSCollector() (Collector, error)
- func NewvmStatCollector() (Collector, error)
- type NodeCollector
Constants ¶
This section is empty.
Variables ¶
var LogCollectorStore logCollectorStrore
var ProcessCacheObj processCache
Functions ¶
func BusinessMonitorHttpHandle ¶
func BusinessMonitorHttpHandle(w http.ResponseWriter, r *http.Request)
func LogMonitorHttpHandle ¶
func LogMonitorHttpHandle(w http.ResponseWriter, r *http.Request)
func ProcessMonitorHttpHandle ¶
func ProcessMonitorHttpHandle(w http.ResponseWriter, r *http.Request)
Types ¶
type Collector ¶
type Collector interface { // Get new metrics and expose them via prometheus registry. Update(ch chan<- prometheus.Metric) error }
Collector is the interface a collector has to implement.
func NewARPCollector ¶
NewARPCollector returns a new Collector exposing ARP stats.
func NewBcacheCollector ¶
NewBcacheCollector returns a newly allocated bcacheCollector. It exposes a number of Linux bcache statistics.
func NewBondingCollector ¶
NewBondingCollector returns a newly allocated bondingCollector. It exposes the number of configured and active slave of linux bonding interfaces.
func NewBuddyinfoCollector ¶
NewBuddyinfoCollector returns a new Collector exposing buddyinfo stats.
func NewCPUCollector ¶
NewCPUCollector returns a new Collector exposing kernel/system statistics.
func NewCPUFreqCollector ¶
NewCPUFreqCollector returns a new Collector exposing kernel/system statistics.
func NewConntrackCollector ¶
NewConntrackCollector returns a new Collector exposing conntrack stats.
func NewDiskstatsCollector ¶
NewDiskstatsCollector returns a new Collector exposing disk device stats. Docs from https://www.kernel.org/doc/Documentation/iostats.txt
func NewEdacCollector ¶
NewEdacCollector returns a new Collector exposing edac stats.
func NewEntropyCollector ¶
NewEntropyCollector returns a new Collector exposing entropy stats.
func NewFileFDStatCollector ¶
NewFileFDStatCollector returns a new Collector exposing file-nr stats.
func NewFilesystemCollector ¶
NewFilesystemCollector returns a new Collector exposing filesystems stats.
func NewHwMonCollector ¶
NewHwMonCollector returns a new Collector exposing /sys/class/hwmon stats (similar to lm-sensors).
func NewIPVSCollector ¶
NewIPVSCollector sets up a new collector for IPVS metrics. It accepts the "procfs" config parameter to override the default proc location (/proc).
func NewInfiniBandCollector ¶
NewInfiniBandCollector returns a new Collector exposing InfiniBand stats.
func NewInterruptsCollector ¶
NewInterruptsCollector returns a new Collector exposing interrupts stats.
func NewKsmdCollector ¶
NewKsmdCollector returns a new Collector exposing kernel/system statistics.
func NewLoadavgCollector ¶
NewLoadavgCollector returns a new Collector exposing load average stats.
func NewLogMonitorCollector ¶
func NewLogindCollector ¶
NewLogindCollector returns a new Collector exposing logind statistics.
func NewMdadmCollector ¶
NewMdadmCollector returns a new Collector exposing raid statistics.
func NewMeminfoCollector ¶
NewMeminfoCollector returns a new Collector exposing memory stats.
func NewMeminfoNumaCollector ¶
NewMeminfoNumaCollector returns a new Collector exposing memory stats.
func NewMountStatsCollector ¶
NewMountStatsCollector returns a new Collector exposing NFS statistics.
func NewNFSdCollector ¶
NewNFSdCollector returns a new Collector exposing /proc/net/rpc/nfsd statistics.
func NewNetClassCollector ¶
NewNetClassCollector returns a new Collector exposing network class stats.
func NewNetDevCollector ¶
NewNetDevCollector returns a new Collector exposing network device stats.
func NewNetStatCollector ¶
NewNetStatCollector takes and returns a new Collector exposing network stats.
func NewNfsCollector ¶
NewNfsCollector returns a new Collector exposing NFS statistics.
func NewNtpCollector ¶
NewNtpCollector returns a new Collector exposing sanity of local NTP server. Default definition of "local" is: - collector.ntp.server address is a loopback address (or collector.ntp.server-is-mine flag is turned on) - the server is reachable with outgoin IP_TTL = 1
func NewPerfCollector ¶
NewPerfCollector returns a new perf based collector, it creates a profiler per CPU.
func NewPressureStatsCollector ¶
NewPressureStatsCollector returns a Collector exposing pressure stall information
func NewProcessStatCollector ¶
NewProcessStatCollector returns a new Collector exposing process data read from the proc filesystem.
func NewQdiscStatCollector ¶
NewQdiscStatCollector returns a new Collector exposing queuing discipline statistics.
func NewRunitCollector ¶
NewRunitCollector returns a new Collector exposing runit statistics.
func NewSchedstatCollector ¶
NewSchedstatCollector returns a new Collector exposing task scheduler statistics
func NewSockStatCollector ¶
NewSockStatCollector returns a new Collector exposing socket stats.
func NewStatCollector ¶
NewStatCollector returns a new Collector exposing kernel/system statistics.
func NewSupervisordCollector ¶
NewSupervisordCollector returns a new Collector exposing supervisord statistics.
func NewSystemdCollector ¶
NewSystemdCollector returns a new Collector exposing systemd statistics.
func NewTCPStatCollector ¶
NewTCPStatCollector returns a new Collector exposing network stats.
func NewTextFileCollector ¶
NewTextFileCollector returns a new Collector exposing metrics read from files in the given textfile directory.
func NewThermalZoneCollector ¶
NewThermalZoneCollector returns a new Collector exposing kernel/system statistics.
func NewTimeCollector ¶
NewTimeCollector returns a new Collector exposing the current system time in seconds since epoch.
func NewTimexCollector ¶
NewTimexCollector returns a new Collector exposing adjtime(3) stats.
func NewWifiCollector ¶
NewWifiCollector returns a new Collector exposing Wifi statistics.
func NewXFSCollector ¶
NewXFSCollector returns a new Collector exposing XFS statistics.
func NewZFSCollector ¶
NewZFSCollector returns a new Collector exposing ZFS statistics.
func NewvmStatCollector ¶
NewvmStatCollector returns a new Collector exposing vmstat stats.
type NodeCollector ¶
NodeCollector implements the prometheus.Collector interface.
func NewNodeCollector ¶
func NewNodeCollector(filters ...string) (*NodeCollector, error)
NewNodeCollector creates a new NodeCollector.
func (NodeCollector) Collect ¶
func (n NodeCollector) Collect(ch chan<- prometheus.Metric)
Collect implements the prometheus.Collector interface.
func (NodeCollector) Describe ¶
func (n NodeCollector) Describe(ch chan<- *prometheus.Desc)
Describe implements the prometheus.Collector interface.
Source Files ¶
- arp_linux.go
- bcache_linux.go
- bonding_linux.go
- buddyinfo.go
- business_monitor_linux.go
- collector.go
- conntrack_linux.go
- cpu_common.go
- cpu_linux.go
- cpufreq_linux.go
- diskstats_common.go
- diskstats_linux.go
- drbd_linux.go
- edac_linux.go
- entropy_linux.go
- filefd_linux.go
- filesystem_common.go
- filesystem_linux.go
- helper.go
- hwmon_linux.go
- infiniband_linux.go
- interrupts_common.go
- interrupts_linux.go
- ipvs_linux.go
- ksmd_linux.go
- loadavg.go
- loadavg_linux.go
- log_monitor_linux.go
- logind_linux.go
- mdadm_linux.go
- meminfo.go
- meminfo_linux.go
- meminfo_numa_linux.go
- mountstats_linux.go
- netclass_linux.go
- netdev_common.go
- netdev_linux.go
- netstat_linux.go
- nfs_linux.go
- nfsd_linux.go
- ntp.go
- paths.go
- perf_linux.go
- pressure_linux.go
- process_monitor_linux.go
- processes_linux.go
- qdisc_linux.go
- runit.go
- schedstat_linux.go
- sockstat_linux.go
- stat_linux.go
- supervisord.go
- systemd_linux.go
- tcpstat_linux.go
- textfile.go
- thermal_zone_linux.go
- time.go
- timex.go
- uname.go
- uname_linux.go
- vmstat_linux.go
- wifi_linux.go
- xfs_linux.go
- zfs.go
- zfs_linux.go