HomeFreeBSD

Store the L2ARC device ashift in the vdev label

Description

Store the L2ARC device ashift in the vdev label

If this is not done, and the pool has an ashift other than the default
(at the moment 9) then the following happens:

  1. vdev_alloc() assigns the ashift of the pool to L2ARC device, but upon export it is not stored anywhere
  2. at the first import, vdev_open() sees an vdev_ashift() of 0 and assigns the logical_ashift, which is 9
  3. reading the contents of L2ARC, including the header fails
  4. L2ARC buffers are not restored in ARC.

Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov>
Signed-off-by: George Amanakis <gamanakis@gmail.com>
Closes #14313
Closes #14963

Details

Provenance
g_amanakis_yahoo.comAuthored on Jun 14 2023, 3:01 PM
Brian Behlendorf <behlendorf1@llnl.gov>Committed on Jun 26 2023, 8:59 PM
Parents
rGc12b5829e1e2: Fix the L2ARC write size calculating logic (2)
Branches
Unknown
Tags
Unknown