Network

Network Attributes

These attributes may be used for any network related operation.

AttributeTypeDescriptionExamplesStability
network.carrier.iccstringThe ISO 3166-1 alpha-2 2-character country code associated with the mobile carrier network.DEDevelopment
network.carrier.mccstringThe mobile carrier country code.310Development
network.carrier.mncstringThe mobile carrier network code.001Development
network.carrier.namestringThe name of the mobile carrier.sprintDevelopment
network.connection.statestringThe state of network connection [1]close_waitDevelopment
network.connection.subtypestringThis describes more details regarding the connection.type. It may be the type of cell technology connection, but it could be used for describing details about a wifi connection.LTEDevelopment
network.connection.typestringThe internet connection type.wifiDevelopment
network.interface.namestringThe network interface name.lo; eth0Development
network.io.directionstringThe network IO operation direction.transmitDevelopment
network.local.addressstringLocal address of the network connection - IP address or Unix domain socket name.10.1.2.80; /tmp/my.sockStable
network.local.portintLocal port number of the network connection.65123Stable
network.peer.addressstringPeer address of the network connection - IP address or Unix domain socket name.10.1.2.80; /tmp/my.sockStable
network.peer.portintPeer port number of the network connection.65123Stable
network.protocol.namestringOSI application layer or non-OSI equivalent. [2]amqp; http; mqttStable
network.protocol.versionstringThe actual version of the protocol used for network communication. [3]1.1; 2Stable
network.transportstringOSI transport layer or inter-process communication method. [4]tcp; udpStable
network.typestringOSI network layer or non-OSI equivalent. [5]ipv4; ipv6Stable

[1] network.connection.state: Connection states are defined as part of the rfc9293

[2] network.protocol.name: The value SHOULD be normalized to lowercase.

[3] network.protocol.version: If protocol version is subject to negotiation (for example using ALPN), this attribute SHOULD be set to the negotiated version. If the actual protocol version is not known, this attribute SHOULD NOT be set.

[4] network.transport: The value SHOULD be normalized to lowercase.

Consider always setting the transport when setting a port number, since a port number is ambiguous without knowing the transport. For example different processes could be listening on TCP port 12345 and UDP port 12345.

[5] network.type: The value SHOULD be normalized to lowercase.


network.connection.state has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.

ValueDescriptionStability
close_waitclose_waitDevelopment
closedclosedDevelopment
closingclosingDevelopment
establishedestablishedDevelopment
fin_wait_1fin_wait_1Development
fin_wait_2fin_wait_2Development
last_acklast_ackDevelopment
listenlistenDevelopment
syn_receivedsyn_receivedDevelopment
syn_sentsyn_sentDevelopment
time_waittime_waitDevelopment

network.connection.subtype has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.

ValueDescriptionStability
cdmaCDMADevelopment
cdma2000_1xrttCDMA2000 1XRTTDevelopment
edgeEDGEDevelopment
ehrpdEHRPDDevelopment
evdo_0EVDO Rel. 0Development
evdo_aEVDO Rev. ADevelopment
evdo_bEVDO Rev. BDevelopment
gprsGPRSDevelopment
gsmGSMDevelopment
hsdpaHSDPADevelopment
hspaHSPADevelopment
hspapHSPAPDevelopment
hsupaHSUPADevelopment
idenIDENDevelopment
iwlanIWLANDevelopment
lteLTEDevelopment
lte_caLTE CADevelopment
nr5G NR (New Radio)Development
nrnsa5G NRNSA (New Radio Non-Standalone)Development
td_scdmaTD-SCDMADevelopment
umtsUMTSDevelopment

network.connection.type has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.

ValueDescriptionStability
cellcellDevelopment
unavailableunavailableDevelopment
unknownunknownDevelopment
wifiwifiDevelopment
wiredwiredDevelopment

network.io.direction has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.

ValueDescriptionStability
receivereceiveDevelopment
transmittransmitDevelopment

network.transport has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.

ValueDescriptionStability
pipeNamed or anonymous pipe.Stable
quicQUICDevelopment
tcpTCPStable
udpUDPStable
unixUnix domain socketStable

network.type has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.

ValueDescriptionStability
ipv4IPv4Stable
ipv6IPv6Stable

Deprecated Network Attributes

These attributes may be used for any network related operation.

AttributeTypeDescriptionExamplesStability
net.host.ipstringDeprecated, use network.local.address.192.168.0.1Deprecated
Replaced by network.local.address.
net.host.namestringDeprecated, use server.address.example.comDeprecated
Replaced by server.address.
net.host.portintDeprecated, use server.port.8080Deprecated
Replaced by server.port.
net.peer.ipstringDeprecated, use network.peer.address.127.0.0.1Deprecated
Replaced by network.peer.address.
net.peer.namestringDeprecated, use server.address on client spans and client.address on server spans.example.comDeprecated
Replaced by server.address on client spans and client.address on server spans.
net.peer.portintDeprecated, use server.port on client spans and client.port on server spans.8080Deprecated
Replaced by server.port on client spans and client.port on server spans.
net.protocol.namestringDeprecated, use network.protocol.name.amqp; http; mqttDeprecated
Replaced by network.protocol.name.
net.protocol.versionstringDeprecated, use network.protocol.version.3.1.1Deprecated
Replaced by network.protocol.version.
net.sock.familystringDeprecated, use network.transport and network.type.inet; inet6; unixDeprecated
Split to network.transport and network.type.
net.sock.host.addrstringDeprecated, use network.local.address./var/my.sockDeprecated
Replaced by network.local.address.
net.sock.host.portintDeprecated, use network.local.port.8080Deprecated
Replaced by network.local.port.
net.sock.peer.addrstringDeprecated, use network.peer.address.192.168.0.1Deprecated
Replaced by network.peer.address.
net.sock.peer.namestringDeprecated, no replacement at this time./var/my.sockDeprecated
Removed.
net.sock.peer.portintDeprecated, use network.peer.port.65531Deprecated
Replaced by network.peer.port.
net.transportstringDeprecated, use network.transport.ip_tcp; ip_udp; pipeDeprecated
Replaced by network.transport.

net.sock.family has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.

ValueDescriptionStability
inetIPv4 addressDevelopment
inet6IPv6 addressDevelopment
unixUnix domain socket pathDevelopment

net.transport has the following list of well-known values. If one of them applies, then the respective value MUST be used; otherwise, a custom value MAY be used.

ValueDescriptionStability
inprocIn-process communication. [6]Development
ip_tcpip_tcpDevelopment
ip_udpip_udpDevelopment
otherSomething else (non IP-based).Development
pipeNamed or anonymous pipe.Development

[6]: Signals that there is only in-process communication not using a “real” network protocol in cases where network attributes would normally be expected. Usually all other network attributes can be left out in that case.