Fix empty xattr dir causing lockup
zfs - Zettabyte File System
This fix from ZoL is related to #5833. This appears to detect zeroed XATTR directories like those reported in 5833.
Fix empty xattr dir causing lockup During zfs_rmnode on a xattr dir, if the system crash just after dmu_free_long_range, we would get empty xattr dir in delete queue. This would cause blkid=0 be passed into zap_get_leaf_byblk when doing zfs_purgedir during mount, and would try to do rw_enter on a wrong structure and cause system lockup. We fix this by returning ENOENT when blkid is zero in zap_get_leaf_byblk. Signed-off-by: Chunwei Chen <email@example.com> Signed-off-by: Brian Behlendorf <firstname.lastname@example.org>
Updated by Electric Monk about 4 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
commit 02525cd08fb3730fff3a69cb5376443d481f7839 Author: Chunwei Chen <email@example.com> Date: 2016-04-05T14:41:38.000Z 6842 Fix empty xattr dir causing lockup Reviewed by: Brian Behlendorf <firstname.lastname@example.org> Reviewed by: Dan McDonald <email@example.com> Reviewed by: Matthew Ahrens <firstname.lastname@example.org> Approved by: Robert Mustacchi <email@example.com>