[Bug 214479] Cannot create or mount ext2 file system on a USB external drive

bugzilla-noreply at freebsd.org bugzilla-noreply at freebsd.org
Sun Nov 13 16:13:00 UTC 2016


https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=214479

            Bug ID: 214479
           Summary: Cannot create or mount ext2 file system on a USB
                    external drive
           Product: Base System
           Version: 11.0-RELEASE
          Hardware: amd64
                OS: Any
            Status: New
          Severity: Affects Only Me
          Priority: ---
         Component: usb
          Assignee: freebsd-usb at FreeBSD.org
          Reporter: giorgioxyzb at hotmail.com
                CC: freebsd-amd64 at FreeBSD.org
                CC: freebsd-amd64 at FreeBSD.org

I have two external 1T USB drives which I use for backups. Both contain one MBR
partition which is formatted with ext2fs. I can mount and use the first drive
under FreeBSD without any problems. On the second drive, I cannot mount the
ext2fs. Here is the model of the drive:

# smartctl -i /dev/da1
smartctl 6.5 2016-05-07 r4318 [FreeBSD 11.0-RELEASE-p1 amd64] (local build)
Copyright (C) 2002-16, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Family:     Western Digital Blue Mobile
Device Model:     WDC WD10JPVX-00JC3T0
Serial Number:    WD-WXQ1E945D4NJ
LU WWN Device Id: 5 0014ee 65add21b2
Firmware Version: 01.01A01
User Capacity:    1,000,204,886,016 bytes [1.00 TB]
Sector Sizes:     512 bytes logical, 4096 bytes physical
Rotation Rate:    5400 rpm
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   ACS-2 (minor revision not indicated)
SATA Version is:  SATA 3.0, 6.0 Gb/s (current: 3.0 Gb/s)
Local Time is:    Sat Nov 12 11:53:56 2016 CET
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

I have scanned the drive for bad sectors and nothing was found.

I have partitioned and formatted with ext2fs under GNU/Linux: GNU/Linux can
mount and use the drive. Under FreeBSD I get the following errors:
# mount -t ext2fs /dev/da1s1 mnt
mount: /dev/da1s1: Invalid argument

If I try to check the file system I get the following error:
# fsck_ext2fs -f -n -v /dev/da1s1
e2fsck 1.42.13 (17-May-2015)
/sbin/e2fsck: Attempt to read block from filesystem resulted in short read
while trying to open /dev/da1s1
Could this be a zero-length partition?

I have also partitioned the drive under FreeBSD using gpart and formatted with
ufs, and everything seems to work OK: I can mount, write files, read files.

I have tried formatting with ext2fs from FreeBSD and got warnings:
# mke2fs /dev/da1s1
mke2fs 1.42.13 (17-May-2015)
/dev/da1s1 contains a ext2 file system
Proceed anyway? (y,n) y
Warning: could not erase sector 2: Attempt to write block to filesystem
resulted in short write
Creating filesystem with 244188598 4k blocks and 61054976 inodes
Filesystem UUID: 22101a6d-fda0-4bfb-98a2-353b27953c13
Superblock backups stored on blocks: 
        32768, 98304, 163840, 229376, 294912, 819200, 884736, 1605632, 2654208, 
        4096000, 7962624, 11239424, 20480000, 23887872, 71663616, 78675968, 
        102400000, 214990848

Allocating group tables: done                            
Warning: could not read block 0: Attempt to read block from filesystem resulted
in short read
Warning: could not erase sector 0: Attempt to write block to filesystem
resulted in short write
Writing inode tables: done                            
Writing superblocks and filesystem accounting information:    0/7453

If I check the filesystem from FreeBSD I get the same errors:
/sbin/e2fsck -f -n /dev/da1s1 
e2fsck 1.42.13 (17-May-2015)
/sbin/e2fsck: Attempt to read block from filesystem resulted in short read
while trying to open /dev/da1s1
Could this be a zero-length partition?

So, I have these problems only with this disk and only with ext2fs. One thing
that occurred to me, is that GNU/Linux reports a physical sector size of 2048
bytes while for the other working disk it reports a physical sector size of
512.

-- 
You are receiving this mail because:
You are on the CC list for the bug.


More information about the freebsd-amd64 mailing list