LLAPI_LAYOUT_PATTERN_GET(3)
π LLAPI_LAYOUT_PATTERN_GET(3) π
okay bestie, welcome to the llapi_layout_pattern_get page from the Lustre Library Functions manual β yes, that's a 3 in the parens, it's a library call, we're doing C today, hydrate first πΈ
β¨ NAME β¨
llapi_layout_pattern_get, llapi_layout_pattern_set β get or set the RAID striping pattern of a Lustre file π¦
β¨ SYNOPSIS β¨
#include <lustre/lustreapi.h>
int llapi_layout_pattern_get(const struct llapi_layout *layout,
uint64_t *pattern);
int llapi_layout_pattern_set(struct llapi_layout *layout,
uint64_t pattern);
like, include the header first obviously, we don't just guess at structs π
β¨ DESCRIPTION β¨
so llapi_layout_pattern_get() does the cute lil read thing: it stores into pattern the RAID striping pattern used by layout layout. just hands it over. reading era πβ¨
then llapi_layout_pattern_set() sets the RAID striping pattern of layout to pattern. currently the only supported RAID pattern is RAID0, that's it, that's the whole menu, no cap. so if pattern is not a supported RAID pattern, the return value will be -1 and errno will be set to EOPNOTSUPP. it's giving rejection but politely π
two special values, remember these:
- A pattern value of
LLAPI_LAYOUT_DEFAULTmeans that the filesystem default RAID pattern will be used. - A pattern value of
LLAPI_LAYOUT_RAID0means that the RAID0 pattern will be used.
lowkey the whole API in two constants, obsessed π
β¨ RETURN VALUES β¨
llapi_layout_pattern_get() and llapi_layout_pattern_set() return 0 on success, or -1 if an error occurred (in which case, errno is set appropriately). zero is a slay, minus one is a vibe check failure π
β¨ ERRORS β¨
EINVALβ An invalid argument was specified. you passed something goofy, bestie πEOPNOTSUPPβ An unsupported RAID pattern was specified. we said RAID0 and we meant RAID0 β
β¨ AVAILABILITY β¨
llapi_layout_pattern_get() and llapi_layout_pattern_set() are part of the lustre(7) user application interface library since release 2.7.0 β so like, since forever ago, vintage icon behavior π
β¨ SEE ALSO β¨
go read those next, the lore is deep π
anyway that's the page!! Lustre User API, dated 2024-08-27, from the LLAPI_LAYOUT_PATTERN_GET(3) era of your terminal. mwah, go write some layouts πβ¨
π¦ where this page comes from
- ubuntu stonking: lustre-client-utils 2.17.58+dfsg-0ubuntu2 Β· GPL-2.0-only
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms