oxidecomputer / oxidecomputer/softnpu
Want functional P4 counters
Nobody has claimed this yet.
- Dominant language
- Rust
- Stars
- 17
- Forks
- 5
- PR merge metrics
- No merged PRs in 30d
Description
swadm counters list shows a handful of different counters that are available, yet swadm counters get <name> returns a 500 whenever you try to dump them:
root@oxz_switch:~# swadm counters list
["Service", "Ingress", "Packet", "Egress", "Ingress_Drop_Port", "Ingress_Drop_Reason"]
root@oxz_switch:~# swadm counters get Ingress_Drop_Port
Error: Error Response: status: 500 Internal Server Error; headers: {"content-type": "application/json", "x-request-id": "d47f850a-0389-4704-a840-47f6b366da5b", "content-length": "124", "date": "Tue, 03 Mar 2026 19:57:10 GMT"}; value: Error { error_code: Some("Internal"), message: "Internal Server Error", request_id: "d47f850a-0389-4704-a840-47f6b366da5b" }
root@oxz_switch:~# swadm counters get Ingress_Drop_Reason
Error: Error Response: status: 500 Internal Server Error; headers: {"content-type": "application/json", "x-request-id": "108a80c0-0237-4153-884d-35edcf43ed9a", "content-length": "124", "date": "Tue, 03 Mar 2026 19:57:23 GMT"}; value: Error { error_code: Some("Internal"), message: "Internal Server Error", request_id: "108a80c0-0237-4153-884d-35edcf43ed9a" }
It would be nice to be able to have the same fidelity in counters on softnpu as we have with a physical npu
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reproducing the failures with the swadm counters list and swadm counters get entry points, especially Ingress_Drop_Port and Ingress_Drop_Reason. Trace where these listed counters are handled and compare them with counters that already return successfully. Done means the listed P4 counters can be retrieved without a 500 and expose fidelity comparable to physical NPU counters.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- rust
- Domain
- networking
- Issue type
- Bug
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100