Opened 15 years ago

Closed 15 years ago

Last modified 15 years ago

#13 closed enhancement (fixed)

Autodetection doesn't work with -d sat

Reported by: Giuseppe Iuculano Owned by: Christian Franke
Priority: minor Milestone: Release 5.39.1
Component: smartd Version: 5.39
Keywords: Cc: 546566-forwarded@…, Giuseppe Iuculano

Description

Hi,

with:

DEVICESCAN -d sat -n standby -m root -M exec /usr/share/smartmontools/smartd-runner -M test

I got:

# smartd -d
smartd 5.39 2009-08-29 r2879 [i686-pc-linux-gnu] (local build)
Copyright (C) 2002-9 by Bruce Allen, http://smartmontools.sourceforge.net

Opened configuration file /etc/smartd.conf
Drive: DEVICESCAN, implied '-a' Directive on line 23 of file /etc/smartd.conf
Configuration file /etc/smartd.conf was parsed, found DEVICESCAN, scanning devices
In the system's table of devices NO devices found to scan
Unable to monitor any SMART enabled devices. Try debug (-d) option. Exiting...

But with:
DEVICESCAN -n standby -m root -M exec /usr/share/smartmontools/smartd-runner -M test

autodetection works:

# smartd -d
smartd 5.39 2009-08-29 r2879 [i686-pc-linux-gnu] (local build)
Copyright (C) 2002-9 by Bruce Allen, http://smartmontools.sourceforge.net

Opened configuration file /etc/smartd.conf
Drive: DEVICESCAN, implied '-a' Directive on line 23 of file /etc/smartd.conf
Configuration file /etc/smartd.conf was parsed, found DEVICESCAN, scanning devices
Device: /dev/hda, opened
Device: /dev/hda, packet devices [this device CD/DVD] not SMART capable
Unable to register ATA device /dev/hda at line 23 of file /etc/smartd.conf
Device: /dev/hdc, opened
Device: /dev/hdc, packet devices [this device CD/DVD] not SMART capable
Unable to register ATA device /dev/hdc at line 23 of file /etc/smartd.conf
Device: /dev/sda, type changed from 'scsi' to 'sat'
Device: /dev/sda [SAT], opened
Device: /dev/sda [SAT], found in smartd database.
Device: /dev/sda [SAT], is SMART capable. Adding to "monitor" list.
Device: /dev/sdb, type changed from 'scsi' to 'sat'
Device: /dev/sdb [SAT], opened
Device: /dev/sdb [SAT], found in smartd database.
Device: /dev/sdb [SAT], is SMART capable. Adding to "monitor" list.
Monitoring 2 ATA and 0 SCSI devices

Original bug report: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=546566

Change History (7)

comment:1 by Giuseppe Iuculano, 15 years ago

Cc: Giuseppe Iuculano added

comment:2 by Alex Samorukov, 15 years ago

Priority: majorminor
Type: defectenhancement

I`m not sure that this is a real problem. We are detecting sat device only when we adding it (because it is SCSI, initially). -d sata will not work, because we are not able to find sat devices before probing all scsi dev names. Also i have no idea why do you need such configuration. As for me - it is bogus report.

in reply to:  2 ; comment:3 by Giuseppe Iuculano, 15 years ago

Replying to samm2:

Also i have no idea why do you need such configuration. As for me - it is bogus report.

As far as I know, previous stable smartmontools versions required -d sat for sat devices, so it would be nice to not force users to adjust their configuration on upgrade.

Cheers,
Giuseppe.

in reply to:  3 comment:4 by Christian Franke, 15 years ago

Owner: changed from somebody to Christian Franke
Status: newaccepted

Replying to derevko:

As far as I know, previous stable smartmontools versions required -d sat for sat devices, so it would be nice to not force users to adjust their configuration on upgrade.

Yes, smartd.cpp of 5.38 included a first attempt to detect SAT devices behind SCSI. It required 'DEVICESCAN -d sat'. This was Linux related and probably did not make sense for other platforms (see r2306, r2326, r2373).

With current SVN (r2922), 'DEVICESCAN' (without -d) also detects SAT and known USB devices. 'DEVICESCAN -d sat' is no longer needed and actually broken. It returns an empty device list but no error message.

comment:5 by Christian Franke, 15 years ago

Version: 5.39

comment:6 by Christian Franke, 15 years ago

Milestone: Release 5.40
Resolution: fixed
Status: acceptedclosed

r3042 (Linux only, see CHANGELOG for details).

comment:7 by Christian Franke, 15 years ago

Milestone: Release 5.40Release 5.39.1
Note: See TracTickets for help on using tickets.