iPXE
Data Fields
ip_statistics Struct Reference

IP system statistics. More...

#include <ipstat.h>

Data Fields

unsigned long in_receives
 ipSystemStatsInReceives More...
 
unsigned long in_octets
 ipSystemStatsInOctets More...
 
unsigned long in_hdr_errors
 ipSystemStatsInHdrErrors More...
 
unsigned long in_addr_errors
 ipSystemStatsInAddrErrors More...
 
unsigned long in_unknown_protos
 ipSystemStatsInUnknownProtos More...
 
unsigned long in_truncated_pkts
 ipSystemStatsInTruncatedPkts More...
 
unsigned long reasm_reqds
 ipSystemStatsReasmReqds More...
 
unsigned long reasm_oks
 ipSystemStatsReasmOks More...
 
unsigned long reasm_fails
 ipSystemStatsReasmFails More...
 
unsigned long in_delivers
 ipSystemStatsInDelivers More...
 
unsigned long out_requests
 ipSystemStatsOutRequests More...
 
unsigned long out_no_routes
 ipSystemStatsOutNoRoutes More...
 
unsigned long out_transmits
 ipSystemStatsOutTransmits More...
 
unsigned long out_octets
 ipSystemStatsOutOctets More...
 
unsigned long in_mcast_pkts
 ipSystemStatsInMcastPkts More...
 
unsigned long out_mcast_pkts
 ipSystemStatsOutMcastPkts More...
 
unsigned long in_bcast_pkts
 ipSystemStatsInBcastPkts More...
 
unsigned long out_bcast_pkts
 ipSystemStatsOutBcastPkts More...
 

Detailed Description

IP system statistics.

Definitions are taken from the RFC4293 section 5 "ipSystemStatsEntry" table.

To minimise code size, we use "unsigned long" as the counter variable type regardless of whether this type is 32-bit or 64-bit. On a 32-bit build (e.g. the standard BIOS build), this means that we omit the "high capacity" 64-bit counters (prefixed with "HC"). This reduces the code size required to maintain the counter values, and avoids the need to support the "%lld" format in vsprintf.c (which would require dragging in the 64-bit division library on a standard 32-bit build). Since total available memory in a 32-bit environment is limited to 4GB, it is unlikely that we will overflow even the 32-bit octet counters under normal operation.

Counters relating to packet forwarding are omitted, since iPXE includes no functionality for acting as a router.

Counters related to output fragmentation are omitted, since iPXE has no support for fragmenting transmitted packets.

The ipSystemStatsInDiscards and ipSystemStatsOutDiscards counters are omitted, since they will always be zero.

Separate octet counters for multicast packets are omitted to save code size.

Definition at line 44 of file ipstat.h.

Field Documentation

◆ in_receives

unsigned long ip_statistics::in_receives

ipSystemStatsInReceives

The total number of input IP datagrams received, including those received in error.

Definition at line 50 of file ipstat.h.

Referenced by ipstat(), ipv4_rx(), and ipv6_rx().

◆ in_octets

unsigned long ip_statistics::in_octets

ipSystemStatsInOctets

The total number of octets received in input IP datagrams, including those received in error. Octets from datagrams counted in ipSystemStatsInReceives MUST be counted here.

Definition at line 57 of file ipstat.h.

Referenced by ipstat(), ipv4_rx(), and ipv6_rx().

◆ in_hdr_errors

unsigned long ip_statistics::in_hdr_errors

ipSystemStatsInHdrErrors

The number of input IP datagrams discarded due to errors in their IP headers, including version number mismatch, other format errors, hop count exceeded, errors discovered in processing their IP options, etc.

Definition at line 65 of file ipstat.h.

Referenced by ipstat(), ipv4_rx(), and ipv6_rx().

◆ in_addr_errors

unsigned long ip_statistics::in_addr_errors

ipSystemStatsInAddrErrors

The number of input IP datagrams discarded because the IP address in their IP header's destination field was not a valid address to be received at this entity. This count includes invalid addresses (e.g., ::0). For entities that are not IP routers and therefore do not forward datagrams, this counter includes datagrams discarded because the destination address was not a local address.

Definition at line 76 of file ipstat.h.

Referenced by ipstat(), ipv4_rx(), and ipv6_rx().

◆ in_unknown_protos

unsigned long ip_statistics::in_unknown_protos

ipSystemStatsInUnknownProtos

The number of locally-addressed IP datagrams received successfully but discarded because of an unknown or unsupported protocol.

Definition at line 83 of file ipstat.h.

Referenced by ipstat(), and tcpip_rx().

◆ in_truncated_pkts

unsigned long ip_statistics::in_truncated_pkts

ipSystemStatsInTruncatedPkts

The number of input IP datagrams discarded because the datagram frame didn't carry enough data.

Definition at line 89 of file ipstat.h.

Referenced by ipstat(), ipv4_rx(), and ipv6_rx().

◆ reasm_reqds

unsigned long ip_statistics::reasm_reqds

ipSystemStatsReasmReqds

The number of IP fragments received that needed to be reassembled at this interface.

Definition at line 95 of file ipstat.h.

Referenced by fragment_reassemble(), and ipstat().

◆ reasm_oks

unsigned long ip_statistics::reasm_oks

ipSystemStatsReasmOks

The number of IP datagrams successfully reassembled.

Definition at line 100 of file ipstat.h.

Referenced by fragment_reassemble(), and ipstat().

◆ reasm_fails

unsigned long ip_statistics::reasm_fails

ipSystemStatsReasmFails

The number of failures detected by the IP re-assembly algorithm (for whatever reason: timed out, errors, etc.). Note that this is not necessarily a count of discarded IP fragments since some algorithms (notably the algorithm in RFC 815) can lose track of the number of fragments by combining them as they are received.

Definition at line 110 of file ipstat.h.

Referenced by fragment_expired(), fragment_reassemble(), and ipstat().

◆ in_delivers

unsigned long ip_statistics::in_delivers

ipSystemStatsInDelivers

The total number of datagrams successfully delivered to IP user-protocols (including ICMP).

Definition at line 116 of file ipstat.h.

Referenced by ipstat(), and tcpip_rx().

◆ out_requests

unsigned long ip_statistics::out_requests

ipSystemStatsOutRequests

The total number of IP datagrams that local IP user- protocols (including ICMP) supplied to IP in requests for transmission.

Definition at line 123 of file ipstat.h.

Referenced by ipstat(), ipv4_tx(), and ipv6_tx().

◆ out_no_routes

unsigned long ip_statistics::out_no_routes

ipSystemStatsOutNoRoutes

The number of locally generated IP datagrams discarded because no route could be found to transmit them to their destination.

Definition at line 130 of file ipstat.h.

Referenced by ipstat(), ipv4_tx(), and ipv6_tx().

◆ out_transmits

unsigned long ip_statistics::out_transmits

ipSystemStatsOutTransmits

The total number of IP datagrams that this entity supplied to the lower layers for transmission. This includes datagrams generated locally and those forwarded by this entity.

Definition at line 138 of file ipstat.h.

Referenced by ipstat(), ipv4_tx(), and ipv6_tx().

◆ out_octets

unsigned long ip_statistics::out_octets

ipSystemStatsOutOctets

The total number of octets in IP datagrams delivered to the lower layers for transmission. Octets from datagrams counted in ipSystemStatsOutTransmits MUST be counted here.

Definition at line 145 of file ipstat.h.

Referenced by ipstat(), ipv4_tx(), and ipv6_tx().

◆ in_mcast_pkts

unsigned long ip_statistics::in_mcast_pkts

ipSystemStatsInMcastPkts

The number of IP multicast datagrams received.

Definition at line 150 of file ipstat.h.

Referenced by ipstat(), ipv4_rx(), and ipv6_rx().

◆ out_mcast_pkts

unsigned long ip_statistics::out_mcast_pkts

ipSystemStatsOutMcastPkts

The number of IP multicast datagrams transmitted.

Definition at line 155 of file ipstat.h.

Referenced by ipstat(), ipv4_tx(), and ipv6_tx().

◆ in_bcast_pkts

unsigned long ip_statistics::in_bcast_pkts

ipSystemStatsInBcastPkts

The number of IP broadcast datagrams received.

Definition at line 160 of file ipstat.h.

Referenced by ipstat(), ipv4_rx(), and ipv6_rx().

◆ out_bcast_pkts

unsigned long ip_statistics::out_bcast_pkts

ipSystemStatsOutBcastPkts

The number of IP broadcast datagrams transmitted.

Definition at line 165 of file ipstat.h.

Referenced by ipstat(), and ipv4_tx().


The documentation for this struct was generated from the following file: