[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20180814150114.4uphhk2avsfaowbn@localhost.localdomain>
Date: Tue, 14 Aug 2018 17:01:14 +0200
From: Lukas Czerner <lczerner@...hat.com>
To: "Theodore Y. Ts'o" <tytso@....edu>
Cc: linux-ext4@...r.kernel.org
Subject: Re: [PATCH 2/2] test: mke2fs must not create fs with reszie_inode
and meta_bg
On Tue, Aug 14, 2018 at 04:50:15PM +0200, Lukas Czerner wrote:
> On Tue, Aug 14, 2018 at 10:20:27AM -0400, Theodore Y. Ts'o wrote:
> > On Mon, Aug 13, 2018 at 03:17:06PM +0200, Lukas Czerner wrote:
> > > Test that mke2fs does not allow to create file system with both
> > > resize_inode and meta_bg features enabled.
> > >
> >
> > > diff --git a/tests/m_resize_inode_meta_bg/script b/tests/m_resize_inode_meta_bg/script
> > > new file mode 100644
> > > index 00000000..41ffb32a
> > > --- /dev/null
> > > +++ b/tests/m_resize_inode_meta_bg/script
> > > @@ -0,0 +1,7 @@
> > > +DESCRIPTION="resize_inode and meta_bg enabled"
> > > +FS_SIZE=15360
> > > +MKE2FS_DEVICE_SECTSIZE=4096
> > > +export MKE2FS_DEVICE_SECTSIZE
> > > +MKE2FS_OPTS="-T ext4 -g256 -O 64bit"
> > > +. $cmd_dir/run_mke2fs
> > > +unset MKE2FS_DEVICE_SECTSIZE
> >
> > This doesn't look right --- in order to trigger the bug the file
> > system size has to be exactly 2**32, right? And if so, then we need
> > to add:
>
> No it does not have to be that big. it's just that the ratio of
> (s_reserved_gdt_blocks + desc_blocks) to s_blocks_per_group must be
> bigger than 3:4 to trigger it.
>
> So if we artificially limit the blocks per group (using -g) to the right
> size then we can do this on smaller file systems. I did not really tried
> to figure out the minimum size we can hit it I just wanted the fs to be
> small enough in this case it's 60MB I think.
Eh, it's 15M of course.
+FS_SIZE=15360
-Lukas
>
> And indeed if you run it with 42e77d5db53e3ec09b5dc507169d15de219799e3.
> reverted it will fail.
>
> -Lukas
>
> >
> > if [ $(uname -s) = "Darwin" ]; then
> > # creates a really big filesystem
> > echo "$test_name: $DESCRIPTION: skipped for HFS+ (no sparse files)"
> > return 0
> > fi
> >
> > right?
> >
> > Hmm, Andreas, these checks were mostly for you IIRC. APFS *does*
> > support sparse files, so I wonder if we should be using an autoconf
> > test to see if the system supports sparse files, and using this to set
> > a variable in test_config (which would have to be generated from
> > test_config.in)? I don't plan to do anything like this since I don't
> > have a development MacOS system, but if you do run High Sierra, maybe
> > you could look in this?
> >
> > - Ted
Powered by blists - more mailing lists