mirror of
https://git.proxmox.com/git/mirror_zfs.git
synced 2026-05-22 02:27:36 +03:00
Don't emit cksum_{actual_expected} in ereport.fs.zfs.checksum events
With anything but fletcher-4, even a tiny change in the input will cause the checksum value to change completely. So knowing the actual and expected checksums doesn't provide much more information than "they don't match". The harm in sending them is simply that they bloat the event. In particular, on FreeBSD the event must fit into a 1016 byte buffer. Fixes #14717 for mirrored pools. Reviewed-by: Brian Behlendorf <behlendorf1@llnl.gov> Reviewed-by: Rich Ercolani <rincebrain@gmail.com> Signed-off-by: Alan Somers <asomers@gmail.com> Sponsored-by: Axcient Closes #14717 Closes #15052
This commit is contained in:
committed by
Brian Behlendorf
parent
51a2b59767
commit
b6f618f8ff
@@ -1398,7 +1398,7 @@ vdev_indirect_checksum_error(zio_t *zio,
|
||||
vd->vdev_stat.vs_checksum_errors++;
|
||||
mutex_exit(&vd->vdev_stat_lock);
|
||||
|
||||
zio_bad_cksum_t zbc = {{{ 0 }}};
|
||||
zio_bad_cksum_t zbc = { 0 };
|
||||
abd_t *bad_abd = ic->ic_data;
|
||||
abd_t *good_abd = is->is_good_child->ic_data;
|
||||
(void) zfs_ereport_post_checksum(zio->io_spa, vd, NULL, zio,
|
||||
|
||||
@@ -1785,7 +1785,7 @@ vdev_raidz_checksum_error(zio_t *zio, raidz_col_t *rc, abd_t *bad_data)
|
||||
static int
|
||||
raidz_checksum_verify(zio_t *zio)
|
||||
{
|
||||
zio_bad_cksum_t zbc = {{{0}}};
|
||||
zio_bad_cksum_t zbc = {0};
|
||||
raidz_map_t *rm = zio->io_vsd;
|
||||
|
||||
int ret = zio_checksum_error(zio, &zbc);
|
||||
|
||||
@@ -914,14 +914,6 @@ annotate_ecksum(nvlist_t *ereport, zio_bad_cksum_t *info,
|
||||
|
||||
if (info != NULL && info->zbc_has_cksum) {
|
||||
fm_payload_set(ereport,
|
||||
FM_EREPORT_PAYLOAD_ZFS_CKSUM_EXPECTED,
|
||||
DATA_TYPE_UINT64_ARRAY,
|
||||
sizeof (info->zbc_expected) / sizeof (uint64_t),
|
||||
(uint64_t *)&info->zbc_expected,
|
||||
FM_EREPORT_PAYLOAD_ZFS_CKSUM_ACTUAL,
|
||||
DATA_TYPE_UINT64_ARRAY,
|
||||
sizeof (info->zbc_actual) / sizeof (uint64_t),
|
||||
(uint64_t *)&info->zbc_actual,
|
||||
FM_EREPORT_PAYLOAD_ZFS_CKSUM_ALGO,
|
||||
DATA_TYPE_STRING,
|
||||
info->zbc_checksum_name,
|
||||
|
||||
@@ -515,8 +515,6 @@ zio_checksum_error_impl(spa_t *spa, const blkptr_t *bp,
|
||||
}
|
||||
|
||||
if (info != NULL) {
|
||||
info->zbc_expected = expected_cksum;
|
||||
info->zbc_actual = actual_cksum;
|
||||
info->zbc_checksum_name = ci->ci_name;
|
||||
info->zbc_byteswapped = byteswap;
|
||||
info->zbc_injected = 0;
|
||||
|
||||
Reference in New Issue
Block a user