---
name: "dtrace_mib"
section: "4"
platform: "freebsd"
package: "base"
version: "16.0-CURRENT-20261027-61c70dc16a79"
release: "FreeBSD 16.0-CURRENT (2026-10-27)"
platforms: ["freebsd"]
url: "https://new.carta.tech/dtrace_mib"
---

# dtrace\_mib(4)

a DTrace provider for Management Information Base

## NAME

**dtrace\_mib** – a DTrace provider for Management Information Base

## SYNOPSIS

**mib:***module***:count:***counter*

In [config(5)](/config/5.md): **options KDTRACE\_MIB\_SDT**

## DESCRIPTION

The **mib** provider allows tracing of Management Information Base stats counters.

The list of instrumented *module*s includes:

- **ah**

  IP Authentication Header (RFC 2402), [ipsec(4)](/ipsec/4.md)

- **esp**

  IP Encapsulating Security Payload (RFC 1827, RFC 2406), [ipsec(4)](/ipsec/4.md)

- **icmp**

  [icmp(4)](/icmp/4.md)

- **icmp6**

  [icmp6(4)](/icmp6/4.md)

- **ip**

  [ip(4)](/ip/4.md)

- **ip6**

  [ip6(4)](/ip6/4.md)

- **ipcomp**

  IP Payload Compression Protocol, [ipsec(4)](/ipsec/4.md)

- **ipsec**

  [ipsec(4)](/ipsec/4.md)

- **tcp**

  [tcp(4)](/tcp/4.md)

- **udp**

  [udp(4)](/udp/4.md)

The **mib:***module***:count:***counter* probes fire when the *counter* in *module*s increases.

The first probe argument, *uint64\_t* *args\[0\]*, is the increment that the *counter* will increase by.

Note that some probes like **mib:esp:count:esps\_hist** or **mib:icmp6:count:icp6s\_outhist** provide additional probe-specific arguments.

## EXAMPLES

### Example 1 : Tracing IP Stats Counters

When debugging network issues one common clue is an unexpectedly incrementing error counter. This is helpful, in that it gives us an idea of what might be going wrong, but often these counters may be incremented in different functions.

Trace all **mib** probes in the [ip(4)](/ip/4.md) module and print the current count and a stack trace:

```
# dtrace -n 'mib:ip:count: { printf("%d", arg0); stack(); }'
dtrace: description 'mib:ip:count: ' matched 29 probes
CPU     ID                    FUNCTION:NAME
  7  98784               count:ips_localout 1
              kernel`ip_output+0x17a2
              kernel`udp_send+0xaca
              kernel`sosend_dgram+0x315
              kernel`sousrsend+0x79
              kernel`kern_sendit+0x1be
              kernel`sendit+0x1ab
              kernel`sys_sendmsg+0x5b
              kernel`amd64_syscall+0x169
              kernel`0xffffffff81094b8b
```

## SEE ALSO

[dtrace(1)](/dtrace/1.md), [dtrace\_ip(4)](/dtrace_ip/4.md), [dtrace\_tcp(4)](/dtrace_tcp/4.md), [dtrace\_udp(4)](/dtrace_udp/4.md), [tracing(7)](/tracing/7.md), [sysctl(8)](/sysctl/8.md)

## STANDARDS

The probe descriptions in the FreeBSD **mib** provider are not compatible with those in the Solaris/illumos mib provider.

## AUTHORS

The **mib** provider was added to FreeBSD by Kristof Provost ⟨*kp@FreeBSD.org*⟩.

This manual page was written by Mateusz Piotrowski ⟨*0mp@FreeBSD.org*⟩.
