problem mounting from flash [Invalid sectorsize] [g_vfs_done() ?error=22]

Oliver Fromme olli at lurza.secnetix.de
Tue Nov 9 13:13:49 UTC 2010


Bruce Evans wrote:
 > On Mon, 8 Nov 2010, Oliver Fromme wrote:
 > > Monthadar Al Jaberi <monthadar at gmail.com> wrote:
 > > > [...]
 > > > mount: /dev/redboot/fs Invalid sectorsize 65536 for superblock size
 > > > 8192: Invalid argument
 > > > 
 > > > So I guessed it has todo with the flash configured in 64k sectors
 > > > according to the boot output.
 > > > ...
 > > > mx25l0: <M25Pxx Flash Family> at cs 0 on spibus0
 > > > mx25l0: mx25ll128, sector 65536 bytes, 256 sectors
 > > > ...
 > > 
 > > Historically UFS/FFS supports only 512 bytes per sector.
 > > I think it was patched at some point in the past to support
 > > 2048 bytes per sector, too, which is used by some MOD media
 > > and DVD-RAM.  I'm pretty sure it does _not_ support 65536
 > > bytes per sector (someone please correct me if I'm wrong).
 > 
 > Maybe 25 years ago, but in Net2/ 20 years ago ffs doesn't really
 > even use sectors.  It just has a buggy superblock probe which
 > prevents it determining its correct i/o size when that size
 > exceeds SBLOCKSIZE = 8192.

In the second half of the 90s it did *not* support the
2048-byte sectors of the larger MOD media that became
popular at that time.  I owned several of those drives
(still have one of them), so I remember it quite well.
FreeBSD's file system code needed some patches in order
to be able to use those disks.  Before that, only 512-
byte sectors worked.

I don't know what sector sizes are supported today, but
I wouldn't be surprised if only 512 to 2048 works out
of the box.  I'm not aware of any widely used media
that has sectors smaller than 512 or larger than 2048.
(Those new 4k drives translate accesses to/from 512 byte
sectors, so it looks like a 512-byte sector drive.)

Best regards
   Oliver

-- 
Oliver Fromme, secnetix GmbH & Co. KG, Marktplatz 29, 85567 Grafing b. M.
Handelsregister: Registergericht Muenchen, HRA 74606,  Geschäftsfuehrung:
secnetix Verwaltungsgesellsch. mbH, Handelsregister: Registergericht Mün-
chen, HRB 125758,  Geschäftsführer: Maik Bachmann, Olaf Erb, Ralf Gebhart

FreeBSD-Dienstleistungen, -Produkte und mehr:  http://www.secnetix.de/bsd

Python is executable pseudocode.  Perl is executable line noise.


More information about the freebsd-fs mailing list