Host

Host

Status: Development

type: host

Description: A host is defined as a computing instance. For example, physical servers, virtual machines, switches or disk array.

Attributes:

RoleKeyStabilityRequirement LevelValue TypeDescriptionExample Values
Identityhost.idDevelopmentRecommendedstringUnique host ID, determined by the first matching source in the priority order. [1]fdbf79e8af94cb7f9e8df36789187052
Descriptionhost.archDevelopmentRecommendedstringThe CPU architecture the host system is running on.amd64; arm32; arm64 (see more)
Descriptionhost.image.idDevelopmentRecommendedstringVM image ID or host OS image ID. For Cloud, this value is from the provider.ami-07b06b442921831e5
Descriptionhost.image.nameDevelopmentRecommendedstringName of the VM image or OS install the host was instantiated from.infra-ami-eks-worker-node-7d4ec78312; CentOS-8-x86_64-1905
Descriptionhost.image.versionDevelopmentRecommendedstringThe version string of the VM image or host OS as defined in Version Attributes.0.1
Descriptionhost.nameDevelopmentRecommendedstringName of the host. On UNIX systems, it may contain what the hostname command returns, or the fully qualified hostname, or another name specified by the user.opentelemetry-test
Descriptionhost.typeDevelopmentRecommendedstringType of host. For Cloud, this must be the machine type.n1-standard-1
Descriptionhost.ipDevelopmentOpt-Instring[]Available IP addresses of the host, excluding loopback interfaces. [2]["192.168.1.140", "fe80::abc2:4a28:737a:609e"]
Descriptionhost.macDevelopmentOpt-Instring[]Available MAC addresses of the host, excluding loopback interfaces. [3]["AC-DE-48-23-45-67", "AC-DE-48-23-45-67-01-9F"]

[1] host.id: SHOULD be determined using the first available source from the following priority tiers:

  1. Known cloud vendors - cloud instance ID
  2. Known VM vendors - provider VM ID
  3. OS-dependent machine ID
  4. User-provided value

The value SHOULD conform to the following properties:

  • Unique within a given context;
  • Repeatable - multiple observers on the same host come up with the same value;
  • Persistent - survives host restarts and software updates.

Collecting host.id From Known Environments: When host.id is derived from a cloud vendor instance ID, the resource SHOULD also carry the corresponding cloud.provider and cloud.platform attributes so that the source of the host.id value can be unambiguously determined.

The following cloud environments are currently recognized:

Environmenthost.id sourcecloud.providercloud.platform
AWS EC2EC2 instance IDawsaws_ec2
AWS EKS (node)EC2 instance IDawsaws_eks
Azure VMvmIdazureazure.vm
GCP Compute EngineGCE instance IDgcpgcp_compute_engine
GCP GKE (node)GCE instance IDgcpgcp_kubernetes_engine

The listed cloud.provider/cloud.platform values are for example only. Refer to the cloud attribute definitions for the relevant set of values.

Non-privileged Machine ID Lookup: When collecting host.id for non-containerized systems, non-privileged lookups of the machine ID are preferred. SDK detector implementations MUST use the sources listed below to obtain the machine ID.

OSPrimaryFallback
Linuxcontents of /etc/machine-idcontents of /var/lib/dbus/machine-id
BSDcontents of /etc/hostidoutput of /bin/kenv -q smbios.system.uuid
macOSIOPlatformUUID line from the output of /usr/sbin/ioreg -rd1 -c "IOPlatformExpertDevice"-
WindowsMachineGuid from registry HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Cryptography-

Privileged Machine ID Lookup: The host.id can be looked up using privileged sources. For example, Linux systems can use the output of dmidecode -t system, dmidecode -t baseboard, dmidecode -t chassis, or read the corresponding data from the filesystem (e.g. cat /sys/devices/virtual/dmi/id/product_id, cat /sys/devices/virtual/dmi/id/product_uuid, etc), however, SDK resource detector implementations MUST NOT collect host.id from privileged sources. If privileged lookup of host.id is required, the value SHOULD be injected via the OTEL_RESOURCE_ATTRIBUTES environment variable.

Collecting host.id From User Configuration: If none of the above sources yields a non-empty value, the implementation MAY be unable to determine host.id automatically and SHOULD omit the attribute. In that case, the host.id can only be provided through user configuration or other available manual options. Users SHOULD ensure that the host.id value conforms to the properties stated above.

[2] host.ip: IPv4 Addresses MUST be specified in dotted-quad notation. IPv6 addresses MUST be specified in the RFC 5952 format.

[3] host.mac: MAC Addresses MUST be represented in IEEE RA hexadecimal form: as hyphen-separated octets in uppercase hexadecimal form from most to least significant.


host.arch 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
amd64AMD64Development
arm32ARM32Development
arm64ARM64Development
ia64ItaniumDevelopment
ppc3232-bit PowerPCDevelopment
ppc6464-bit PowerPCDevelopment
s390xIBM z/ArchitectureDevelopment
x8632-bit x86Development

Host CPU

Status: Development

type: host.cpu

Description: A host’s CPU information

Attributes:

RoleKeyStabilityRequirement LevelValue TypeDescriptionExample Values
Identityhost.cpu.familyDevelopmentRequiredstringFamily or generation of the CPU.6; PA-RISC 1.1e
Identityhost.cpu.model.idDevelopmentRequiredstringModel identifier. It provides more granular information about the CPU, distinguishing it from other CPUs within the same family.6; 9000/778/B180L
Identityhost.cpu.vendor.idDevelopmentRequiredstringProcessor manufacturer identifier. A maximum 12-character string. [4]GenuineIntel
Descriptionhost.cpu.cache.l2.sizeDevelopmentRecommendedintThe amount of level 2 memory cache available to the processor (in Bytes).12288000
Descriptionhost.cpu.model.nameDevelopmentRecommendedstringModel designation of the processor.11th Gen Intel(R) Core(TM) i7-1185G7 @ 3.00GHz
Descriptionhost.cpu.steppingDevelopmentRecommendedstringStepping or core revisions.1; r1p1

[4] host.cpu.vendor.id: CPUID command returns the vendor ID string in EBX, EDX and ECX registers. Writing these to memory in this order results in a 12-character string.