lsm_volume_mask(3)
π lsm_volume_mask β a lil' page from the Libstoragemgmt C API Manual (section 3, bestie, we're in the library docs)
okay so. picture this: you got a volume, you got an access group, and they're just... not talking. tragic. lsm_volume_mask() is the function that fixes that, and I'm gonna walk you through it like we're texting at 2am. π«Ά
β¨ NAME β¨
lsm_volume_mask β grants access to a volume for the specified group. that's it. that's the whole job. iconic behavior honestly. π
πΈ SYNOPSIS πΈ
int lsm_volume_mask (lsm_connect *conn, lsm_access_group *access_group,
lsm_volume *volume, lsm_flag flags);
π ARGUMENTS π
connβ a valid connection. like, a real one. don't be passing me garbage, bestie.access_groupβ pointer oflsm_access_group. this is the group getting the access.volumeβ pointer oflsm_volume. this is the volume being handed over.flagsβ reserved for future use, must beLSM_CLIENT_FLAG_RSVD. it's giving "we made room for future plot twists." don't put anything else there fr fr.
π¦ VERSION π¦
1.0 β¨
π DESCRIPTION π
grants access to a volume for the specified group β also known as LUN masking or mapping. so if you've ever heard those two terms floating around and wondered "is that the same thing as this function?" β yes. yes it is. slay. π
π₯ CAPABILITY π₯
LSM_CAP_VOLUME_MASK
that's the capability you gotta check for, okay? if it's not there, it's not happening.
π RETURN π
it returns an error code as enumerated by lsm_error_number. so like, the vibes get reported back to you in number form. here's the whole list, no skips, no shortcuts:
LSM_ERR_OK- on success. we ate. π
LSM_ERR_INVALID_ARGUMENT- when any argument is
NULLor not a validlsm_connectpointer, or invalid flags, or an invalidlsm_access_grouppointer, or an invalidlsm_volume. basically if anything you handed over was sus, you get this.
- when any argument is
LSM_ERR_NOT_FOUND_ACCESS_GROUP- when the access group is not found. she's not here. π
LSM_ERR_NOT_FOUND_VOLUME- when the volume is not found. also not here. π
LSM_ERR_NO_STATE_CHANGE- when the specified volume is already masked to the specified access group. like bestie it's already done, nothing changed, go home. π
LSM_ERR_NO_SUPPORT- not supported. the system said "no <3" in the politest way possible.
lowkey important: LSM_ERR_NO_STATE_CHANGE isn't an error error, it's more like a "you're already holding the door open, why are you knocking" situation. but it IS what gets returned, so don't come for me.
and that's the whole page, no notes. π§ this lil' page came from the Libstoragemgmt C API Manual, dated February 2026, and honestly? she's short, she's sweet, she does exactly one thing and does it well. main character energy. periodt. ππβ¨
π¦ 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