systemd

package
v0.0.0-...-5655933 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 20, 2023 License: MIT Imports: 13 Imported by: 0

README

systemd 插件

node_exporterfork 并改动

Configuration

enable=false # 设置为true 打开采集
#unit_include=".+"
#unit_exclude=""
enable_start_time_metrics=true #是否采集service unit的启动时间信息 单位秒
enable_task_metrics=true # 是否采集service unit task的metrics
enable_restarts_metrics=true #是否采集service unit重启的次数信息

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Systemd

type Systemd struct {
	config.PluginConfig
	Enable bool `toml:"enable"`

	UnitInclude string `toml:"unit_include"`
	UnitExclude string `toml:"unit_exclude"`

	SystemdPrivate         bool `toml:"systemd_private"`
	EnableTaskMetrics      bool `toml:"enable_task_metrics"`
	EnableRestartMetrics   bool `toml:"enable_restarts_metrics"`
	EnableStartTimeMetrics bool `toml:"enable_start_time_metrics"`
	// contains filtered or unexported fields
}

func (*Systemd) Clone

func (s *Systemd) Clone() inputs.Input

func (*Systemd) Drop

func (s *Systemd) Drop()

func (*Systemd) Gather

func (s *Systemd) Gather(slist *types.SampleList)

Gather gathers metrics from systemd. Dbus collection is done in parallel to reduce wait time for responses.

func (*Systemd) Init

func (s *Systemd) Init() error

Init returns a new Collector exposing systemd statistics.

func (*Systemd) Name

func (s *Systemd) Name() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL