lsm_volume_list(3)
β¨ lsm_volume_list β the Libstoragemgmt C API Manual glow-up β¨
okay bestie, welcome to lsm_volume_list from the Libstoragemgmt C API Manual π this is the one that hands you a whole list of volumes on your connection, and honestly? iconic behaviour.
πΈ NAME πΈ
lsm_volume_list β gets a list of volumes on this connection. that's it, that's the vibe. π
π SYNOPSIS π
int lsm_volume_list (lsm_connect *conn, const char *search_key, const
char *search_value, lsm_volume **volumes[], uint32_t *count, lsm_flag
flags);
π¦ ARGUMENTS π¦
connβ a validlsm_connectpointer. like, an actually valid one. don't be playing games with me here πsearch_keyβ your search key, and it'sNULLfor all of them. the valid search keys are:"id","system_id"and"pool_id". that's the whole list, no extras, no secret menu πsearch_valueβ the search value. the matching half of the little search duo π«Άvolumes[]β output pointer of thelsm_volumearray. lowkey important: it should be manually freed bylsm_volume_record_array_free. yes, manually. you, personally. do not ghost it, bestie, that's a leak πcountβ output pointer ofuint32_t. number of volumes. how many you got β¨flagsβ reserved for future use, must beLSM_CLIENT_FLAG_RSVD. no freelancing on this one π«
β VERSION β
1.0
π DESCRIPTION π
Gets a list of volumes on this connection. the way that this function justβ¦ gathers up all your volumes, no cap π
Volume properties could be retrieved by these functions:
lsm_volume_id_getlsm_volume_name_getlsm_volume_system_id_getlsm_volume_vpd83_getlsm_volume_number_of_blocks_getlsm_volume_block_size_getlsm_volume_admin_state_getlsm_volume_pool_id_get
all eight of them, collected, matching set, main character energy π
π§ CAPABILITY π§
LSM_CAP_VOLUMES
π₯ RETURN π₯
Error code as enumerated by lsm_error_number. here's the rundown:
LSM_ERR_OKβ on success or searched value not found. yes, "not found" still counts as okay here, that's just how she is πLSM_ERR_INVALID_ARGUMENTβ when any argument isNULLor invalid flags or invalid search key. basically if you handed her nonsense, she's telling you π«LSM_ERR_NO_SUPPORTβ not supported. she simply cannot, bestie π
lowkey reminder: thatvolumes[]array is yours to free withlsm_volume_record_array_free. fr fr, don't skip it. πΈ
that's the whole page, bestie β lsm_volume_list(3) from the Libstoragemgmt C API Manual, version 1.0, dated February 2026. slay, go forth, and free your arrays π
β¨
π¦ where this page comes from
- fedora 43: libstoragemgmt-devel 1.10.3-1.fc43 Β· LGPL-2.1-or-later
- fedora 44: libstoragemgmt-devel 1.10.3-1.fc44 Β· LGPL-2.1-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms