Skip to content

Format MAC/IP addresses, TCP flags, ICMP types#259

Open
taspelund wants to merge 3 commits into
mainfrom
trey/formatters
Open

Format MAC/IP addresses, TCP flags, ICMP types#259
taspelund wants to merge 3 commits into
mainfrom
trey/formatters

Conversation

@taspelund

Copy link
Copy Markdown

Adds formatters to make life easier when using DTrace to track softnpu.

Before:

ipv4: version 4 ihl 5 diffserv 0 total_len 34 identification 15 flags 2 frag_offset 0 ttl 40 protocol 6 hdr_checksum e444 src c6336502 dst c6336501  

After:

ethernet: dst 33:33:00:00:00:dd src a8:40:25:00:00:06 ether_type 0x0901 (Sidecar)
sidecar: sc_code 1 sc_ingress 3 sc_egress 3 sc_ether_type 0x86dd (IPv6) sc_payload 1701d
arp: ∅
ipv4: ∅
ipv6: version 6 traffic_class 0 flow_label 0 payload_len e next_hdr 0x11 (UDP) hop_limit 1 src fe80::aa40:25ff:fe00:6 dst ff02::dd

Adds formatters to make life easier when using DTrace to track softnpu.

Before:
```
ipv4: version 4 ihl 5 diffserv 0 total_len 34 identification 15 flags 2 frag_offset 0 ttl 40 protocol 6 hdr_checksum e444 src c6336502 dst c6336501  
```

After:
```
ethernet: dst 33:33:00:00:00:dd src a8:40:25:00:00:06 ether_type 0x0901 (Sidecar)
sidecar: sc_code 1 sc_ingress 3 sc_egress 3 sc_ether_type 0x86dd (IPv6) sc_payload 1701d
arp: ∅
ipv4: ∅
ipv6: version 6 traffic_class 0 flow_label 0 payload_len e next_hdr 0x11 (UDP) hop_limit 1 src fe80::aa40:25ff:fe00:6 dst ff02::dd
```

Signed-off-by: Trey Aspelund <trey@oxidecomputer.com>
Signed-off-by: Trey Aspelund <trey@oxidecomputer.com>
Signed-off-by: Trey Aspelund <trey@oxidecomputer.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant