Class: Nl::Linux::Netdev::AttributeSets::Qstats

Inherits:
AttributeSet
  • Object
show all
Defined in:
nl-linux/generated/nl/linux/netdev.rb

Overview

Get device statistics, scoped to a device or a queue. These statistics extend (and partially duplicate) statistics available in struct rtnl_link_stats64. Value of the scope attribute determines how statistics are aggregated. When aggregated for the entire device the statistics represent the total number of events since last explicit reset of the device (i.e. not a reconfiguration like changing queue count). When reported per-queue, however, the statistics may not add up to the total number of events, will only be reported for currently active objects, and will likely report the number of events since last reconfiguration.

Defined Under Namespace

Classes: Attribute, Ifindex, QueueId, QueueType, RxAllocFail, RxBytes, RxCsumBad, RxCsumComplete, RxCsumNone, RxCsumUnnecessary, RxHwDropOverruns, RxHwDropRatelimits, RxHwDrops, RxHwGroBytes, RxHwGroPackets, RxHwGroWireBytes, RxHwGroWirePackets, RxPackets, Scope, TxBytes, TxCsumNone, TxHwDropErrors, TxHwDropRatelimits, TxHwDrops, TxHwGsoBytes, TxHwGsoPackets, TxHwGsoWireBytes, TxHwGsoWirePackets, TxNeedsCsum, TxPackets, TxStop, TxWake

Constant Summary

Constants inherited from AttributeSet

AttributeSet::SELECTOR_NAMES

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from AttributeSet

#<<, #[], build_attributes, decode, #encode, #initialize

Constructor Details

This class inherits a constructor from Nl::AttributeSet

Class Method Details

.by_name(name) ⇒ Attribute

Looks up Attribute class by name.

Parameters:

  • name (Symbol)

Returns:



1450
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1450

def by_name(name); BY_NAME.fetch(name); end

.by_type(type) ⇒ Attribute

Looks up Attribute class by type value.

Parameters:

  • type (Integer)

Returns:



1456
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1456

def by_type(type); BY_TYPE.fetch(type); end

Instance Method Details

#ifindex ⇒ Integer

ifindex of the netdevice to which stats belong.

Returns:

  • (Integer)

See Also:



1260
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1260

def ifindex; self[:"ifindex"]&.value; end

#queue_id ⇒ Integer

Queue ID, if stats are scoped to a single queue instance.

Returns:

  • (Integer)

See Also:



1272
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1272

def queue_id; self[:"queue_id"]&.value; end

#queue_type ⇒ Integer

Queue type as rx, tx, for queue-id.

Known enum values are defined in Enums::QueueType.

Returns:

  • (Integer)

See Also:



1267
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1267

def queue_type; self[:"queue_type"]&.value; end

#rx_alloc_fail ⇒ Integer

Number of times skb or buffer allocation failed on the Rx datapath. Allocation failure may, or may not result in a packet drop, depending on driver implementation and whether system recovers quickly.

Returns:

  • (Integer)

See Also:



1311
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1311

def rx_alloc_fail; self[:"rx_alloc_fail"]&.value; end

#rx_bytes ⇒ Integer

Successfully received bytes, see rx-packets.

Returns:

  • (Integer)

See Also:



1292
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1292

def rx_bytes; self[:"rx_bytes"]&.value; end

#rx_csum_bad ⇒ Integer

Number of packets with bad checksum. The packets are not discarded, but still delivered to the stack.

Returns:

  • (Integer)

See Also:



1346
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1346

def rx_csum_bad; self[:"rx_csum_bad"]&.value; end

#rx_csum_complete ⇒ Integer

Number of packets that were marked as CHECKSUM_COMPLETE.

Returns:

  • (Integer)

See Also:



1330
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1330

def rx_csum_complete; self[:"rx_csum_complete"]&.value; end

#rx_csum_none ⇒ Integer

Number of packets that were not checksummed by device.

Returns:

  • (Integer)

See Also:



1340
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1340

def rx_csum_none; self[:"rx_csum_none"]&.value; end

#rx_csum_unnecessary ⇒ Integer

Number of packets that were marked as CHECKSUM_UNNECESSARY.

Returns:

  • (Integer)

See Also:



1335
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1335

def rx_csum_unnecessary; self[:"rx_csum_unnecessary"]&.value; end

#rx_hw_drop_overruns ⇒ Integer

Number of packets dropped due to transient lack of resources, such as buffer space, host descriptors etc.

Returns:

  • (Integer)

See Also:



1325
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1325

def rx_hw_drop_overruns; self[:"rx_hw_drop_overruns"]&.value; end

#rx_hw_drop_ratelimits ⇒ Integer

Number of the packets dropped by the device due to the received packets bitrate exceeding the device rate limit.

Returns:

  • (Integer)

See Also:



1375
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1375

def rx_hw_drop_ratelimits; self[:"rx_hw_drop_ratelimits"]&.value; end

#rx_hw_drops ⇒ Integer

Number of all packets which entered the device, but never left it, including but not limited to: packets dropped due to lack of buffer space, processing errors, explicit or implicit policies and packet filters.

Returns:

  • (Integer)

See Also:



1319
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1319

def rx_hw_drops; self[:"rx_hw_drops"]&.value; end

#rx_hw_gro_bytes ⇒ Integer

See rx-hw-gro-packets.

Returns:

  • (Integer)

See Also:



1358
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1358

def rx_hw_gro_bytes; self[:"rx_hw_gro_bytes"]&.value; end

#rx_hw_gro_packets ⇒ Integer

Number of packets that were coalesced from smaller packets by the device. Counts only packets coalesced with the HW-GRO netdevice feature, LRO-coalesced packets are not counted.

Returns:

  • (Integer)

See Also:



1353
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1353

def rx_hw_gro_packets; self[:"rx_hw_gro_packets"]&.value; end

#rx_hw_gro_wire_bytes ⇒ Integer

See rx-hw-gro-wire-packets.

Returns:

  • (Integer)

See Also:



1369
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1369

def rx_hw_gro_wire_bytes; self[:"rx_hw_gro_wire_bytes"]&.value; end

#rx_hw_gro_wire_packets ⇒ Integer

Number of packets that were coalesced to bigger packetss with the HW-GRO netdevice feature. LRO-coalesced packets are not counted.

Returns:

  • (Integer)

See Also:



1364
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1364

def rx_hw_gro_wire_packets; self[:"rx_hw_gro_wire_packets"]&.value; end

#rx_packets ⇒ Integer

Number of wire packets successfully received and passed to the stack. For drivers supporting XDP, XDP is considered the first layer of the stack, so packets consumed by XDP are still counted here.

Returns:

  • (Integer)

See Also:



1287
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1287

def rx_packets; self[:"rx_packets"]&.value; end

#scope ⇒ Integer

What object type should be used to iterate over the stats.

Known flags are defined in Flags::QstatsScope.

Returns:

  • (Integer)

See Also:



1280
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1280

def scope; self[:"scope"]&.value; end

#tx_bytes ⇒ Integer

Successfully sent bytes, see tx-packets.

Returns:

  • (Integer)

See Also:



1304
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1304

def tx_bytes; self[:"tx_bytes"]&.value; end

#tx_csum_none ⇒ Integer

Number of packets that did not require the device to calculate the checksum.

Returns:

  • (Integer)

See Also:



1394
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1394

def tx_csum_none; self[:"tx_csum_none"]&.value; end

#tx_hw_drop_errors ⇒ Integer

Number of packets dropped because they were invalid or malformed.

Returns:

  • (Integer)

See Also:



1388
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1388

def tx_hw_drop_errors; self[:"tx_hw_drop_errors"]&.value; end

#tx_hw_drop_ratelimits ⇒ Integer

Number of the packets dropped by the device due to the transmit packets bitrate exceeding the device rate limit.

Returns:

  • (Integer)

See Also:



1429
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1429

def tx_hw_drop_ratelimits; self[:"tx_hw_drop_ratelimits"]&.value; end

#tx_hw_drops ⇒ Integer

Number of packets that arrived at the device but never left it, encompassing packets dropped for reasons such as processing errors, as well as those affected by explicitly defined policies and packet filtering criteria.

Returns:

  • (Integer)

See Also:



1383
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1383

def tx_hw_drops; self[:"tx_hw_drops"]&.value; end

#tx_hw_gso_bytes ⇒ Integer

See tx-hw-gso-packets.

Returns:

  • (Integer)

See Also:



1412
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1412

def tx_hw_gso_bytes; self[:"tx_hw_gso_bytes"]&.value; end

#tx_hw_gso_packets ⇒ Integer

Number of packets that necessitated segmentation into smaller packets by the device.

Returns:

  • (Integer)

See Also:



1407
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1407

def tx_hw_gso_packets; self[:"tx_hw_gso_packets"]&.value; end

#tx_hw_gso_wire_bytes ⇒ Integer

See tx-hw-gso-wire-packets.

Returns:

  • (Integer)

See Also:



1423
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1423

def tx_hw_gso_wire_bytes; self[:"tx_hw_gso_wire_bytes"]&.value; end

#tx_hw_gso_wire_packets ⇒ Integer

Number of wire-sized packets generated by processing tx-hw-gso-packets

Returns:

  • (Integer)

See Also:



1418
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1418

def tx_hw_gso_wire_packets; self[:"tx_hw_gso_wire_packets"]&.value; end

#tx_needs_csum ⇒ Integer

Number of packets that required the device to calculate the checksum. This counter includes the number of GSO wire packets for which device calculated the L4 checksum.

Returns:

  • (Integer)

See Also:



1401
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1401

def tx_needs_csum; self[:"tx_needs_csum"]&.value; end

#tx_packets ⇒ Integer

Number of wire packets successfully sent. Packet is considered to be successfully sent once it is in device memory (usually this means the device has issued a DMA completion for the packet).

Returns:

  • (Integer)

See Also:



1299
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1299

def tx_packets; self[:"tx_packets"]&.value; end

#tx_stop ⇒ Integer

Number of times driver paused accepting new tx packets from the stack to this queue, because the queue was full. Note that if BQL is supported and enabled on the device the networking stack will avoid queuing a lot of data at once.

Returns:

  • (Integer)

See Also:



1437
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1437

def tx_stop; self[:"tx_stop"]&.value; end

#tx_wake ⇒ Integer

Number of times driver re-started accepting send requests to this queue from the stack.

Returns:

  • (Integer)

See Also:



1443
# File 'nl-linux/generated/nl/linux/netdev.rb', line 1443

def tx_wake; self[:"tx_wake"]&.value; end