ZFS RAID mirror, how to test that it functions properly.

I have FreeBSD version 10.3-RELEASE-p4(kernel) and 10.3-RELEASE-p5 (userland). I did setup Mirror RAID with two disks during installation. Now I wand to make sure that the mirror is functioning properly.

This is what I’ve tried.

graid status prints no results.

Next, I made sure disks are seen by the system:

Code:
pav@pavfilebox:~ % more /var/run/dmesg.boot | grep ada
ada0 at ata3 bus 0 scbus1 target 0 lun 0
ada0: <WDC WD20EFRX-68EUZN0 80.00A80> ACS-2 ATA SATA 3.x device
ada0: Serial Number WD-WCC4MMW6EXLR
ada0: 300.000MB/s transfers (SATA 2.x, UDMA5, PIO 8192bytes)
ada0: 1907729MB (3907029168 512 byte sectors)
ada0: quirks=0x1<4K>
ada0: Previously was known as ad6
ada1 at ata4 bus 0 scbus2 target 0 lun 0
ada1: <WDC WD20EFRX-68EUZN0 80.00A80> ACS-2 ATA SATA 3.x device
ada1: Serial Number WD-WCC4MLK57UAT
ada1: 300.000MB/s transfers (SATA 2.x, UDMA5, PIO 8192bytes)
ada1: 1907729MB (3907029168 512 byte sectors)
ada1: quirks=0x1<4K>
ada1: Previously was known as ad8

But zpool mentions only one of those disks by its id:

Code:
pav@pavfilebox:~ % zpool status
  pool: zroot
 state: ONLINE
status: Some supported features are not enabled on the pool. The pool can
            still be used, but some features are unavailable.
action: Enable all features using 'zpool upgrade'. Once this is done,
            the pool may no longer be accessible by software that does not support
            the features. See zpool-features(7) for details.
  scan: resilvered 276K in 0h0m with 0 errors on Sat Jan 26 15:37:42 2019
config:

            NAME                               STATE     READ WRITE CKSUM
            zroot                              ONLINE       0     0     0
              mirror-0                         ONLINE       0     0     0
                gpt/zfs0                       ONLINE       0     0     0
                diskid/DISK-WD-WCC4MMW6EXLRp3  ONLINE       0     0     0

errors: No known data errors

Also, if I probe disks with gpart, I get results for only one of my disks:

Code:
pav@pavfilebox:~ % gpart show /dev/ada0
gpart: No such geom: /dev/ada0.
pav@pavfilebox:~ % gpart show /dev/ada1
=>        34  3907029101  ada1  GPT  (1.8T)
          34           6        - free -  (3.0K)
          40        1024     1  freebsd-boot  (512K)
        1064     4194304     2  freebsd-swap  (2.0G)
     4195368  3902833760     3  freebsd-zfs  (1.8T)
  3907029128           7        - free -  (3.5K)

My quetion is: Is one of my disks not working properly, and that’s why only one disk is mentioned in zpool report, or is it how it’s supposed to be?
 
I have FreeBSD version 10.3-RELEASE-p4(kernel) and 10.3-RELEASE-p5 (userland).
FreeBSD 10.3 has been End-of-Life since April 2018 and is not supported any more. Update to a supported version.




My quetion is: Is one of my disks not working properly, and that’s why only one disk is mentioned in zpool report, or is it how it’s supposed to be?
Both disks are reported, just differently. I'm guessing ada0 has been replaced at some point in time but replaced incorrectly. Instead of creating the partitions and replacing the partition, the whole disk was used.

Take out ad0, partition it properly (it should be exactly like ada1) and add it again, this time using the partition.
 
FreeBSD 10.3 has been End-of-Life since April 2018 and is not supported any more. Update to a supported version.





Both disks are reported, just differently. I'm guessing ada0 has been replaced at some point in time but replaced incorrectly. Instead of creating the partitions and replacing the partition, the whole disk was used.

Take out ad0, partition it properly (it should be exactly like ada1) and add it again, this time using the partition.
ada0 was never replaced, the only thing I ever did after installing the system was connecting it to a different SATA outlet on the motherboard. I don’t suppose it really matters. Now I’m trying to understand why it got formatted this was: my best recollection is that all formatting was handled during the installation. Is any data at all written to ada0?
 
the only thing I ever did after installing the system was connecting it to a different SATA outlet on the motherboard
For ZFS this shouldn't matter. But, was it originally perhaps on a RAID controller and not configured as a JBOD?

Is any data at all written to ada0?
The mirror itself is in sync, so yes.
 
For ZFS this shouldn't matter. But, was it originally perhaps on a RAID controller and not configured as a JBOD?
As far as I recoll, I turned off RAID support in BIOS (yes, the motherboard is this old, its BIOS only) before installing BSD, and didn't change any settings since the installation.
 
Ok, I know some people resorted to creating single disk RAID0 sets when their controller didn't support JBOD. Using a single disk RAID0 on a "plain" interface could result in weird situations where the partition table appears to be corrupted.

In any case, it's probably difficult to figure how it got into this state. Because this is a mirror it should be relatively easy to fix though.
 
Back
Top