LFS-GETSTRIPE(1)
๐ LFS-GETSTRIPE ๐
okay so welcome to LFS-GETSTRIPE(1), straight outta the Lustre User Utilities manual โ section 1, users' commands, periodt ๐
this is the one you run when you wanna know exactly how a file's data is laid out across the filesystem and you're not about to guess. no cap.
โจ NAME โจ
lfs-getstripe โ the Lustre client command that prints the layout parameters of a file ๐ฆ
๐ธ SYNOPSIS ๐ธ
like, here's the whole vibe, verbatim, don't @ me:
lfs getstripe [--component-count|--comp-count]
[--component-end|--comp-end|-E[=[+-]END_OFFSET [KMGTPE]]
[--component-flags|--comp-flags[=COMP_FLAGS]]
[--component-id|--comp-id [=COMP_ID]|-I[COMP_ID]]
[--component-start[=[+-]START_OFFSET[KMGTPE]]]
[--extension-size|--ext-size|-z] [--default|-D]
[--directory|-d] [--fid|-F] [--generation|-g] [--help|-h]
[--hex-idx] [--layout|-L] [--mdt|--mdt-index|-m]
[--ost|-O OST_NAME] [--pool|-p] [--quiet|-q]
[--recursive|-r] [--raw|-R] [--stripe-count|-c] [--stripe-
index|-i] [--stripe-size|-S] [--mirror-count|-N]
[[!]--mirror-index=[+-]MIRROR_INDEX | [!]--mirror-
id=[+-]MIRROR_ID] [--verbose|-v] [--yaml|-y] [--no-follow]
FILENAME|DIRECTORY ...
๐ DESCRIPTION ๐
so lfs getstripe is literally here to list the layout / striping info for a filename or a whole directory tree, bestie. by default it shows you the stripe_count, stripe_size, stripe_offset, and all the allocated OST objects for every file. that's the default dump, no notes. ๐
but bestie, if you only want specific layout info printed? you can totally just use --stripe-count, --stripe-size, --extension-size, --stripe-index, --layout, --fid, --generation, --component-id, --component-flags, --component-count, --component-start, --component-end, --pool, or --mirror-index or --mirror-id โ or the equivalent single-character options โ with no argument, and you'll get back just that field (or fields). the way that you can just ask for one thing and get one thing ๐ iconic behavior fr fr.
you can also limit the displayed content to one or more specific components or mirrors of a composite file layout by specifying the matching parameter(s) for --component-id, --component-flags, --component-start, --component-end, --mirror-index, or --mirror-id โ or their single-character options. and hERE'S the catch, don't get it twisted: for the single-character options, the argument has to follow the option with no space in between, and for long options you gotta use an = sign. this is the rule. respect the rule. ๐ค
and hey, default behavior when you hand it a directory? it lists the striping info for all the files inside that specified directory โ like ls -l DIRECTORY. cute right? ๐
๐ OPTIONS ๐
okay bestie this is the whole menu, don't skip, everything matters:
--component-count,--comp-countโ prints only the number of components in the file's layout. just the count. nothing else. ๐ข-E,--component-end,--comp-end[[+-]END_OFFSET[KMGTPE]]โ prints only the component end offset (in bytes) for the component(s). if you also give the component end offset (with an optional suffix for SI units), then it prints only the attributes of the component(s) with that given end offset. and if you use+END_OFFSETor-END_OFFSET, it prints components with, respectively, a larger or smallerEND_OFFSEToffset. ๐--component-flags,--comp-flags[^]COMP_FLAG,...โ prints only the component flags. if you specifyCOMP_FLAG, it prints only the components matching that specifiedCOMP_FLAGset. if you use^COMP_FLAG, it prints only the components that don't matchCOMP_FLAG. you can stack multiple flags, separated by commas. the valid flag names are:initโ the component has been initialized (meaning it has allocated OST objects). โstaleโ replicated (mirrored) components that do not have up-to-date data. these stale components will not be used for read or write operations, and they need to be resynched usinglfs mirror resyncbefore they can be accessed again. โ ๏ธpreferโ replicated (mirrored) components that are preferred for read or write. like, for example, because they're sitting on SSD-based OSTs, or they're more local on the network to clients. ๐prefrdโ replicated (mirrored) components that are preferred for read. ๐prefwrโ replicated (mirrored) components that are preferred for write. โ๏ธnosyncโ replicated (mirrored) components that do not resync usinglfs mirror resync. and heads up: files with thenosyncflag will also print the timestamp of when the flag was set on that replica. ๐
-I,--component-id,--comp-id[COMP_ID]โ prints only the componentCOMP_IDnumber for the component(s). this file-unique componentCOMP_IDgets assigned as each component is created, and it is not re-used. also important:COMP_IDis not necessarily related to the offset of the component within the file, especially since replicated file layouts can have overlapping extents. and ifCOMP_IDis specified, then it prints only the fields for the matching component. ๐ฏ--component-start,--comp-start[+-]START_OFFSET[KMGTPE]โ prints only the component start offset (in bytes) for the component(s). if you specify the componentSTART_OFFSEToffset (with an optional suffix for SI units), it prints only the attributes of the component(s) with that given starting offset. if you use+START_OFFSETor-START_OFFSET, it prints components with, respectively, a larger or smallerSTART_OFFSEToffset. ๐-D,--defaultโ shows the default layout that gets used when creating new files in the specified directory. ๐ฑ-d,--directoryโ gets striping info for only the specified directory, likels -d. no recursion into the children, bestie. ๐ช-F,--fidโ shows only the 128-bit unique Lustre File Identifier (FID). ๐-g,--generationโ prints only the layout generation number. ๐-h,--helpโ prints the usage message. classic. ๐--hex-idxโ prints OST and MDT indexes in hexadecimal instead of decimal. ๐ขโก๏ธ๐ ฐ๏ธ--layoutโ shows only the file layout, which is one of these bad boys:badโ files that have an invalid layout and are inaccessible. ๐foreignโ files that have a foreign (non-Lustre/free format) component. heads up, such files may be inaccessible without external software integration. ๐ฝholeโ files that are missing a data object, possibly because of OST failure and layout reconstruction by LFSCK. ๐ณ๏ธmdtโ files that store the first data component on the MDT holding the inode. ๐๏ธoverstripedโ files that have more than one stripe per OST, for improved lock scalability. ๐raid0โ the traditional Lustre RAID-0 striping format. ๐งฑreleasedโ HSM-archived files that are not resident in the filesystem. ๐ฆ
-m,--mdt,--mdt-indexโ shows the MDT index on which the file or directory inode is located. ๐-N,--mirror-countโ prints the number of mirrors on the file. ๐ช--mirror-index=[+-]MIRROR_INDEXโ prints only the components of theMIRROR_INDEX-th mirror, based on the order that the mirror components are stored in the file layout.MIRROR_INDEXstarts at1. if you use+MIRROR_INDEXor-MIRROR_INDEX, it prints components of mirror(s) respectively later or earlier than theMIRROR_INDEX-th mirror. โจ!โ negates the meaning. using+beforeMIRROR_INDEXmeans the mirror appears 'later thanMIRROR_INDEX', and-beforeMIRROR_INDEXmeans the mirror appears 'earlier thanMIRROR_INDEX'. if neither is used, it means 'equal toMIRROR_INDEX'. ๐ฆ
--mirror-id =[ +- ] MIRROR_IDโ prints only the components of the mirror with the ID ofMIRROR_ID. mirror IDs are assigned to new mirrors as they are created, but they may not be sequential if some mirrors get removed. if you use+MIRROR_IDor-MIRROR_ID, it prints components of mirror(s) with, respectively, a larger or smaller mirror ID thanMIRROR_ID. ๐ชฉ!โ negates the meaning. using+beforeMIRROR_IDmeans a mirror with an ID 'larger thanMIRROR_ID', and-beforeMIRROR_IDmeans a mirror with an ID 'smaller thanMIRROR_ID'. if neither is used, it means 'equal toMIRROR_ID'. ๐ฆ
-O,--ost OST_NAMEโ prints only file layouts and OST objects on the specifiedOST_NAME. ๐ช-p,--poolโ prints only the OST pool name on which the file was created. ๐-q,--quietโ prints only the allocated objects for each file, and not the other layout parameters. ๐คซ-R,--rawโ prints layout information without substituting the filesystem's default values for unspecified fields. and if the file layout isn't set, then0,0, and-1will be printed forstripe_count,stripe_size, andstripe_offsetrespectively. raw is raw. ๐ฅฉ-r,--recursiveโ recurses into all subdirectories. all the way down, bestie. ๐-c,--stripe-countโ prints the number of stripes in the file. for composite files, this is the stripe count of the last initialized component. ๐งฎ-i,--stripe-indexโ prints the starting OST index for the file layout. ๐ฉ-S,--stripe-sizeโ prints the stripe size in bytes. for composite files, this is the stripe size of the last initialized component. ๐-z,--extension-size,--ext-sizeโ prints the extension size in bytes. for composite files, this is the extension size of the first extension component. ๐งฉ-v,--verboseโ also prints the layout magic, FID sequence, FID object ID, and FID, on top of the normally-printed attributes. talkative queen. ๐ฃ๏ธ-y,--yamlโ always prints the layout in YAML format, instead of only using this format for composite files. ๐--no-followโ prints the stripe information of the symbolic link itself. don't follow the link, bestie, look at the link. ๐
๐ EXAMPLES ๐
okay bestie, this is the part where it all clicks. every example below is copied exactly so you can just paste and go bestie, no cap โจ
list the detailed object allocation of the given file:
# lfs getstripe -v /mnt/lustre/file1
list the detailed information of only component with ID 2 of the given file:
# lfs getstripe -v -I2 /mnt/lustre/file1
print the mirror(s) appearing later than the first mirror in the file:
# lfs getstripe --mirror-index=+1 /mnt/lustre/file1
print the mirror(s) with mirror ID other than 2 in the file:
# lfs getstripe ! --mirror-id=2 /mnt/lustre/file1
bestie note the ! sitting right there before the option โ don't drop it, that lil guy is the whole "not this one" energy ๐
print only the component IDs for all the uninitialized components:
# lfs getstripe --component-flags=^init -I /mnt/lustre/file1
print only the component(s) that are instantiated but not stale:
# lfs getstripe --component-flags=init,^stale -I /mnt/lustre/file1
list information of components in a file with extent end less than 64MiB:
# lfs getstripe -E-64M /mnt/lustre/file1
print only the component start for the component with ID of 3:
# lfs getstripe -I3 --component-start /mnt/lustre/file1
lists the information of the components of a file in YAML format:
# lfs getstripe --yaml /mnt/lustre/file1
๐ซถ AVAILABILITY ๐ซถ
lfs getstripe is part of the lustre(7) filesystem package since release 0.10.0 ๐ซ been here, been iconic, been doing the werk.
๐ SEE ALSO ๐
go read your siblings, they're all serving too ๐ฅ
and that's the whole page bestie, you ate that ๐ โจ this one's from the Lustre crew, dated 2025-12-20, and it lives at LFS-GETSTRIPE(1) in the manual. go forth and getstripe responsibly ๐ฆ๐
๐ฆ 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