mirror of
				https://github.com/prometheus/node_exporter.git
				synced 2025-08-20 18:33:52 -07:00 
			
		
		
		
	The ethtool_linux looks for ethtool stats with their sanitized name which might be different from the name provisioned by ethtool. This caused node-exporter to return a 0-value for sanitized metrics. This patch works-around the missing key by copying ethtool stats to another map under their sanitized name. Signed-off-by: Guillaume Espanel <guillaume.espanel@ovhcloud.com> Co-authored-by: Guillaume Espanel <guillaume.espanel@ovhcloud.com>
		
			
				
	
	
		
			19 lines
		
	
	
		
			408 B
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
			
		
		
	
	
			19 lines
		
	
	
		
			408 B
		
	
	
	
		
			Plaintext
		
	
	
	
	
	
# ethtool -S eth0
 | 
						|
NIC statistics:
 | 
						|
     tx_packets: 961500
 | 
						|
     rx_packets: 1260062
 | 
						|
     tx_errors: 0
 | 
						|
     rx_errors: 0
 | 
						|
     port.rx_dropped: 12028
 | 
						|
     rx_missed: 401
 | 
						|
     align_errors: 0
 | 
						|
     tx_single_collisions: 0
 | 
						|
     tx_multi_collisions: 0
 | 
						|
     rx_unicast: 1230297
 | 
						|
     rx_broadcast: 5792
 | 
						|
     rx_multicast: 23973
 | 
						|
     tx_aborted: 0
 | 
						|
     tx_underrun: 0
 | 
						|
     duplicate metric: 1
 | 
						|
     duplicate_metric: 2
 |