HomeFreeBSD

zed: Avoid core dump if wholedisk property does not exist

Description

zed: Avoid core dump if wholedisk property does not exist

zed aborts and dumps core in vdev_whole_disk_from_config() if
wholedisk property does not exist. make_leaf_vdev() adds the
property but there may be already pools that don't have the
wholedisk in the label.

Reviewed-by: Ryan Moeller <ryan@iXsystems.com>
Reviewed-by: Alexander Motin <mav@FreeBSD.org>
Reviewed-by: Richard Yao <richard.yao@alumni.stonybrook.edu>
Signed-off-by: Ameer Hamza <ahamza@ixsystems.com>
Closes #14062

Details

Provenance
Ameer Hamza <106930537+ixhamza@users.noreply.github.com>Authored on Oct 21 2022, 5:46 PM
Brian Behlendorf <behlendorf1@llnl.gov>Committed on Nov 8 2022, 6:10 PM
Parents
rGca3a675c746e: zed: Prevent special vdev to be replaced by hot spare
Branches
Unknown
Tags
Unknown

Event Timeline

Brian Behlendorf <behlendorf1@llnl.gov> committed rG8c0684d326b5: zed: Avoid core dump if wholedisk property does not exist (authored by Ameer Hamza <106930537+ixhamza@users.noreply.github.com>).Nov 8 2022, 6:10 PM