# Cannot start smartd on Quantum drive



## dougs (Jun 24, 2010)

Hello,

Running FreeBSD 8.0.

I cloned using 'dump' a very old and failing Fujitsu drive that was
mounted as /dev/ad0 to a Quantum drive that was mounted at the time of
dumping as /dev/ad3. I used the method of cloning described in
http://forums.freebsd.org/showthread.php?t=11680. There is a second
drive that was mounted as /dev/ad2. After the clone was completed and
the system was reconfigured taking out the failing drive and inserting
the replacement drive as a master drive. Upon booting in the new drive
configuration, I received the following message that it couldn't boot
from /dev/ad0s1a:


```
,----
| Timecounter "TSC" frequency 1294237239 Hz quality 80
| Timecounters tick every 1.000 msec
| Trying to mount root from ufs:/dev/ad0s1a
| ROOT MOUNT ERROR
| If you have invalid mount options, reboot, and first try the following
| from the loader prompt:
|
| set vfs.root.mountfrom.options=rw
|
| and then remove invalid entries from /etc/fstab
|
| Loader variables:
| vfs.root.mountfrom=ufs:/dev/ad0s1a
| vfs.root.mountfrom.options=rw
`----
```

I found from dmesg that I had the following mounted disks:


```
ad2: 26147MB <QUANTUM FIREBALLP KX27.3 A1S.3700> at ata1-master UDMA66
  ad3: 76293MB <Seagate ST380011A 8.16> at ata1-slave UDMA100
```

I ended up with a mountroot command prompt. After fiddling around, I
finally was able to change the boot order so that it boots from
/dev/ad2s1. I also had to edit the /etc/fstab. After rebooting, I was
able to boot up the system successfully except that I now received an
error message that smartd couldn't start monitoring /dev/ad2 as follows:


```
ad2: FAILURE - SMART status=51<READY,DSC,ERROR> error=4<ABORTED>
```
Ok, check log:


```
root@ftp:/root# tail /var/log/messages
  <..snip..>
  Jun 24 10:26:48 ftp kernel: Trying to mount root from ufs:/dev/ad2s1a
  Jun 24 10:26:48 ftp kernel: GEOM: ufsid/47336891c9952d8a: geometry does not match label (255h,63s != 16h,63s).
  Jun 24 10:26:52 ftp kernel: ad2: FAILURE - SMART status=51<READY,DSC,ERROR> error=4<ABORTED>
  Jun 24 10:26:52 ftp smartd[786]: Unable to register ATA device /dev/ad2 at line 41 of file /usr/local/etc/smartd.conf
  Jun 24 10:26:52 ftp smartd[786]: Unable to register device /dev/ad2 (no Directive -d removable). Exiting.
  Jun 24 10:26:52 ftp root: /etc/rc: WARNING: failed to start smartd
  <..snip..>
  root@ftp:/root#
```
Listing relevant info in smartd.conf:


```
# First (primary) ATA/IDE hard disk.  Monitor all attributes, enable
  # automatic online data collection, automatic Attribute autosave, and
  # start a short self-test every day between 2-3am, and a long self test
  # Saturdays between 3-4am.
  #/dev/hda -a -o on -S on -s (S/../.././02|L/../../6/03)
  /dev/ad2 -a -o on -S on -s (S/../.././02|L/../../6/03)
  /dev/ad3 -a -o on -S on -s (S/../.././02|L/../../6/03)
```

fsck'ing all volumes on /dev/ad2 comes up clean.

Trying to start smartd from command prompt:


```
root@ftp:/root# smartctl -s on /dev/ad2
  smartctl 5.39.1 2010-01-28 r3054 [FreeBSD 8.0-STABLE i386] (local build)
  Copyright (C) 2002-10 by Bruce Allen, [url]http://smartmontools.sourceforge.net[/url]
  
  === START OF ENABLE/DISABLE COMMANDS SECTION ===
  Error SMART Enable failed
  Smartctl: SMART Enable Failed.
  
  A mandatory SMART command failed: exiting. To continue, add one or more '-T permissive' options.
  root@ftp:/root# smartctl -s on -T verypermissive /dev/ad2
  smartctl 5.39.1 2010-01-28 r3054 [FreeBSD 8.0-STABLE i386] (local build)
  Copyright (C) 2002-10 by Bruce Allen, [url]http://smartmontools.sourceforge.net[/url]
  
  === START OF ENABLE/DISABLE COMMANDS SECTION ===
  Error SMART Enable failed
  Smartctl: SMART Enable Failed.

  root@ftp:/root# smartctl -i /dev/ad2
  smartctl 5.39.1 2010-01-28 r3054 [FreeBSD 8.0-STABLE i386] (local build)
  Copyright (C) 2002-10 by Bruce Allen, [url]http://smartmontools.sourceforge.net[/url]
  
  === START OF INFORMATION SECTION ===
  Model Family:     Quantum Fireball Plus KX series
  Device Model:     QUANTUM FIREBALLP KX27.3
  Serial Number:    158002833918
  Firmware Version: A1S.3700
  User Capacity:    27,417,755,648 bytes
  Device is:        In smartctl database [for details use: -P show]
  ATA Version is:   4
  ATA Standard is:  ATA/ATAPI-4 T13 1153D revision 15
  Local Time is:    Thu Jun 24 11:12:35 2010 PDT
  SMART support is: Available - device has SMART capability.
  SMART support is: Enabled
  
  SMART Disabled. Use option -s with argument 'on' to enable it.
  root@ftp:/root# smartctl -t short /dev/ad2
  smartctl 5.39.1 2010-01-28 r3054 [FreeBSD 8.0-STABLE i386] (local build)
  Copyright (C) 2002-10 by Bruce Allen, [url]http://smartmontools.sourceforge.net[/url]
  
  SMART Disabled. Use option -s with argument 'on' to enable it.
  root@ftp:/root# smartctl -a /dev/ad2
  smartctl 5.39.1 2010-01-28 r3054 [FreeBSD 8.0-STABLE i386] (local build)
  Copyright (C) 2002-10 by Bruce Allen, [url]http://smartmontools.sourceforge.net[/url]
  
  === START OF INFORMATION SECTION ===
  Model Family:     Quantum Fireball Plus KX series
  Device Model:     QUANTUM FIREBALLP KX27.3
  Serial Number:    158002833918
  Firmware Version: A1S.3700
  User Capacity:    27,417,755,648 bytes
  Device is:        In smartctl database [for details use: -P show]
  ATA Version is:   4
  ATA Standard is:  ATA/ATAPI-4 T13 1153D revision 15
  Local Time is:    Thu Jun 24 11:16:54 2010 PDT
  SMART support is: Available - device has SMART capability.
  SMART support is: Enabled
  
  SMART Disabled. Use option -s with argument 'on' to enable it.
  root@ftp:/root# smartctl -s on /dev/ad2
  smartctl 5.39.1 2010-01-28 r3054 [FreeBSD 8.0-STABLE i386] (local build)
  Copyright (C) 2002-10 by Bruce Allen, [url]http://smartmontools.sourceforge.net[/url]
  
  === START OF ENABLE/DISABLE COMMANDS SECTION ===
  Error SMART Enable failed
  Smartctl: SMART Enable Failed.
```
 
  A mandatory SMART command failed: exiting. To continue, add one or
more '-T permissive' options.


What do I need to do in order to enable smartd support? Or is this drive indeed failing?

~Doug


----------



## Carpetsmoker (Jun 24, 2010)

As a general hint/note: don't use dump on failing drives, use something like sysutils/dd_rescue instead.


----------



## dougs (Jun 25, 2010)

Okay, the failing drive was reported as *failing* by smarted although fsck was executed on all partitions with no errors being reported. Thus I thought it best to commence cloning ASAP and assumed it was safe to use dump. Was it safe to use dump under this circumstance?

I still don't know what is preventing smartd from starting on the Quantum drive. I might as well go get another drive and clone from the failing drive just to determine whether the Quantum drive is bad.


----------



## wblock@ (Jun 25, 2010)

dougs said:
			
		

> I still don't know what is preventing smartd from starting on the Quantum drive. I might as well go get another drive and clone from the failing drive just to determine whether the Quantum drive is bad.



SMART hasn't been around forever.  Maybe the Quantum doesn't support it.  camcontrol identify has a SMART support listing.


----------



## SirDice (Jun 25, 2010)

Also check the BIOS, SMART needs to be turned on there too. Watch the BIOS POST messages closely. Most BIOS' will print a message if the drive supports SMART.


----------



## Terry_Kennedy (Jun 25, 2010)

SirDice said:
			
		

> Also check the BIOS, SMART needs to be turned on there too.


The "SMART Enable" stuff in the BIOS just causes the BIOS to ask the drive for SMART status when the system boots and interrupt the boot if the drive reports an error. It doesn't control whether FreeBSD / smartd can use SMART operations or not.

When smartd reports the kind of error the OP is seeing, it is because either 1) the drive doesn't support SMART (or has an obsolete / incomplete implementation), or 2) the drive supports SMART but is behind a controller that doesn't pass the SMART commands through to the drive. This is most common with RAID or "intelligent" controllers. The controllers handled by the mpt driver are an example.

While I'm here, I'd also like to say that a passing SMART status does not mean that a drive is good. Within the last week I've run into 2 drives that report via SMART that they're completely healthy, but which have problems that make them unusuable (one drive has a bunch of unreadable sectors which are not correctable by re-writing, and the other one writes garbage instead of data but reads old data just fine). A drive that says it fails SMART is probably really bad, but a drive that reports passing SMART may not be good. Just something to keep in mind...


----------

