[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]

Re: [lvm-devel] lvresize.c: use kilobytes when passing sizes to fsadm

Milan Broz wrote:
Bryn M. Reeves wrote:
The code in lvresize.c computes a new file system size to pass to fsadm when resizing as (extents * extent_size), giving a result in kilobytes.

This is then passed on to fsadm without a suffix, meaning that fsadm interprets it as a count of the number of file system blocks instead.

This breaks fsadm for all file system block sizes other than 1K.

The attached patch adds a "K" suffix and fixes the problem for me - see:


Reviewed-by: Milan Broz <mbroz redhat com>
Tested-by: Milan Broz <mbroz redhat com>

Thanks Milan!

Jaroslav, please can you add some tests internally for fsadm/lvresize?
(test in bugzilla, just extend/reduce for 1024,2048,4096 fs blocksize,
mke2fs -b <bs> is enough (or maybe xfs, reiserfs tests too))

Sorry, I meant to take a look at the test suite yesterday to see if I could figure out adding tests for this but ran out of time.


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]