Bug 187905 - [zpool] Confusion zpool with a block size in HDD - block size: 512B configured, 4096B native
Summary: [zpool] Confusion zpool with a block size in HDD - block size: 512B configure...
Status: Open
Alias: None
Product: Base System
Classification: Unclassified
Component: kern (show other bugs)
Version: Unspecified
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-fs (Nobody)
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-03-24 18:20 UTC by Vladyslav V. Prodan
Modified: 2019-12-04 22:22 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Vladyslav V. Prodan 2014-03-24 18:20:00 UTC
On a machine using ZFS, after upgrading from 9.0 to 10.0, zpool status
says:

# zpool status
  pool: tank
 state: ONLINE
status: One or more devices are configured to use a non-native block size.
        Expect reduced performance.
action: Replace affected devices with devices that support the
        configured block size, or migrate data to a properly configured
        pool.
  scan: scrub repaired 0 in 4h42m with 0 errors on Mon Mar 24 05:38:49 2014
config:

        NAME               STATE     READ WRITE CKSUM
        tank               ONLINE       0     0     0
          gpt/system-ada1  ONLINE       0     0     0  block size: 512B configured, 4096B native

errors: No known data errors


ashift: 9

# zdb -U /boot/zfs/zpool.cache
tank:
    version: 28
    name: 'tank'
    state: 0
    txg: 9794975
    pool_guid: 14509785011519350988
    hostid: 3616469326
    hostname: 'bimbo.fitnessfactor.com.ua'
    vdev_children: 1
    vdev_tree:
        type: 'root'
        id: 0
        guid: 14509785011519350988
        children[0]:
            type: 'disk'
            id: 0
            guid: 17960990484356700785
            path: '/dev/gpt/system-ada1'
            phys_path: '/dev/gpt/system-ada1'
            whole_disk: 1
            metaslab_array: 30
            metaslab_shift: 31
            ashift: 9
            asize: 495807889408
            is_log: 0
            DTL: 82314
            create_txg: 4

# diskinfo -v /dev/ada0
/dev/ada0
        512             # sectorsize
        500107862016    # mediasize in bytes (466G)
        976773168       # mediasize in sectors
        4096            # stripesize
        0               # stripeoffset
        969021          # Cylinders according to firmware.
        16              # Heads according to firmware.
        63              # Sectors according to firmware.
        S20BJ90D306953  # Disk ident.


# smartctl -a /dev/ada0
smartctl 6.2 2014-02-18 r3874 [FreeBSD 10.0-STABLE amd64] (local build)
Copyright (C) 2002-13, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Family:     Seagate Barracuda SpinPoint F3
Device Model:     ST500DM005 HD502HJ
Serial Number:    S20BJ90D306953
LU WWN Device Id: 5 0004cf 209d3bdd6
Firmware Version: 1AJ10001
User Capacity:    500 107 862 016 bytes [500 GB]
Sector Size:      512 bytes logical/physical
Rotation Rate:    7200 rpm
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   ATA8-ACS T13/1699-D revision 6
SATA Version is:  SATA 2.6, 3.0 Gb/s
Local Time is:    Mon Mar 24 20:00:48 2014 EET
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED
..
Comment 1 Mark Linimon freebsd_committer freebsd_triage 2014-03-24 18:34:42 UTC
Responsible Changed
From-To: freebsd-bugs->freebsd-fs

Over to maintainer(s).
Comment 2 Steven Hartland & 2014-03-24 19:09:48 UTC
This matches the 4K quirk for Seagate Barracuda Green Advanced Format (4k) drives 
        {
                /* Seagate Barracuda Green Advanced Format (4k) drives */
                { T_DIRECT, SIP_MEDIA_FIXED, "ATA", "ST???DM*", "*" },
                /*quirks*/DA_Q_4K
        },
---
        {
                /* Seagate Barracuda Advanced Format (4k) drives */
                { T_DIRECT, SIP_MEDIA_FIXED, "*", "ST????DM*", "*" },
                /*quirks*/ADA_Q_4K
        },

This is possibly incorrect for this drive as it looks like its a Seagate
version of the old Samsung drive.

Could you provide the information from:-
camcontrol identify ada0

    Regards
    Steve
Comment 3 Vladyslav V. Prodan 2014-03-24 19:27:28 UTC
2014-03-24 21:09 GMT+02:00 Steven Hartland <killing@multiplay.co.uk>:

> This matches the 4K quirk for Seagate Barracuda Green Advanced Format (4k)
> drives        {
>                /* Seagate Barracuda Green Advanced Format (4k) drives */
>                { T_DIRECT, SIP_MEDIA_FIXED, "ATA", "ST???DM*", "*" },
>                /*quirks*/DA_Q_4K
>        },
> ---
>        {
>                /* Seagate Barracuda Advanced Format (4k) drives */
>                { T_DIRECT, SIP_MEDIA_FIXED, "*", "ST????DM*", "*" },
>                /*quirks*/ADA_Q_4K
>        },
>
> This is possibly incorrect for this drive as it looks like its a Seagate
> version of the old Samsung drive.
>
> Could you provide the information from:-
> camcontrol identify ada0
>


Thanks for the reply.
Here's the output:

# camcontrol identify ada0
pass0: <ST500DM005 HD502HJ 1AJ10001> ATA-8 SATA 2.x device
pass0: 150.000MB/s transfers (SATA, UDMA5, PIO 8192bytes)

protocol              ATA/ATAPI-8 SATA 2.x
device model          ST500DM005 HD502HJ
firmware revision     1AJ10001
serial number         S20BJ90D306953
WWN                   50004cf209d3bdd6
cylinders             16383
heads                 16
sectors/track         63
sector size           logical 512, physical 512, offset 0
LBA supported         268435455 sectors
LBA48 supported       976773168 sectors
PIO supported         PIO4
DMA supported         WDMA2 UDMA6
media RPM             7200

Feature                      Support  Enabled   Value           Vendor
read ahead                     yes      yes
write cache                    yes      yes
flush cache                    yes      yes
overlap                        no
Tagged Command Queuing (TCQ)   no       no
Native Command Queuing (NCQ)   yes              32 tags
SMART                          yes      yes
microcode download             yes      yes
security                       yes      no
power management               yes      yes
advanced power management      yes      no      0/0x00
automatic acoustic management  yes      yes     254/0xFE        254/0xFE
media status notification      no       no
power-up in Standby            yes      no
write-read-verify              no       no
unload                         no       no
free-fall                      no       no
Data Set Management (DSM/TRIM) no
Host Protected Area (HPA)      yes      no      976773168/976773168
HPA - Security                 no




-- 
Vladislav V. Prodan
System & Network Administrator
http://support.od.ua
+380 67 4584408, +380 99 4060508
VVP88-RIPE
Comment 4 Eitan Adler freebsd_committer freebsd_triage 2017-12-31 08:01:13 UTC
For bugs matching the following criteria:

Status: In Progress Changed: (is less than) 2014-06-01

Reset to default assignee and clear in-progress tags.

Mail being skipped
Comment 5 Conrad Meyer freebsd_committer freebsd_triage 2018-01-03 05:43:29 UTC
Clearing in-progress is fine, but this is definitely -fs.
Comment 6 Jason S 2019-12-04 22:22:41 UTC
I'm seeing the same thing on a 12.0-RELEASE-p10 system where I just replaced a pair of 128GB SSDs with 250GB drives.  The SPCC is fine, but the Samsung 850 Evo is mismatched.

$ zpool status
  pool: zmule
 state: ONLINE
status: One or more devices are configured to use a non-native block size.
        Expect reduced performance.
action: Replace affected devices with devices that support the
        configured block size, or migrate data to a properly configured
        pool.
  scan: resilvered 86.8G in 0 days 01:01:03 with 0 errors on Tue Dec  3 14:38:09 2019
config:

        NAME                              STATE     READ WRITE CKSUM
        zmule                             ONLINE       0     0     0
          mirror-0                        ONLINE       0     0     0
            gpt/S21SERIALNUM94M-zfs       ONLINE       0     0     0  block size: 512B configured, 4096B native
            gpt/A86SERIALNUM00303100-zfs  ONLINE       0     0     0

errors: No known data errors

$ sudo zdb -U /boot/zfs/zpool.cache | grep ashift
            ashift: 9

$ sudo smartctl -a /dev/ada0
smartctl 7.0 2018-12-30 r4883 [FreeBSD 12.0-RELEASE-p10 amd64] (local build)
Copyright (C) 2002-18, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Family:     Samsung based SSDs
Device Model:     Samsung SSD 850 EVO 250GB
Serial Number:    S21SERIALNUM94M
LU WWN Device Id: 5 123456 da00c1299
Firmware Version: EMT01B6Q
User Capacity:    250,059,350,016 bytes [250 GB]
Sector Size:      512 bytes logical/physical
Rotation Rate:    Solid State Device
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   ACS-2, ATA8-ACS T13/1699-D revision 4c
SATA Version is:  SATA 3.1, 6.0 Gb/s (current: 3.0 Gb/s)
Local Time is:    Wed Dec  4 17:06:03 2019 EST
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

$ sudo diskinfo -v /dev/ada0
/dev/ada0
        512             # sectorsize
        250059350016    # mediasize in bytes (233G)
        488397168       # mediasize in sectors

camcontrol identify ada0  
pass0: <Samsung SSD 850 EVO 250GB EMT01B6Q> ACS-2 ATA SATA 3.x device
pass0: 300.000MB/s transfers (SATA 2.x, UDMA5, PIO 512bytes)

protocol              ATA/ATAPI-9 SATA 3.x
device model          Samsung SSD 850 EVO 250GB
firmware revision     EMT01B6Q
serial number         S21SERIALNUM94M
WWN                   1234567da00c1299
cylinders             16383
heads                 16
sectors/track         63
sector size           logical 512, physical 512, offset 0
LBA supported         268435455 sectors
LBA48 supported       488397168 sectors
PIO supported         PIO4
DMA supported         WDMA2 UDMA6 
media RPM             non-rotating
Zoned-Device Commands no

Feature                      Support  Enabled   Value           Vendor
read ahead                     yes      yes
write cache                    yes      yes
flush cache                    yes      yes
overlap                        no
Tagged Command Queuing (TCQ)   no       no
Native Command Queuing (NCQ)   yes              32 tags
NCQ Queue Management           no
NCQ Streaming                  no
Receive & Send FPDMA Queued    yes
SMART                          yes      yes
microcode download             yes      yes
security                       yes      no
power management               yes      yes
advanced power management      no       no
automatic acoustic management  no       no
media status notification      no       no
power-up in Standby            no       no
write-read-verify              yes      no      0/0x0
unload                         no       no
general purpose logging        yes      yes
free-fall                      no       no
Data Set Management (DSM/TRIM) yes
DSM - max 512byte blocks       yes              8
DSM - deterministic read       no
Host Protected Area (HPA)      yes      no      488397168/488397168
HPA - Security                 no