Get link statistics
http://localhost/v1/impairments/{direction}/statsServed over the Unix socket /run/chaosd/chaosd.sock
Returns a LinkStats sample of cumulative egress counters from the managed root qdisc, with monotonic and wall-clock sample timestamps.
The wire shape never carries rates. Poll this endpoint and compute throughput, packets per second, and drop rate from the delta between two samples.
Path parameters
directionstringRequiredThe direction to operate on. Each direction is configured independently. An unknown value returns 400.
port1port2Response
200 · application/jsonStatistics sample. Returns a LinkStats object.
directionstringOptionalport1port2tx_bytesinteger <int64>OptionalTotal bytes sent through the qdisc.
tx_packetsinteger <int64>OptionalTotal packets sent through the qdisc.
droppedinteger <int64>OptionalPackets dropped: queue overflow plus impairment loss.
overlimitsinteger <int64>OptionalTimes the qdisc exceeded its rate ceiling (tbf).
requeuesinteger <int64>OptionalPackets requeued.
backlog_bytesintegerOptionalBytes currently enqueued.
backlog_packetsintegerOptionalPackets currently enqueued.
captured_atinteger <int64>OptionalMonotonic sample time in nanoseconds.
captured_at_wallinteger <int64>OptionalWall-clock sample time in nanoseconds since the Unix epoch.
Errors
Unknown direction or malformed body.
Backend or I/O error.
