Whamcloud - gitweb
LU-17263 utils: 'lfs find -blocks' to use 512-byte units
authorAndreas Dilger <adilger@whamcloud.com>
Sun, 5 Nov 2023 05:32:19 +0000 (23:32 -0600)
committerAndreas Dilger <adilger@whamcloud.com>
Fri, 29 Dec 2023 11:12:17 +0000 (11:12 +0000)
commit046936e828404d434f6dee4b507c34633505d8f1
tree954396e59da210be9ba4945467c1b24dd136532d
parent2bff3b05114e38df1ff128e93aaca27d072dcfb0
LU-17263 utils: 'lfs find -blocks' to use 512-byte units

Change the default units for 'lfs find -blocks' from 1KiB blocks
to 512-byte blocks to better match the behavior of find(1).  This
also matches what "-printf %b" will print.

Change llapi_parse_size() to accept a 'c' argument to specify
characters, and accept a "B" or "iB" suffix if provided.

Lustre-change: https://review.whamcloud.com/52993
Lustre-commit: 869ea3211d2f15d7c674bc10e5f1a3272e44504e

Fixes: c043f46025 ("LU-10705 utils: add "lfs find --blocks"")
Signed-off-by: Andreas Dilger <adilger@whamcloud.com>
Change-Id: If8345f15bf53912501cadc0fa7f981a9f787b767
Reviewed-by: Arshad Hussain <arshad.hussain@aeoncomputing.com>
Reviewed-by: Vitaliy Kuznetsov <vkuznetsov@ddn.com>
Reviewed-on: https://review.whamcloud.com/c/ex/lustre-release/+/53522
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
lustre/doc/lfs-find.1
lustre/utils/lfs.c
lustre/utils/liblustreapi.c