lsm_volume_create(3)
π lsm_volume_create β bestie edition π
okay so we're in the Libstoragemgmt C API Manual and today's main character is lsm_volume_create(3). yes that's the whole page name, we're doing this properly π
β¨ NAME β¨
lsm_volume_create β creates a new volume π
πΈ SYNOPSIS πΈ
int lsm_volume_create (lsm_connect *conn, lsm_pool *pool, const char
*volume_name, uint64_t size, lsm_volume_provision_type provisioning,
lsm_volume **new_volume, char **job, lsm_flag flags);
like. look at all those arguments. we love a function with range π
π¦ ARGUMENTS π¦
connβ a validlsm_connectpointer. has to be valid bestie, no fake ones πpoolβ pointer oflsm_pool. that's the pool we're pulling from πvolume_nameβ string. it's a human recognizable name, but heads up: some storage systems might alter it or straight up ignore it π so don't get attachedsizeβuint64_t. size of the new volume in bytes. ngl the actual size might be bigger than what you asked for, because it gets based on array rounding to block size. it's giving "close enough" β¨provisioningβlsm_volume_provision_type. the type of volume provisioning to use. valid values are:LSM_VOLUME_PROVISION_DEFAULTβ let the storage system decide. we love a delegator πLSM_VOLUME_PROVISION_FULLβ create a new fully allocated volume. no crumbs, all in π₯LSM_VOLUME_PROVISION_THINβ create a new thin provisioning volume. light and airy π§
new_volumeβ output pointer oflsm_volume. it will beNULLif the storage system supports asynchronous action on this. the memory must be freed with a call tolsm_volume_record_free. do not forget, i'm literally begging π«Άjobβ output pointer of string. if the storage system supports asynchronous action on this, a job will be created and could be tracked vialsm_job_status_volume_get. it'sNULLif the storage system does not support asynchronous action on this βflagsβ reserved for future use, must beLSM_CLIENT_FLAG_RSVD. it's a placeholder bestie, don't put anything else in there π
π VERSION π
1.0
π DESCRIPTION π
Creates a new volume (also known as a LUN). that's it, that's the vibe β¨
π CAPABILITY π
LSM_CAP_VOLUME_CREATE
π RETURN π
the error code, as enumerated by lsm_error_number:
LSM_ERR_OKβ on success. slay πLSM_ERR_JOB_STARTEDβ a job is started. please check thejoboutput pointer. go look at it, fr fr πLSM_ERR_INVALID_ARGUMENTβ when any argument isNULL, or not a validlsm_connectpointer, or invalid flags, or invalid provisioning type. basically when something's off πLSM_ERR_NOT_FOUND_POOLβ when pool not found. where is she πLSM_ERR_NOT_ENOUGH_SPACEβ pool does not have enough space. the pool said no πLSM_ERR_POOL_NOT_READYβ pool is not ready for volume creation. give her a minute π§LSM_ERR_NO_SUPPORTβ not supported. it's not giving what it needs to give π
okay that's the whole page, nothing skipped, every single detail accounted for. you ate this. periodt π
and that's a wrap on lsm_volume_create(3) from the Libstoragemgmt C API Manual, dated February 2026 β source and version notes delivered, cute sign-off included, mwah π«Άβ¨
π¦ 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