Skip to content

VOLUME.ADMIN LIST-SEGMENTS

Returns the list of segment IDs for a given volume. Segments are the underlying storage units within a volume. Each segment holds a range of appended data.

VOLUME.ADMIN LIST-SEGMENTS <volume-name>
ParameterTypeDescription
volume-namestringName of the volume, in <kind>-shard-<id> format (e.g. bucket-shard-0)

RESP3 array of integers. Each element is a segment ID (long). Returns an empty array if the volume has no segments.

Loads volume metadata and returns the list of segment IDs as an integer array.

It is available on the management port (default 3320).

ConditionMessage
Missing volume name parameterERR invalid number of parameters
No volume with that name is managed by this memberERR Volume: '<name>' is not open

List segments for an empty volume:

127.0.0.1:3320> VOLUME.ADMIN LIST-SEGMENTS bucket-shard-1
(empty array)

List segments for a volume with data:

127.0.0.1:3320> VOLUME.ADMIN LIST-SEGMENTS bucket-shard-0
1) (integer) 0

Volume not found:

127.0.0.1:3320> VOLUME.ADMIN LIST-SEGMENTS non-existent-volume
(error) ERR Volume: 'non-existent-volume' is not open