Thread (3 messages) 3 messages, 2 authors, 2021-02-20

Re: [PATCH v3] btrfs-progs: filesystem-resize: make output more readable

From: Sidong Yang <hidden>
Date: 2021-02-20 12:39:09

On Fri, Feb 19, 2021 at 07:11:49PM +0100, David Sterba wrote:
On Fri, Feb 19, 2021 at 05:18:18PM +0000, Sidong Yang wrote:
quoted
This patch make output of filesystem-resize command more readable and
give detail information for users. This patch provides more information
about filesystem like below.

Before:
Resize '/mnt' of '1:-1G'

After:
Resize device id 1 (/dev/vdb) from 4.00GiB to 3.00GiB

Signed-off-by: Sidong Yang <redacted>
Code-wise it looks good, but I tried a simple test and it does not work:
Thanks, It should be fixed to make devid having default value 1 that
also kernel code does it. and initialize sizestr with amount_dup because
if there is no devid, sizestr will be NULL and command failed.

I'll write patch v4.

Thanks,
Sidong
# truncate -s 4g image
# mkfs.btrfs image
# mount -o loop image mnt
# btrfs fi resize -1G mnt
ERROR: cannot find devid: 0

while running the same command with the installed system 'btrfs' resizes
the fs: "Resize '.' of '-1G'".
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help