Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 26 Feb 2019 20:32:26 -0700
From:      Warner Losh <imp@bsdimp.com>
To:        "Rodney W. Grimes" <rgrimes@freebsd.org>
Cc:        Bruce Evans <brde@optusnet.com.au>, Jason Harmening <jason.harmening@gmail.com>,  "Jason A. Harmening" <jah@freebsd.org>, src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org
Subject:   Re: svn commit: r344562 - head/sys/ufs/ffs
Message-ID:  <CANCZdfrBQXLTO9E6nHmc-zAKLpG-3npx8fT1DJuD%2BacF_yHCqg@mail.gmail.com>
In-Reply-To: <201902260749.x1Q7n1GI043756@pdx.rh.CN85.dnsmgr.net>
References:  <20190226173749.A1863@besplex.bde.org> <201902260749.x1Q7n1GI043756@pdx.rh.CN85.dnsmgr.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, Feb 26, 2019, 12:49 AM Rodney W. Grimes <
freebsd@pdx.rh.cn85.dnsmgr.net> wrote:

> > On Mon, 25 Feb 2019, Jason Harmening wrote:
> >
> > > On 2/25/19 9:46 PM, Bruce Evans wrote:
> > >>
> > >> block_size <= PAGE_SIZE is very uncommon for ffs, even on systems
> with
> > >> large
> > >> pages.  MINBSIZE is 4096 in ffs (except in my version, it is 512).
> The
> > >> default is 32768 in newfs.  I consider this excessive and only use it
> for
> > >> file systems with many files larger than 1GB, but it is the most
> common
> > >> size.
> > >> It is larger than the large page size of 8192.
> > >
> > > I think this is a case of filesystem logical block size vs. media
> sector
> > > size, right?  Here we're checking the devvp's block size, which I
> think
> > > should correspond to the sector size.  I'd expect cases of that being
> > > greater than PAGE_SIZE to be uncommon, in fact geli warns when that is
> the
> > > case.   I probably should've made that clearer in the commit message.
> >
> > Yes, I missed that you are checking devvp.  ffs_getpages() also checks
> > devvp.
> >
> > So the bug has nothing to do with file system logical (fragment) or i/o
> > (block) block size's, except file systems themselves won't work unless
> > their i/o size is a multiple of the underlying devices (sector) i/o size.
> >
> > Are there physical disk with sector size > PAGE_SIZE now?
>
> I have been told that there are some sd/flash devices that
> have a 16k physical sector size, I have not been able to
> confirm that information though.
>

There are a number of drives that report 16k physical, but 4k sector size.
Others vendors have suggested that 32k or 64k may be on the horizon. But
all these drives still report an LBA size of 4k.

The drive vendors I've talked to have indicated that a larger sector size
is in the works, but so far they haven't indicated what that newer size
will wind up being, or when it would appear in the market...

The timing of when may be unknown, but it's quite likely the future will
have to cope with a mismatch.

Warner

> It is easy to
> > create virtual (md) disks with sector size > PAGE_SIZE, and this may even
> > be useful for avoiding the related problem of having to access large fs
> > blocks to do i/o to small md sectors.  I think it is best to use
> PAGE_SIZE
> > blocks in all layers and sometimes combine these into clusters.
> >
> > Bruce
> --
> Rod Grimes
> rgrimes@freebsd.org
>
>



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CANCZdfrBQXLTO9E6nHmc-zAKLpG-3npx8fT1DJuD%2BacF_yHCqg>