Description
As with "df", it would be useful to allow specifying "lfs df --output=FIELD_LIST" to print only specific fields from the output:
FIELD_LIST is a comma-separated list of columns to be included. Valid
field names are: 'source', 'itotal' (alias 'inodes'), 'iused', 'iavail' (alias 'ifree'),
'ipcent' (alias 'iusepct'), 'size', 'used', 'free', 'avail', 'pcent' (alias 'usepct'), 'file' and 'target'
This allows printing only specific fields, and would avoid a lot of "lfs df | awk '/OST0000/ { print $4 }'" kind of usage in test scripts, and is likely similarly useful for end users. The aliases are added to match the column headings reported by "df".
It would also be useful to have long options for these, like "lfs df --itotal" or "lfs df --size" or "lfs df --usepct" so that they are accessible in an intuitive manner as needed.
Attachments
Issue Links
- is related to
-
LU-18242 allow 'lfs df -m/-o' to specify one MDT/OST
-
- Open
-