nginxvts

package
v0.40.2 Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2022 License: GPL-3.0 Imports: 9 Imported by: 1

README

NGINX VTS monitoring with Netdata

nginxvts can monitor statistics of NGINX which configured with nginx-module-vts.

Metrics

All metrics have "nginxvts." prefix.

Metric Scope Dimensions Units
requests_total global requests requests/s
active_connections global active connections
connections_total global reading, writing, waiting, accepted, handled connections/s
uptime global uptime seconds
shm_usage global max, used bytes
shm_used_node global used nodes
server_requests_total global requests requests/s
server_responses_total global 1xx, 2xx, 3xx, 4xx, 5xx responses/s
server_traffic_total global in, out bytes/s
server_cache_total global miss, bypass, expired, stale, updating, revalidated, hit, scarce events/s

Refer nginx-module-vts for more information.

Configuration

Edit the go.d/nginxvts.conf configuration file using edit-config from the Netdata config directory, which is typically at /etc/netdata.

cd /etc/netdata # Replace this path with your Netdata config directory
sudo ./edit-config go.d/nginxvts.conf

Needs only url to server's stub_status. Here is an example for local and remote servers:

jobs:
  - name: local
    url: http://127.0.0.1/status/format/json
  - name: remote
    url: http://203.0.113.0/status/format/json

For all available options please see module configuration file.

Troubleshooting

To troubleshoot issues with the nginxvts collector, run the go.d.plugin with the debug option enabled. The output should give you clues as to why the collector isn't working.

  • Navigate to the plugins.d directory, usually at /usr/libexec/netdata/plugins.d/. If that's not the case on your system, open netdata.conf and look for the plugins setting under [directories].

    cd /usr/libexec/netdata/plugins.d/
    
  • Switch to the netdata user.

    sudo -u netdata -s
    
  • Run the go.d.plugin to debug the collector:

    ./go.d.plugin -d -m nginxvts
    

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	web.HTTP `yaml:",inline"`
}

type NginxVTS

type NginxVTS struct {
	module.Base
	Config `yaml:",inline"`
	// contains filtered or unexported fields
}

func New

func New() *NginxVTS

func (*NginxVTS) Charts

func (vts *NginxVTS) Charts() *module.Charts

func (*NginxVTS) Check

func (vts *NginxVTS) Check() bool

func (*NginxVTS) Cleanup

func (vts *NginxVTS) Cleanup()

func (*NginxVTS) Collect

func (vts *NginxVTS) Collect() map[string]int64

func (*NginxVTS) Init

func (vts *NginxVTS) Init() bool

type Server

type Server struct {
	RequestCounter int64 `stm:"requestcounter"`
	InBytes        int64 `stm:"inbytes"`
	OutBytes       int64 `stm:"outbytes"`
	Responses      struct {
		Resp1xx     int64 `stm:"responses_1xx" json:"1xx"`
		Resp2xx     int64 `stm:"responses_2xx" json:"2xx"`
		Resp3xx     int64 `stm:"responses_3xx" json:"3xx"`
		Resp4xx     int64 `stm:"responses_4xx" json:"4xx"`
		Resp5xx     int64 `stm:"responses_5xx" json:"5xx"`
		Miss        int64 `stm:"cache_miss"`
		Bypass      int64 `stm:"cache_bypass"`
		Expired     int64 `stm:"cache_expired"`
		Stale       int64 `stm:"cache_stale"`
		Updating    int64 `stm:"cache_updating"`
		Revalidated int64 `stm:"cache_revalidated"`
		Hit         int64 `stm:"cache_hit"`
		Scarce      int64 `stm:"cache_scarce"`
	} `stm:""`
}

Server is for total Nginx server

Jump to

Keyboard shortcuts

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