From 62403d6748c1fc39ca4b257539a3f761ae9f7ba6 Mon Sep 17 00:00:00 2001 From: mhiles Date: Mon, 13 Jul 2020 08:41:04 -0400 Subject: [PATCH 1/9] add fibre channel collector Signed-off-by: mhiles --- collector/fibrechannel_linux.go | 149 ++++++++++++++++++++++++++++++++ 1 file changed, 149 insertions(+) create mode 100644 collector/fibrechannel_linux.go diff --git a/collector/fibrechannel_linux.go b/collector/fibrechannel_linux.go new file mode 100644 index 00000000..42e74365 --- /dev/null +++ b/collector/fibrechannel_linux.go @@ -0,0 +1,149 @@ +// Copyright 2017-2019 The Prometheus Authors +// Licensed under the Apache License, Version 2.0 (the "License"); +// you may not use this file except in compliance with the License. +// You may obtain a copy of the License at +// +// http://www.apache.org/licenses/LICENSE-2.0 +// +// Unless required by applicable law or agreed to in writing, software +// distributed under the License is distributed on an "AS IS" BASIS, +// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +// See the License for the specific language governing permissions and +// limitations under the License. + +// +build linux +// +build !nofibrechannel + +package collector + +import ( + "fmt" + "os" + + "github.com/go-kit/kit/log" + "github.com/go-kit/kit/log/level" + "github.com/prometheus/client_golang/prometheus" + "github.com/prometheus/procfs/sysfs" +) + +const maxUint64 = ^uint64(0) + +type fibrechannelCollector struct { + fs sysfs.FS + metricDescs map[string]*prometheus.Desc + logger log.Logger + subsystem string +} + +func init() { + registerCollector("fibrechannel", defaultEnabled, NewFibreChannelCollector) +} + +// NewFibreChannelCollector returns a new Collector exposing FibreChannel stats. +func NewFibreChannelCollector(logger log.Logger) (Collector, error) { + var i fibrechannelCollector + var err error + + i.fs, err = sysfs.NewFS(*sysPath) + if err != nil { + return nil, fmt.Errorf("failed to open sysfs: %w", err) + } + i.logger = logger + + // Detailed description for all metrics. + descriptions := map[string]string{ + "dumped_frames": "", + "loss_of_signal_count": "Number of times signal has been lost", + "loss_of_sync_count": "Number of failures on either bit or transmission word boundaries", + "rx_frames": "Number of frames received", + "error_frames": "Number of errors in frames", + "invalid_tx_word_count": "Number of invalid words transmitted by host port", + "seconds_since_last_reset": "Number of seconds since last host port reset", + "tx_words": "Number of words transmitted by host port", + "invalid_crc_count": "Invalid Cyclic Redundancy Check count", + "nos_count": "Number Not_Operational Primitive Sequence received by host port", + "fcp_packet_aborts": "Number of aborted packets", + "rx_words": "Number of words received by host port", + "tx_frames": "Number of frames transmitted by host port", + "link_failure_count": "Number of times the host port link has failed", + "name": "Name of Fibre Channel HBA", + "speed": "Current operating speed", + "port_state": "Current port state", + "port_type": "Port type, what the port is connected to", + "symbolic_name": "Symoblic Name", + "node_name": "Node Name as hexadecimal string", + "port_id": "Port ID as string", + "port_name": "Port Name as hexadecimal string", + "fabric_name": "Fabric Name; 0 if PTP", + "dev_loss_tmo": "Device Loss Timeout in seconds", + "supported_classes": "The FC classes supported", + "supported_speeds": "The FC speeds supported", + } + + i.metricDescs = make(map[string]*prometheus.Desc) + i.subsystem = "fibrechannel" + + for metricName, description := range descriptions { + i.metricDescs[metricName] = prometheus.NewDesc( + prometheus.BuildFQName(namespace, i.subsystem, metricName), + description, + []string{"host"}, + nil, + ) + } + + return &i, nil +} + +func (c *fibrechannelCollector) pushMetric(ch chan<- prometheus.Metric, name string, value uint64, host string, valueType prometheus.ValueType) { + ch <- prometheus.MustNewConstMetric(c.metricDescs[name], valueType, float64(value), host) +} + +func (c *fibrechannelCollector) pushCounter(ch chan<- prometheus.Metric, name string, value uint64, host string) { + // Don't push counters that aren't implemented (a counter equal to maxUint64 is unimplemented by the HBA firmware) + if value != maxUint64 { + c.pushMetric(ch, name, value, host, prometheus.CounterValue) + } +} + +func (c *fibrechannelCollector) Update(ch chan<- prometheus.Metric) error { + hosts, err := c.fs.FibreChannelClass() + if err != nil { + if os.IsNotExist(err) { + level.Debug(c.logger).Log("msg", "fibrechannel statistics not found, skipping") + return ErrNoData + } + return fmt.Errorf("error obtaining FibreChannel class info: %s", err) + } + + for _, host := range hosts { + infoDesc := prometheus.NewDesc( + prometheus.BuildFQName(namespace, c.subsystem, "info"), + "Non-numeric data from /sys/class/fc_host/, value is always 1.", + []string{"host", "speed", "port_state", "port_type", "port_id", "port_name", "fabric_name", "symbolic_name", "supported_classes", "supported_speeds", "dev_loss_tmo"}, + nil, + ) + infoValue := 1.0 + + // First push the Host values + ch <- prometheus.MustNewConstMetric(infoDesc, prometheus.GaugeValue, infoValue, host.Name, host.Speed, host.PortState, host.PortType, host.PortID, host.PortName, host.FabricName, host.SymbolicName, host.SupportedClasses, host.SupportedSpeeds, host.DevLossTMO) + + // Then the counters + c.pushCounter(ch, "dumped_frames", host.Counters.DumpedFrames, host.Name) + c.pushCounter(ch, "error_frames", host.Counters.ErrorFrames, host.Name) + c.pushCounter(ch, "invalid_crc_count", host.Counters.InvalidCRCCount, host.Name) + c.pushCounter(ch, "rx_frames", host.Counters.RXFrames, host.Name) + c.pushCounter(ch, "rx_words", host.Counters.RXWords, host.Name) + c.pushCounter(ch, "tx_frames", host.Counters.TXFrames, host.Name) + c.pushCounter(ch, "tx_words", host.Counters.TXWords, host.Name) + c.pushCounter(ch, "seconds_since_last_reset", host.Counters.SecondsSinceLastReset, host.Name) + c.pushCounter(ch, "invalid_tx_word_count", host.Counters.InvalidTXWordCount, host.Name) + c.pushCounter(ch, "link_failure_count", host.Counters.LinkFailureCount, host.Name) + c.pushCounter(ch, "loss_of_sync_count", host.Counters.LossOfSyncCount, host.Name) + c.pushCounter(ch, "loss_of_signal_count", host.Counters.LossOfSignalCount, host.Name) + c.pushCounter(ch, "nos_count", host.Counters.NosCount, host.Name) + c.pushCounter(ch, "fcp_packet_aborts", host.Counters.FCPPacketAborts, host.Name) + } + + return nil +} From 076c953488ac635b494f76fc4c6733919bd57065 Mon Sep 17 00:00:00 2001 From: mhiles Date: Mon, 13 Jul 2020 09:30:19 -0400 Subject: [PATCH 2/9] update fixtures / e2e test for fibre channel Signed-off-by: mhiles --- collector/fixtures/e2e-output.txt | 43 ++++++++++ collector/fixtures/sys.ttar | 134 ++++++++++++++++++++++++++++++ end-to-end-test.sh | 1 + 3 files changed, 178 insertions(+) diff --git a/collector/fixtures/e2e-output.txt b/collector/fixtures/e2e-output.txt index e8a57794..58ff4ae8 100644 --- a/collector/fixtures/e2e-output.txt +++ b/collector/fixtures/e2e-output.txt @@ -629,6 +629,48 @@ node_edac_uncorrectable_errors_total{controller="0"} 5 node_entropy_available_bits 1337 # HELP node_exporter_build_info A metric with a constant '1' value labeled by version, revision, branch, and goversion from which node_exporter was built. # TYPE node_exporter_build_info gauge +# HELP node_fibrechannel_error_frames Number of errors in frames +# TYPE node_fibrechannel_error_frames counter +node_fibrechannel_error_frames{host="host0"} 0 +# HELP node_fibrechannel_fcp_packet_aborts Number of aborted packets +# TYPE node_fibrechannel_fcp_packet_aborts counter +node_fibrechannel_fcp_packet_aborts{host="host0"} 19 +# HELP node_fibrechannel_info Non-numeric data from /sys/class/fc_host/, value is always 1. +# TYPE node_fibrechannel_info gauge +node_fibrechannel_info{dev_loss_tmo="30",fabric_name="0",host="host0",port_id="000002",port_name="1000e0071bce95f2",port_state="Online",port_type="Point-To-Point (direct nport connection)",speed="16 Gbit",supported_classes="Class 3",supported_speeds="4 Gbit, 8 Gbit, 16 Gbit",symbolic_name="Emulex SN1100E2P FV12.4.270.3 DV12.4.0.0. HN:gotest. OS:Linux"} 1 +# HELP node_fibrechannel_invalid_crc_count Invalid Cyclic Redundancy Check count +# TYPE node_fibrechannel_invalid_crc_count counter +node_fibrechannel_invalid_crc_count{host="host0"} 2 +# HELP node_fibrechannel_invalid_tx_word_count Number of invalid words transmitted by host port +# TYPE node_fibrechannel_invalid_tx_word_count counter +node_fibrechannel_invalid_tx_word_count{host="host0"} 8 +# HELP node_fibrechannel_link_failure_count Number of times the host port link has failed +# TYPE node_fibrechannel_link_failure_count counter +node_fibrechannel_link_failure_count{host="host0"} 9 +# HELP node_fibrechannel_loss_of_signal_count Number of times signal has been lost +# TYPE node_fibrechannel_loss_of_signal_count counter +node_fibrechannel_loss_of_signal_count{host="host0"} 17 +# HELP node_fibrechannel_loss_of_sync_count Number of failures on either bit or transmission word boundaries +# TYPE node_fibrechannel_loss_of_sync_count counter +node_fibrechannel_loss_of_sync_count{host="host0"} 16 +# HELP node_fibrechannel_nos_count Number Not_Operational Primitive Sequence received by host port +# TYPE node_fibrechannel_nos_count counter +node_fibrechannel_nos_count{host="host0"} 18 +# HELP node_fibrechannel_rx_frames Number of frames received +# TYPE node_fibrechannel_rx_frames counter +node_fibrechannel_rx_frames{host="host0"} 3 +# HELP node_fibrechannel_rx_words Number of words received by host port +# TYPE node_fibrechannel_rx_words counter +node_fibrechannel_rx_words{host="host0"} 4 +# HELP node_fibrechannel_seconds_since_last_reset Number of seconds since last host port reset +# TYPE node_fibrechannel_seconds_since_last_reset counter +node_fibrechannel_seconds_since_last_reset{host="host0"} 7 +# HELP node_fibrechannel_tx_frames Number of frames transmitted by host port +# TYPE node_fibrechannel_tx_frames counter +node_fibrechannel_tx_frames{host="host0"} 5 +# HELP node_fibrechannel_tx_words Number of words transmitted by host port +# TYPE node_fibrechannel_tx_words counter +node_fibrechannel_tx_words{host="host0"} 6 # HELP node_filefd_allocated File descriptor statistics: allocated. # TYPE node_filefd_allocated gauge node_filefd_allocated 1024 @@ -2628,6 +2670,7 @@ node_scrape_collector_success{collector="diskstats"} 1 node_scrape_collector_success{collector="drbd"} 1 node_scrape_collector_success{collector="edac"} 1 node_scrape_collector_success{collector="entropy"} 1 +node_scrape_collector_success{collector="fibrechannel"} 1 node_scrape_collector_success{collector="filefd"} 1 node_scrape_collector_success{collector="hwmon"} 1 node_scrape_collector_success{collector="infiniband"} 1 diff --git a/collector/fixtures/sys.ttar b/collector/fixtures/sys.ttar index 3e52c609..0392d205 100644 --- a/collector/fixtures/sys.ttar +++ b/collector/fixtures/sys.ttar @@ -38,6 +38,140 @@ SymlinkTo: ../../../devices/system/node/node1 Directory: sys/class Mode: 755 # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Directory: sys/class/fc_host +Mode: 755 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Directory: sys/class/fc_host/host0 +Mode: 755 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/dev_loss_tmo +Lines: 1 +30 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/fabric_name +Lines: 1 +0x0 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/node_name +Lines: 1 +0x2000e0071bce95f2 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/port_id +Lines: 1 +0x000002 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/port_name +Lines: 1 +0x1000e0071bce95f2 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/port_state +Lines: 1 +Online +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/port_type +Lines: 1 +Point-To-Point (direct nport connection) +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/speed +Lines: 1 +16 Gbit +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Directory: sys/class/fc_host/host0/statistics +Mode: 755 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/dumped_frames +Lines: 1 +0xffffffffffffffff +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/error_frames +Lines: 1 +0x0 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/fcp_packet_aborts +Lines: 1 +0x13 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/invalid_crc_count +Lines: 1 +0x2 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/invalid_tx_word_count +Lines: 1 +0x8 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/link_failure_count +Lines: 1 +0x9 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/loss_of_signal_count +Lines: 1 +0x11 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/loss_of_sync_count +Lines: 1 +0x10 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/nos_count +Lines: 1 +0x12 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/rx_frames +Lines: 1 +0x3 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/rx_words +Lines: 1 +0x4 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/seconds_since_last_reset +Lines: 1 +0x7 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/tx_frames +Lines: 1 +0x5 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/statistics/tx_words +Lines: 1 +0x6 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/supported_classes +Lines: 1 +Class 3 +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/supported_speeds +Lines: 1 +4 Gbit, 8 Gbit, 16 Gbit +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - +Path: sys/class/fc_host/host0/symbolic_name +Lines: 1 +Emulex SN1100E2P FV12.4.270.3 DV12.4.0.0. HN:gotest. OS:Linux +Mode: 644 +# ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - Directory: sys/class/hwmon Mode: 755 # ttar - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - diff --git a/end-to-end-test.sh b/end-to-end-test.sh index 961dd27e..e26a3868 100755 --- a/end-to-end-test.sh +++ b/end-to-end-test.sh @@ -14,6 +14,7 @@ enabled_collectors=$(cat << COLLECTORS drbd edac entropy + fibrechannel filefd hwmon infiniband From d80ae383b778b7c151df5b3fdd201ea84befec57 Mon Sep 17 00:00:00 2001 From: mhiles Date: Mon, 13 Jul 2020 10:30:52 -0400 Subject: [PATCH 3/9] conform to metric naming conventions Signed-off-by: mhiles --- collector/fibrechannel_linux.go | 52 +++++++++++----------- collector/fixtures/e2e-output.txt | 72 +++++++++++++++---------------- 2 files changed, 62 insertions(+), 62 deletions(-) diff --git a/collector/fibrechannel_linux.go b/collector/fibrechannel_linux.go index 42e74365..429dcd43 100644 --- a/collector/fibrechannel_linux.go +++ b/collector/fibrechannel_linux.go @@ -52,20 +52,20 @@ func NewFibreChannelCollector(logger log.Logger) (Collector, error) { // Detailed description for all metrics. descriptions := map[string]string{ - "dumped_frames": "", - "loss_of_signal_count": "Number of times signal has been lost", - "loss_of_sync_count": "Number of failures on either bit or transmission word boundaries", - "rx_frames": "Number of frames received", - "error_frames": "Number of errors in frames", - "invalid_tx_word_count": "Number of invalid words transmitted by host port", + "dumped_frames_total": "Number of dumped frames", + "loss_of_signal_total": "Number of times signal has been lost", + "loss_of_sync_total": "Number of failures on either bit or transmission word boundaries", + "rx_frames_total": "Number of frames received", + "error_frames_total": "Number of errors in frames", + "invalid_tx_word_total": "Number of invalid words transmitted by host port", "seconds_since_last_reset": "Number of seconds since last host port reset", - "tx_words": "Number of words transmitted by host port", - "invalid_crc_count": "Invalid Cyclic Redundancy Check count", - "nos_count": "Number Not_Operational Primitive Sequence received by host port", - "fcp_packet_aborts": "Number of aborted packets", - "rx_words": "Number of words received by host port", - "tx_frames": "Number of frames transmitted by host port", - "link_failure_count": "Number of times the host port link has failed", + "tx_words_total": "Number of words transmitted by host port", + "invalid_crc_total": "Invalid Cyclic Redundancy Check count", + "nos_total": "Number Not_Operational Primitive Sequence received by host port", + "fcp_packet_aborts_total": "Number of aborted packets", + "rx_words_total": "Number of words received by host port", + "tx_frames_total": "Number of frames transmitted by host port", + "link_failure_total": "Number of times the host port link has failed", "name": "Name of Fibre Channel HBA", "speed": "Current operating speed", "port_state": "Current port state", @@ -129,20 +129,20 @@ func (c *fibrechannelCollector) Update(ch chan<- prometheus.Metric) error { ch <- prometheus.MustNewConstMetric(infoDesc, prometheus.GaugeValue, infoValue, host.Name, host.Speed, host.PortState, host.PortType, host.PortID, host.PortName, host.FabricName, host.SymbolicName, host.SupportedClasses, host.SupportedSpeeds, host.DevLossTMO) // Then the counters - c.pushCounter(ch, "dumped_frames", host.Counters.DumpedFrames, host.Name) - c.pushCounter(ch, "error_frames", host.Counters.ErrorFrames, host.Name) - c.pushCounter(ch, "invalid_crc_count", host.Counters.InvalidCRCCount, host.Name) - c.pushCounter(ch, "rx_frames", host.Counters.RXFrames, host.Name) - c.pushCounter(ch, "rx_words", host.Counters.RXWords, host.Name) - c.pushCounter(ch, "tx_frames", host.Counters.TXFrames, host.Name) - c.pushCounter(ch, "tx_words", host.Counters.TXWords, host.Name) + c.pushCounter(ch, "dumped_frames_total", host.Counters.DumpedFrames, host.Name) + c.pushCounter(ch, "error_frames_total", host.Counters.ErrorFrames, host.Name) + c.pushCounter(ch, "invalid_crc_total", host.Counters.InvalidCRCCount, host.Name) + c.pushCounter(ch, "rx_frames_total", host.Counters.RXFrames, host.Name) + c.pushCounter(ch, "rx_words_total", host.Counters.RXWords, host.Name) + c.pushCounter(ch, "tx_frames_total", host.Counters.TXFrames, host.Name) + c.pushCounter(ch, "tx_words_total", host.Counters.TXWords, host.Name) c.pushCounter(ch, "seconds_since_last_reset", host.Counters.SecondsSinceLastReset, host.Name) - c.pushCounter(ch, "invalid_tx_word_count", host.Counters.InvalidTXWordCount, host.Name) - c.pushCounter(ch, "link_failure_count", host.Counters.LinkFailureCount, host.Name) - c.pushCounter(ch, "loss_of_sync_count", host.Counters.LossOfSyncCount, host.Name) - c.pushCounter(ch, "loss_of_signal_count", host.Counters.LossOfSignalCount, host.Name) - c.pushCounter(ch, "nos_count", host.Counters.NosCount, host.Name) - c.pushCounter(ch, "fcp_packet_aborts", host.Counters.FCPPacketAborts, host.Name) + c.pushCounter(ch, "invalid_tx_word_total", host.Counters.InvalidTXWordCount, host.Name) + c.pushCounter(ch, "link_failure_total", host.Counters.LinkFailureCount, host.Name) + c.pushCounter(ch, "loss_of_sync_total", host.Counters.LossOfSyncCount, host.Name) + c.pushCounter(ch, "loss_of_signal_total", host.Counters.LossOfSignalCount, host.Name) + c.pushCounter(ch, "nos_total", host.Counters.NosCount, host.Name) + c.pushCounter(ch, "fcp_packet_aborts_total", host.Counters.FCPPacketAborts, host.Name) } return nil diff --git a/collector/fixtures/e2e-output.txt b/collector/fixtures/e2e-output.txt index 58ff4ae8..e0614d1a 100644 --- a/collector/fixtures/e2e-output.txt +++ b/collector/fixtures/e2e-output.txt @@ -629,48 +629,48 @@ node_edac_uncorrectable_errors_total{controller="0"} 5 node_entropy_available_bits 1337 # HELP node_exporter_build_info A metric with a constant '1' value labeled by version, revision, branch, and goversion from which node_exporter was built. # TYPE node_exporter_build_info gauge -# HELP node_fibrechannel_error_frames Number of errors in frames -# TYPE node_fibrechannel_error_frames counter -node_fibrechannel_error_frames{host="host0"} 0 -# HELP node_fibrechannel_fcp_packet_aborts Number of aborted packets -# TYPE node_fibrechannel_fcp_packet_aborts counter -node_fibrechannel_fcp_packet_aborts{host="host0"} 19 +# HELP node_fibrechannel_error_frames_total Number of errors in frames +# TYPE node_fibrechannel_error_frames_total counter +node_fibrechannel_error_frames_total{host="host0"} 0 +# HELP node_fibrechannel_fcp_packet_aborts_total Number of aborted packets +# TYPE node_fibrechannel_fcp_packet_aborts_total counter +node_fibrechannel_fcp_packet_aborts_total{host="host0"} 19 # HELP node_fibrechannel_info Non-numeric data from /sys/class/fc_host/, value is always 1. # TYPE node_fibrechannel_info gauge node_fibrechannel_info{dev_loss_tmo="30",fabric_name="0",host="host0",port_id="000002",port_name="1000e0071bce95f2",port_state="Online",port_type="Point-To-Point (direct nport connection)",speed="16 Gbit",supported_classes="Class 3",supported_speeds="4 Gbit, 8 Gbit, 16 Gbit",symbolic_name="Emulex SN1100E2P FV12.4.270.3 DV12.4.0.0. HN:gotest. OS:Linux"} 1 -# HELP node_fibrechannel_invalid_crc_count Invalid Cyclic Redundancy Check count -# TYPE node_fibrechannel_invalid_crc_count counter -node_fibrechannel_invalid_crc_count{host="host0"} 2 -# HELP node_fibrechannel_invalid_tx_word_count Number of invalid words transmitted by host port -# TYPE node_fibrechannel_invalid_tx_word_count counter -node_fibrechannel_invalid_tx_word_count{host="host0"} 8 -# HELP node_fibrechannel_link_failure_count Number of times the host port link has failed -# TYPE node_fibrechannel_link_failure_count counter -node_fibrechannel_link_failure_count{host="host0"} 9 -# HELP node_fibrechannel_loss_of_signal_count Number of times signal has been lost -# TYPE node_fibrechannel_loss_of_signal_count counter -node_fibrechannel_loss_of_signal_count{host="host0"} 17 -# HELP node_fibrechannel_loss_of_sync_count Number of failures on either bit or transmission word boundaries -# TYPE node_fibrechannel_loss_of_sync_count counter -node_fibrechannel_loss_of_sync_count{host="host0"} 16 -# HELP node_fibrechannel_nos_count Number Not_Operational Primitive Sequence received by host port -# TYPE node_fibrechannel_nos_count counter -node_fibrechannel_nos_count{host="host0"} 18 -# HELP node_fibrechannel_rx_frames Number of frames received -# TYPE node_fibrechannel_rx_frames counter -node_fibrechannel_rx_frames{host="host0"} 3 -# HELP node_fibrechannel_rx_words Number of words received by host port -# TYPE node_fibrechannel_rx_words counter -node_fibrechannel_rx_words{host="host0"} 4 +# HELP node_fibrechannel_invalid_crc_total Invalid Cyclic Redundancy Check count +# TYPE node_fibrechannel_invalid_crc_total counter +node_fibrechannel_invalid_crc_total{host="host0"} 2 +# HELP node_fibrechannel_invalid_tx_word_total Number of invalid words transmitted by host port +# TYPE node_fibrechannel_invalid_tx_word_total counter +node_fibrechannel_invalid_tx_word_total{host="host0"} 8 +# HELP node_fibrechannel_link_failure_total Number of times the host port link has failed +# TYPE node_fibrechannel_link_failure_total counter +node_fibrechannel_link_failure_total{host="host0"} 9 +# HELP node_fibrechannel_loss_of_signal_total Number of times signal has been lost +# TYPE node_fibrechannel_loss_of_signal_total counter +node_fibrechannel_loss_of_signal_total{host="host0"} 17 +# HELP node_fibrechannel_loss_of_sync_total Number of failures on either bit or transmission word boundaries +# TYPE node_fibrechannel_loss_of_sync_total counter +node_fibrechannel_loss_of_sync_total{host="host0"} 16 +# HELP node_fibrechannel_nos_total Number Not_Operational Primitive Sequence received by host port +# TYPE node_fibrechannel_nos_total counter +node_fibrechannel_nos_total{host="host0"} 18 +# HELP node_fibrechannel_rx_frames_total Number of frames received +# TYPE node_fibrechannel_rx_frames_total counter +node_fibrechannel_rx_frames_total{host="host0"} 3 +# HELP node_fibrechannel_rx_words_total Number of words received by host port +# TYPE node_fibrechannel_rx_words_total counter +node_fibrechannel_rx_words_total{host="host0"} 4 # HELP node_fibrechannel_seconds_since_last_reset Number of seconds since last host port reset # TYPE node_fibrechannel_seconds_since_last_reset counter node_fibrechannel_seconds_since_last_reset{host="host0"} 7 -# HELP node_fibrechannel_tx_frames Number of frames transmitted by host port -# TYPE node_fibrechannel_tx_frames counter -node_fibrechannel_tx_frames{host="host0"} 5 -# HELP node_fibrechannel_tx_words Number of words transmitted by host port -# TYPE node_fibrechannel_tx_words counter -node_fibrechannel_tx_words{host="host0"} 6 +# HELP node_fibrechannel_tx_frames_total Number of frames transmitted by host port +# TYPE node_fibrechannel_tx_frames_total counter +node_fibrechannel_tx_frames_total{host="host0"} 5 +# HELP node_fibrechannel_tx_words_total Number of words transmitted by host port +# TYPE node_fibrechannel_tx_words_total counter +node_fibrechannel_tx_words_total{host="host0"} 6 # HELP node_filefd_allocated File descriptor statistics: allocated. # TYPE node_filefd_allocated gauge node_filefd_allocated 1024 From 10f6841cafee7237060de71a3819eb9f1f2b9cfa Mon Sep 17 00:00:00 2001 From: mhiles Date: Mon, 13 Jul 2020 12:00:43 -0400 Subject: [PATCH 4/9] counter compliance again Signed-off-by: mhiles --- collector/fibrechannel_linux.go | 54 +++++++++++++++---------------- collector/fixtures/e2e-output.txt | 6 ++-- 2 files changed, 30 insertions(+), 30 deletions(-) diff --git a/collector/fibrechannel_linux.go b/collector/fibrechannel_linux.go index 429dcd43..50f96c81 100644 --- a/collector/fibrechannel_linux.go +++ b/collector/fibrechannel_linux.go @@ -52,32 +52,32 @@ func NewFibreChannelCollector(logger log.Logger) (Collector, error) { // Detailed description for all metrics. descriptions := map[string]string{ - "dumped_frames_total": "Number of dumped frames", - "loss_of_signal_total": "Number of times signal has been lost", - "loss_of_sync_total": "Number of failures on either bit or transmission word boundaries", - "rx_frames_total": "Number of frames received", - "error_frames_total": "Number of errors in frames", - "invalid_tx_word_total": "Number of invalid words transmitted by host port", - "seconds_since_last_reset": "Number of seconds since last host port reset", - "tx_words_total": "Number of words transmitted by host port", - "invalid_crc_total": "Invalid Cyclic Redundancy Check count", - "nos_total": "Number Not_Operational Primitive Sequence received by host port", - "fcp_packet_aborts_total": "Number of aborted packets", - "rx_words_total": "Number of words received by host port", - "tx_frames_total": "Number of frames transmitted by host port", - "link_failure_total": "Number of times the host port link has failed", - "name": "Name of Fibre Channel HBA", - "speed": "Current operating speed", - "port_state": "Current port state", - "port_type": "Port type, what the port is connected to", - "symbolic_name": "Symoblic Name", - "node_name": "Node Name as hexadecimal string", - "port_id": "Port ID as string", - "port_name": "Port Name as hexadecimal string", - "fabric_name": "Fabric Name; 0 if PTP", - "dev_loss_tmo": "Device Loss Timeout in seconds", - "supported_classes": "The FC classes supported", - "supported_speeds": "The FC speeds supported", + "dumped_frames_total": "Number of dumped frames", + "loss_of_signal_total": "Number of times signal has been lost", + "loss_of_sync_total": "Number of failures on either bit or transmission word boundaries", + "rx_frames_total": "Number of frames received", + "error_frames_total": "Number of errors in frames", + "invalid_tx_word_total": "Number of invalid words transmitted by host port", + "seconds_since_last_reset_total": "Number of seconds since last host port reset", + "tx_words_total": "Number of words transmitted by host port", + "invalid_crc_total": "Invalid Cyclic Redundancy Check count", + "nos_total": "Number Not_Operational Primitive Sequence received by host port", + "fcp_packet_aborts_total": "Number of aborted packets", + "rx_words_total": "Number of words received by host port", + "tx_frames_total": "Number of frames transmitted by host port", + "link_failure_total": "Number of times the host port link has failed", + "name": "Name of Fibre Channel HBA", + "speed": "Current operating speed", + "port_state": "Current port state", + "port_type": "Port type, what the port is connected to", + "symbolic_name": "Symoblic Name", + "node_name": "Node Name as hexadecimal string", + "port_id": "Port ID as string", + "port_name": "Port Name as hexadecimal string", + "fabric_name": "Fabric Name; 0 if PTP", + "dev_loss_tmo": "Device Loss Timeout in seconds", + "supported_classes": "The FC classes supported", + "supported_speeds": "The FC speeds supported", } i.metricDescs = make(map[string]*prometheus.Desc) @@ -136,7 +136,7 @@ func (c *fibrechannelCollector) Update(ch chan<- prometheus.Metric) error { c.pushCounter(ch, "rx_words_total", host.Counters.RXWords, host.Name) c.pushCounter(ch, "tx_frames_total", host.Counters.TXFrames, host.Name) c.pushCounter(ch, "tx_words_total", host.Counters.TXWords, host.Name) - c.pushCounter(ch, "seconds_since_last_reset", host.Counters.SecondsSinceLastReset, host.Name) + c.pushCounter(ch, "seconds_since_last_reset_total", host.Counters.SecondsSinceLastReset, host.Name) c.pushCounter(ch, "invalid_tx_word_total", host.Counters.InvalidTXWordCount, host.Name) c.pushCounter(ch, "link_failure_total", host.Counters.LinkFailureCount, host.Name) c.pushCounter(ch, "loss_of_sync_total", host.Counters.LossOfSyncCount, host.Name) diff --git a/collector/fixtures/e2e-output.txt b/collector/fixtures/e2e-output.txt index e0614d1a..a0ec636e 100644 --- a/collector/fixtures/e2e-output.txt +++ b/collector/fixtures/e2e-output.txt @@ -662,9 +662,9 @@ node_fibrechannel_rx_frames_total{host="host0"} 3 # HELP node_fibrechannel_rx_words_total Number of words received by host port # TYPE node_fibrechannel_rx_words_total counter node_fibrechannel_rx_words_total{host="host0"} 4 -# HELP node_fibrechannel_seconds_since_last_reset Number of seconds since last host port reset -# TYPE node_fibrechannel_seconds_since_last_reset counter -node_fibrechannel_seconds_since_last_reset{host="host0"} 7 +# HELP node_fibrechannel_seconds_since_last_reset_total Number of seconds since last host port reset +# TYPE node_fibrechannel_seconds_since_last_reset_total counter +node_fibrechannel_seconds_since_last_reset_total{host="host0"} 7 # HELP node_fibrechannel_tx_frames_total Number of frames transmitted by host port # TYPE node_fibrechannel_tx_frames_total counter node_fibrechannel_tx_frames_total{host="host0"} 5 From 6e02d5bff1a5c19b5c6e65a1ed42244fa499c147 Mon Sep 17 00:00:00 2001 From: mhiles Date: Fri, 29 Jan 2021 10:28:22 -0500 Subject: [PATCH 5/9] invalid_tx_word_total -> invalid_tx_words_total Signed-off-by: mhiles --- collector/fibrechannel_linux.go | 4 ++-- collector/fixtures/e2e-output.txt | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/collector/fibrechannel_linux.go b/collector/fibrechannel_linux.go index 50f96c81..b0a46537 100644 --- a/collector/fibrechannel_linux.go +++ b/collector/fibrechannel_linux.go @@ -57,7 +57,7 @@ func NewFibreChannelCollector(logger log.Logger) (Collector, error) { "loss_of_sync_total": "Number of failures on either bit or transmission word boundaries", "rx_frames_total": "Number of frames received", "error_frames_total": "Number of errors in frames", - "invalid_tx_word_total": "Number of invalid words transmitted by host port", + "invalid_tx_words_total": "Number of invalid words transmitted by host port", "seconds_since_last_reset_total": "Number of seconds since last host port reset", "tx_words_total": "Number of words transmitted by host port", "invalid_crc_total": "Invalid Cyclic Redundancy Check count", @@ -137,7 +137,7 @@ func (c *fibrechannelCollector) Update(ch chan<- prometheus.Metric) error { c.pushCounter(ch, "tx_frames_total", host.Counters.TXFrames, host.Name) c.pushCounter(ch, "tx_words_total", host.Counters.TXWords, host.Name) c.pushCounter(ch, "seconds_since_last_reset_total", host.Counters.SecondsSinceLastReset, host.Name) - c.pushCounter(ch, "invalid_tx_word_total", host.Counters.InvalidTXWordCount, host.Name) + c.pushCounter(ch, "invalid_tx_words_total", host.Counters.InvalidTXWordCount, host.Name) c.pushCounter(ch, "link_failure_total", host.Counters.LinkFailureCount, host.Name) c.pushCounter(ch, "loss_of_sync_total", host.Counters.LossOfSyncCount, host.Name) c.pushCounter(ch, "loss_of_signal_total", host.Counters.LossOfSignalCount, host.Name) diff --git a/collector/fixtures/e2e-output.txt b/collector/fixtures/e2e-output.txt index a0ec636e..fee00f74 100644 --- a/collector/fixtures/e2e-output.txt +++ b/collector/fixtures/e2e-output.txt @@ -641,8 +641,8 @@ node_fibrechannel_info{dev_loss_tmo="30",fabric_name="0",host="host0",port_id="0 # HELP node_fibrechannel_invalid_crc_total Invalid Cyclic Redundancy Check count # TYPE node_fibrechannel_invalid_crc_total counter node_fibrechannel_invalid_crc_total{host="host0"} 2 -# HELP node_fibrechannel_invalid_tx_word_total Number of invalid words transmitted by host port -# TYPE node_fibrechannel_invalid_tx_word_total counter +# HELP node_fibrechannel_invalid_tx_words_total Number of invalid words transmitted by host port +# TYPE node_fibrechannel_invalid_tx_words_total counter node_fibrechannel_invalid_tx_word_total{host="host0"} 8 # HELP node_fibrechannel_link_failure_total Number of times the host port link has failed # TYPE node_fibrechannel_link_failure_total counter From 19790920b2a9a47da46e089b7fac7d6de97d9b16 Mon Sep 17 00:00:00 2001 From: mhiles Date: Fri, 29 Jan 2021 10:38:45 -0500 Subject: [PATCH 6/9] update fibrechannel fixture Signed-off-by: mhiles --- collector/fixtures/e2e-output.txt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/collector/fixtures/e2e-output.txt b/collector/fixtures/e2e-output.txt index fee00f74..89cabf10 100644 --- a/collector/fixtures/e2e-output.txt +++ b/collector/fixtures/e2e-output.txt @@ -643,7 +643,7 @@ node_fibrechannel_info{dev_loss_tmo="30",fabric_name="0",host="host0",port_id="0 node_fibrechannel_invalid_crc_total{host="host0"} 2 # HELP node_fibrechannel_invalid_tx_words_total Number of invalid words transmitted by host port # TYPE node_fibrechannel_invalid_tx_words_total counter -node_fibrechannel_invalid_tx_word_total{host="host0"} 8 +node_fibrechannel_invalid_tx_words_total{host="host0"} 8 # HELP node_fibrechannel_link_failure_total Number of times the host port link has failed # TYPE node_fibrechannel_link_failure_total counter node_fibrechannel_link_failure_total{host="host0"} 9 From 3fcccd5b14bc2cb8026351f43089988812bf5341 Mon Sep 17 00:00:00 2001 From: Matthew Hiles <15929821+deusnefum@users.noreply.github.com> Date: Tue, 2 Feb 2021 16:40:59 -0500 Subject: [PATCH 7/9] Update collector/fibrechannel_linux.go Co-authored-by: Ben Kochie Signed-off-by: mhiles --- collector/fibrechannel_linux.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/collector/fibrechannel_linux.go b/collector/fibrechannel_linux.go index b0a46537..1db0f1e6 100644 --- a/collector/fibrechannel_linux.go +++ b/collector/fibrechannel_linux.go @@ -1,4 +1,4 @@ -// Copyright 2017-2019 The Prometheus Authors +// Copyright 2021 The Prometheus Authors // Licensed under the Apache License, Version 2.0 (the "License"); // you may not use this file except in compliance with the License. // You may obtain a copy of the License at From 56eba80306be0ccd171979cd56d96e822e4fe0c8 Mon Sep 17 00:00:00 2001 From: mhiles Date: Tue, 2 Feb 2021 18:05:24 -0500 Subject: [PATCH 8/9] add fibrechannel to default list in read me; host -> fc_host to avoid name collision Signed-off-by: mhiles --- README.md | 1 + collector/fibrechannel_linux.go | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/README.md b/README.md index effca34c..983a250d 100644 --- a/README.md +++ b/README.md @@ -37,6 +37,7 @@ diskstats | Exposes disk I/O statistics. | Darwin, Linux, OpenBSD edac | Exposes error detection and correction statistics. | Linux entropy | Exposes available entropy. | Linux exec | Exposes execution statistics. | Dragonfly, FreeBSD +fibrechannel | Exposes fibre channel information and statistics from `/sys/class/fc_host/`. | Linux filefd | Exposes file descriptor statistics from `/proc/sys/fs/file-nr`. | Linux filesystem | Exposes filesystem statistics, such as disk space used. | Darwin, Dragonfly, FreeBSD, Linux, OpenBSD hwmon | Expose hardware monitoring and sensor data from `/sys/class/hwmon/`. | Linux diff --git a/collector/fibrechannel_linux.go b/collector/fibrechannel_linux.go index 1db0f1e6..9c7edf68 100644 --- a/collector/fibrechannel_linux.go +++ b/collector/fibrechannel_linux.go @@ -87,7 +87,7 @@ func NewFibreChannelCollector(logger log.Logger) (Collector, error) { i.metricDescs[metricName] = prometheus.NewDesc( prometheus.BuildFQName(namespace, i.subsystem, metricName), description, - []string{"host"}, + []string{"fc_host"}, nil, ) } From 5a28930e2e93fb2906bd7211fda2c390ad3d8d43 Mon Sep 17 00:00:00 2001 From: mhiles Date: Wed, 3 Feb 2021 09:35:58 -0500 Subject: [PATCH 9/9] change fc_host everywhere, update fixtures Signed-off-by: mhiles --- collector/fibrechannel_linux.go | 2 +- collector/fixtures/e2e-output.txt | 28 ++++++++++++++-------------- 2 files changed, 15 insertions(+), 15 deletions(-) diff --git a/collector/fibrechannel_linux.go b/collector/fibrechannel_linux.go index 9c7edf68..0f1a1b0c 100644 --- a/collector/fibrechannel_linux.go +++ b/collector/fibrechannel_linux.go @@ -120,7 +120,7 @@ func (c *fibrechannelCollector) Update(ch chan<- prometheus.Metric) error { infoDesc := prometheus.NewDesc( prometheus.BuildFQName(namespace, c.subsystem, "info"), "Non-numeric data from /sys/class/fc_host/, value is always 1.", - []string{"host", "speed", "port_state", "port_type", "port_id", "port_name", "fabric_name", "symbolic_name", "supported_classes", "supported_speeds", "dev_loss_tmo"}, + []string{"fc_host", "speed", "port_state", "port_type", "port_id", "port_name", "fabric_name", "symbolic_name", "supported_classes", "supported_speeds", "dev_loss_tmo"}, nil, ) infoValue := 1.0 diff --git a/collector/fixtures/e2e-output.txt b/collector/fixtures/e2e-output.txt index 89cabf10..d4ddf8be 100644 --- a/collector/fixtures/e2e-output.txt +++ b/collector/fixtures/e2e-output.txt @@ -631,46 +631,46 @@ node_entropy_available_bits 1337 # TYPE node_exporter_build_info gauge # HELP node_fibrechannel_error_frames_total Number of errors in frames # TYPE node_fibrechannel_error_frames_total counter -node_fibrechannel_error_frames_total{host="host0"} 0 +node_fibrechannel_error_frames_total{fc_host="host0"} 0 # HELP node_fibrechannel_fcp_packet_aborts_total Number of aborted packets # TYPE node_fibrechannel_fcp_packet_aborts_total counter -node_fibrechannel_fcp_packet_aborts_total{host="host0"} 19 +node_fibrechannel_fcp_packet_aborts_total{fc_host="host0"} 19 # HELP node_fibrechannel_info Non-numeric data from /sys/class/fc_host/, value is always 1. # TYPE node_fibrechannel_info gauge -node_fibrechannel_info{dev_loss_tmo="30",fabric_name="0",host="host0",port_id="000002",port_name="1000e0071bce95f2",port_state="Online",port_type="Point-To-Point (direct nport connection)",speed="16 Gbit",supported_classes="Class 3",supported_speeds="4 Gbit, 8 Gbit, 16 Gbit",symbolic_name="Emulex SN1100E2P FV12.4.270.3 DV12.4.0.0. HN:gotest. OS:Linux"} 1 +node_fibrechannel_info{dev_loss_tmo="30",fabric_name="0",fc_host="host0",port_id="000002",port_name="1000e0071bce95f2",port_state="Online",port_type="Point-To-Point (direct nport connection)",speed="16 Gbit",supported_classes="Class 3",supported_speeds="4 Gbit, 8 Gbit, 16 Gbit",symbolic_name="Emulex SN1100E2P FV12.4.270.3 DV12.4.0.0. HN:gotest. OS:Linux"} 1 # HELP node_fibrechannel_invalid_crc_total Invalid Cyclic Redundancy Check count # TYPE node_fibrechannel_invalid_crc_total counter -node_fibrechannel_invalid_crc_total{host="host0"} 2 +node_fibrechannel_invalid_crc_total{fc_host="host0"} 2 # HELP node_fibrechannel_invalid_tx_words_total Number of invalid words transmitted by host port # TYPE node_fibrechannel_invalid_tx_words_total counter -node_fibrechannel_invalid_tx_words_total{host="host0"} 8 +node_fibrechannel_invalid_tx_words_total{fc_host="host0"} 8 # HELP node_fibrechannel_link_failure_total Number of times the host port link has failed # TYPE node_fibrechannel_link_failure_total counter -node_fibrechannel_link_failure_total{host="host0"} 9 +node_fibrechannel_link_failure_total{fc_host="host0"} 9 # HELP node_fibrechannel_loss_of_signal_total Number of times signal has been lost # TYPE node_fibrechannel_loss_of_signal_total counter -node_fibrechannel_loss_of_signal_total{host="host0"} 17 +node_fibrechannel_loss_of_signal_total{fc_host="host0"} 17 # HELP node_fibrechannel_loss_of_sync_total Number of failures on either bit or transmission word boundaries # TYPE node_fibrechannel_loss_of_sync_total counter -node_fibrechannel_loss_of_sync_total{host="host0"} 16 +node_fibrechannel_loss_of_sync_total{fc_host="host0"} 16 # HELP node_fibrechannel_nos_total Number Not_Operational Primitive Sequence received by host port # TYPE node_fibrechannel_nos_total counter -node_fibrechannel_nos_total{host="host0"} 18 +node_fibrechannel_nos_total{fc_host="host0"} 18 # HELP node_fibrechannel_rx_frames_total Number of frames received # TYPE node_fibrechannel_rx_frames_total counter -node_fibrechannel_rx_frames_total{host="host0"} 3 +node_fibrechannel_rx_frames_total{fc_host="host0"} 3 # HELP node_fibrechannel_rx_words_total Number of words received by host port # TYPE node_fibrechannel_rx_words_total counter -node_fibrechannel_rx_words_total{host="host0"} 4 +node_fibrechannel_rx_words_total{fc_host="host0"} 4 # HELP node_fibrechannel_seconds_since_last_reset_total Number of seconds since last host port reset # TYPE node_fibrechannel_seconds_since_last_reset_total counter -node_fibrechannel_seconds_since_last_reset_total{host="host0"} 7 +node_fibrechannel_seconds_since_last_reset_total{fc_host="host0"} 7 # HELP node_fibrechannel_tx_frames_total Number of frames transmitted by host port # TYPE node_fibrechannel_tx_frames_total counter -node_fibrechannel_tx_frames_total{host="host0"} 5 +node_fibrechannel_tx_frames_total{fc_host="host0"} 5 # HELP node_fibrechannel_tx_words_total Number of words transmitted by host port # TYPE node_fibrechannel_tx_words_total counter -node_fibrechannel_tx_words_total{host="host0"} 6 +node_fibrechannel_tx_words_total{fc_host="host0"} 6 # HELP node_filefd_allocated File descriptor statistics: allocated. # TYPE node_filefd_allocated gauge node_filefd_allocated 1024