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 <firstname.lastname@example.org> Signed-off-by: Brian Behlendorf <email@example.com>
Updated by Electric Monk over 6 years ago
- Status changed from New to Closed
- % Done changed from 0 to 100
commit 02525cd08fb3730fff3a69cb5376443d481f7839 Author: Chunwei Chen <firstname.lastname@example.org> Date: 2016-04-05T14:41:38.000Z 6842 Fix empty xattr dir causing lockup Reviewed by: Brian Behlendorf <email@example.com> Reviewed by: Dan McDonald <firstname.lastname@example.org> Reviewed by: Matthew Ahrens <email@example.com> Approved by: Robert Mustacchi <firstname.lastname@example.org>