1*44e1285cSBrad Davis# $FreeBSD$ 2*44e1285cSBrad Davis# 3*44e1285cSBrad Davis# Sample ZFS problem reports handling. 4*44e1285cSBrad Davis 5*44e1285cSBrad Davisnotify 10 { 6*44e1285cSBrad Davis match "system" "ZFS"; 7*44e1285cSBrad Davis match "type" "fs.zfs.checksum"; 8*44e1285cSBrad Davis action "logger -p local7.warn -t ZFS 'checksum mismatch, zpool=$pool path=$vdev_path offset=$zio_offset size=$zio_size'"; 9*44e1285cSBrad Davis}; 10*44e1285cSBrad Davis 11*44e1285cSBrad Davisnotify 10 { 12*44e1285cSBrad Davis match "system" "ZFS"; 13*44e1285cSBrad Davis match "type" "fs.zfs.io"; 14*44e1285cSBrad Davis action "logger -p local7.warn -t ZFS 'vdev I/O failure, zpool=$pool path=$vdev_path offset=$zio_offset size=$zio_size error=$zio_err'"; 15*44e1285cSBrad Davis}; 16*44e1285cSBrad Davis 17*44e1285cSBrad Davisnotify 10 { 18*44e1285cSBrad Davis match "system" "ZFS"; 19*44e1285cSBrad Davis match "type" "fs.zfs.data"; 20*44e1285cSBrad Davis action "logger -p local7.warn -t ZFS 'pool I/O failure, zpool=$pool error=$zio_err'"; 21*44e1285cSBrad Davis}; 22*44e1285cSBrad Davis 23*44e1285cSBrad Davisnotify 10 { 24*44e1285cSBrad Davis match "system" "ZFS"; 25*44e1285cSBrad Davis match "type" "fs.zfs.zpool"; 26*44e1285cSBrad Davis action "logger -p local7.err -t ZFS 'failed to load zpool $pool'"; 27*44e1285cSBrad Davis}; 28*44e1285cSBrad Davis 29*44e1285cSBrad Davisnotify 10 { 30*44e1285cSBrad Davis match "system" "ZFS"; 31*44e1285cSBrad Davis match "type" "fs.zfs.vdev\..*"; 32*44e1285cSBrad Davis action "logger -p local7.err -t ZFS 'vdev problem, zpool=$pool path=$vdev_path type=$type'"; 33*44e1285cSBrad Davis}; 34*44e1285cSBrad Davis 35*44e1285cSBrad Davisnotify 10 { 36*44e1285cSBrad Davis match "system" "ZFS"; 37*44e1285cSBrad Davis match "type" "fs.zfs.io_failure"; 38*44e1285cSBrad Davis action "logger -p local7.alert -t ZFS 'catastrophic pool I/O failure, zpool=$pool'"; 39*44e1285cSBrad Davis}; 40*44e1285cSBrad Davis 41*44e1285cSBrad Davisnotify 10 { 42*44e1285cSBrad Davis match "system" "ZFS"; 43*44e1285cSBrad Davis match "type" "fs.zfs.probe_failure"; 44*44e1285cSBrad Davis action "logger -p local7.err -t ZFS 'vdev probe failure, zpool=$pool path=$vdev_path'"; 45*44e1285cSBrad Davis}; 46*44e1285cSBrad Davis 47*44e1285cSBrad Davisnotify 10 { 48*44e1285cSBrad Davis match "system" "ZFS"; 49*44e1285cSBrad Davis match "type" "fs.zfs.log_replay"; 50*44e1285cSBrad Davis action "logger -p local7.err -t ZFS 'pool log replay failure, zpool=$pool'"; 51*44e1285cSBrad Davis}; 52*44e1285cSBrad Davis 53*44e1285cSBrad Davisnotify 10 { 54*44e1285cSBrad Davis match "system" "ZFS"; 55*44e1285cSBrad Davis match "type" "fs.zfs.config_cache_write"; 56*44e1285cSBrad Davis action "logger -p local7.warn -t ZFS 'failed to write zpool.cache, zpool=$pool'"; 57*44e1285cSBrad Davis}; 58*44e1285cSBrad Davis 59*44e1285cSBrad Davis 60*44e1285cSBrad Davisnotify 10 { 61*44e1285cSBrad Davis match "system" "ZFS"; 62*44e1285cSBrad Davis match "type" "resource.fs.zfs.removed"; 63*44e1285cSBrad Davis action "logger -p local7.notice -t ZFS 'vdev is removed, pool_guid=$pool_guid vdev_guid=$vdev_guid'"; 64*44e1285cSBrad Davis}; 65*44e1285cSBrad Davis 66*44e1285cSBrad Davisnotify 10 { 67*44e1285cSBrad Davis match "system" "ZFS"; 68*44e1285cSBrad Davis match "type" "resource.fs.zfs.autoreplace"; 69*44e1285cSBrad Davis action "logger -p local7.info -t ZFS 'autoreplace is configured for vdev, pool_guid=$pool_guid vdev_guid=$vdev_guid'"; 70*44e1285cSBrad Davis}; 71*44e1285cSBrad Davis 72*44e1285cSBrad Davisnotify 10 { 73*44e1285cSBrad Davis match "system" "ZFS"; 74*44e1285cSBrad Davis match "type" "resource.fs.zfs.statechange"; 75*44e1285cSBrad Davis action "logger -p local7.notice -t ZFS 'vdev state changed, pool_guid=$pool_guid vdev_guid=$vdev_guid'"; 76*44e1285cSBrad Davis}; 77*44e1285cSBrad Davis 78