Ad Widget

Collapse

Agent2 SMART check is filling system logs with messages about ioctl being deprecated

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • mouchyn
    Junior Member
    • Apr 2021
    • 9

    #1

    Agent2 SMART check is filling system logs with messages about ioctl being deprecated

    Howdy!

    I have noticed that SMART checks through the zabbix-agent2 are filling up the system logs on my CentOS 7 systems with the following message:

    HTML Code:
    kernel: program smartctl is using a deprecated SCSI ioctl, please convert it to SG_IO
    I can reproduce this by manually executing the appropriate zabbix_get command from the server. Running smartcl from the command line on the target/monitored machine does not produce the same error -- only when it is executed by the zabbix agent2. I increased the agent2 log level to 5 and saw this:

    HTML Code:
    2021/04/15 11:15:04.454326 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sda [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.455484 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:04.457243 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdh [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:04.462496 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdf [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:04.466130 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:04.472813 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdb [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:04.475561 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdb [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.475778 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdg [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.477458 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdg [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:04.482200 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdh [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.483892 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdd [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:04.484436 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdh [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:04.487927 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sda [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:04.487963 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sda [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:04.492449 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdb [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:04.500047 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdc [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:04.502332 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdf [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.503107 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdd [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.503242 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdc [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.506451 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sde [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:04.507982 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sde [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.520345 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdd [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:04.527695 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdi [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.529190 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdi [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:04.532616 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdj [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.532640 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdj [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:04.543777 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:04.545494 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdk [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:04.546230 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdk [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.546645 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdl [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:04.548056 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdl [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.550479 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdl [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:04.553876 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdm [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:04.553903 [Smart] stopped looking for RAID devices of areca type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdm [areca_disk#01_enc#01] failed: Input/output error)
    
    2021/04/15 11:15:04.554153 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:04.564481 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdm [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:05.000303 plugin Cpu: executing collector task
    
    2021/04/15 11:15:05.094216 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdf [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:05.099686 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sde [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:05.105982 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdg [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:05.150288 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdi [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:05.154376 [Smart] stopped looking for RAID devices of megaraid type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdj [megaraid_disk_00] failed: cannot open /dev/megaraid_sas_ioctl_node or /dev/megadev0)
    
    2021/04/15 11:15:05.162896 [Smart] stopped looking for RAID devices of sat type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.163083 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.167286 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.167619 [Smart] stopped looking for RAID devices of sat type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.171957 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdc [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:05.172306 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.172486 [Smart] stopped looking for RAID devices of sat type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.174249 [Smart] stopped looking for RAID devices of sat type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.175333 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.180365 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.181215 [Smart] stopped looking for RAID devices of sat type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.185781 [Smart] stopped looking for RAID devices of sat type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.185829 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.224661 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.226081 [Smart] stopped looking for RAID devices of sat type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.226254 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.227546 [Smart] stopped looking for RAID devices of sat type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.247157 [Smart] stopped looking for RAID devices of cciss type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: Smartctl open device: /dev/sdk [cciss_disk_00] [SCSI/SAT] failed: INQUIRY [SAT]: No such device or address)
    
    2021/04/15 11:15:05.248070 [Smart] stopped looking for RAID devices of 3ware type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.248292 [Smart] stopped looking for RAID devices of sat type, err:%!(EXTRA *errors.errorString=failed to get disk data from smartctl: unknown error from smartctl)
    
    2021/04/15 11:15:05.255822 executed direct exporter task for key 'smart.disk.get'
    
    2021/04/15 11:15:05.256032 sending passive check response: [real data output]
    Zabbix is getting SMART data, and everything seems to be working. It's just that there are over 20,000 lines per day of the ioctl warnings in my system logs. Does anyone have any insight?

    Thanks!
  • dinko
    Junior Member
    • Jun 2021
    • 1

    #2
    I have the same problem on ArchLinux, for now I use the following bash script override saved as /usr/local/bin/smartctl
    Code:
    #!/usr/bin/env bash
    case "$@" in
       *areca*|*3ware*|*cciss*|*megaraid* );;
       *) /usr/bin/smartctl "$@" ;;
    esac
    You could also place it somewhere else and set Plugins.Smart.Path= in your zabbix_agent2.conf accordingly

    This works but It would be nice if we could specify smartctl parameters in the config

    Comment

    Working...