Bug 859869

Summary: discrepancy between palimpsest and smartmontools
Product: [Fedora] Fedora Reporter: Joachim Backes <joachim.backes>
Component: udisksAssignee: David Zeuthen <davidz>
Status: CLOSED NOTABUG QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 18CC: davidz, mclasen
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2012-09-24 14:54:36 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
palimpsest window
none
sudo udisksctl dump>udsikctl.dump
none
sudo udevadm info --export-db>udevadm.info none

Description Joachim Backes 2012-09-24 08:55:00 UTC
Created attachment 616425 [details]
palimpsest window

Description of problem:
Running palimpsest for my sata disks (/dev/sda for example) reports in the palimpsest window:

Assessment: SMART is not enabled

But "smartctl -a /dev/sda" is able to read and report the smart data.

Version-Release number of selected component (if applicable):
gnome-disk-utility-3.4.1-1.fc17.x86_64

Seems similar to BZ 767145

How reproducible:
always

Steps to Reproduce:
1.run palimpsest
2.
3.
  
Actual results:
Assessment: SMART is not enabled

Expected results:
Smart data can be read

Additional info:

Disk smart data (/dev/sda):
============================
smartctl 5.43 2012-06-30 r3573 [x86_64-linux-3.5.4-1.fc17.x86_64] (local build)
Copyright (C) 2002-12 by Bruce Allen, http://smartmontools.sourceforge.net

=== START OF INFORMATION SECTION ===
Model Family:     Western Digital Caviar Blue Serial ATA
Device Model:     WDC WD5000AAKS-00UU3A0
Serial Number:    WD-WCAYU0114219
LU WWN Device Id: 5 0014ee 1ad259f8f
Firmware Version: 01.03B01
User Capacity:    500,107,862,016 bytes [500 GB]
Sector Size:      512 bytes logical/physical
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   8
ATA Standard is:  Exact ATA specification draft version not indicated
Local Time is:    Mon Sep 24 10:50:19 2012 CEST
SMART support is: Available - device has SMART capability.
SMART support is: Enabled

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED

General SMART Values:
Offline data collection status:  (0x82)	Offline data collection activity
					was completed without error.
					Auto Offline Data Collection: Enabled.
Self-test execution status:      (   0)	The previous self-test routine completed
					without error or no self-test has ever 
					been run.
Total time to complete Offline 
data collection: 		( 7980) seconds.
Offline data collection
capabilities: 			 (0x7b) SMART execute Offline immediate.
					Auto Offline data collection on/off support.
					Suspend Offline collection upon new
					command.
					Offline surface scan supported.
					Self-test supported.
					Conveyance Self-test supported.
					Selective Self-test supported.
SMART capabilities:            (0x0003)	Saves SMART data before entering
					power-saving mode.
					Supports SMART auto save timer.
Error logging capability:        (0x01)	Error logging supported.
					General Purpose Logging supported.
Short self-test routine 
recommended polling time: 	 (   2) minutes.
Extended self-test routine
recommended polling time: 	 (  95) minutes.
Conveyance self-test routine
recommended polling time: 	 (   5) minutes.
SCT capabilities: 	       (0x3037)	SCT Status supported.
					SCT Feature Control supported.
					SCT Data Table supported.

SMART Attributes Data Structure revision number: 16
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x002f   200   200   051    Pre-fail  Always       -       0
  3 Spin_Up_Time            0x0027   140   139   021    Pre-fail  Always       -       3958
  4 Start_Stop_Count        0x0032   099   099   000    Old_age   Always       -       1164
  5 Reallocated_Sector_Ct   0x0033   200   200   140    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x002e   100   253   000    Old_age   Always       -       0
  9 Power_On_Hours          0x0032   083   083   000    Old_age   Always       -       13003
 10 Spin_Retry_Count        0x0032   100   100   000    Old_age   Always       -       0
 11 Calibration_Retry_Count 0x0032   100   100   000    Old_age   Always       -       0
 12 Power_Cycle_Count       0x0032   099   099   000    Old_age   Always       -       1069
192 Power-Off_Retract_Count 0x0032   200   200   000    Old_age   Always       -       168
193 Load_Cycle_Count        0x0032   200   200   000    Old_age   Always       -       995
194 Temperature_Celsius     0x0022   109   096   000    Old_age   Always       -       34
196 Reallocated_Event_Count 0x0032   200   200   000    Old_age   Always       -       0
197 Current_Pending_Sector  0x0032   200   200   000    Old_age   Always       -       0
198 Offline_Uncorrectable   0x0030   200   200   000    Old_age   Offline      -       0
199 UDMA_CRC_Error_Count    0x0032   200   200   000    Old_age   Always       -       0
200 Multi_Zone_Error_Rate   0x0008   200   200   000    Old_age   Offline      -       0

SMART Error Log Version: 1
No Errors Logged

SMART Self-test log structure revision number 1
Num  Test_Description    Status                  Remaining  LifeTime(hours)  LBA_of_first_error
# 1  Short offline       Completed without error       00%      1069         -
# 2  Short offline       Aborted by host               60%         5         -

SMART Selective self-test log data structure revision number 1
 SPAN  MIN_LBA  MAX_LBA  CURRENT_TEST_STATUS
    1        0        0  Not_testing
    2        0        0  Not_testing
    3        0        0  Not_testing
    4        0        0  Not_testing
    5        0        0  Not_testing
Selective self-test flags (0x0):
  After scanning selected spans, do NOT read-scan remainder of disk.
If Selective self-test is pending on power-up, resume after 0 minute delay.

Comment 1 David Zeuthen 2012-09-24 14:29:06 UTC
The Disks application (neé Palimpsest) is only the GUI - udisks, udev and the kernel is where this information is from. Please attach (as plain text files) the output of 'udisksctl dump' and 'udevadm info --export-db'.

Comment 2 Joachim Backes 2012-09-24 14:36:59 UTC
(In reply to comment #1)
> The Disks application (neé Palimpsest) is only the GUI - udisks, udev and
> the kernel is where this information is from. Please attach (as plain text
> files) the output of 'udisksctl dump'

See attachment file udsikctl.dump 
and attachment file udevadm.info

Comment 3 Joachim Backes 2012-09-24 14:38:06 UTC
Created attachment 616591 [details]
sudo udisksctl dump>udsikctl.dump

Comment 4 Joachim Backes 2012-09-24 14:38:57 UTC
Created attachment 616592 [details]
sudo udevadm info --export-db>udevadm.info

Comment 5 David Zeuthen 2012-09-24 14:46:58 UTC
Comment on attachment 616591 [details]
sudo udisksctl dump>udsikctl.dump

Please pay attention to the MIME type so the attachment is viewable in the browser.

Comment 6 David Zeuthen 2012-09-24 14:47:33 UTC
Comment on attachment 616592 [details]
sudo udevadm info --export-db>udevadm.info

Please pay attention to the MIME type so the attachment is viewable in the browser.

Comment 7 Joachim Backes 2012-09-24 14:49:22 UTC
I have to apologize - I simply forgot to choose other filenames :-(

Comment 8 David Zeuthen 2012-09-24 14:54:36 UTC
> E: ID_ATA_FEATURE_SET_SMART=1
> E: ID_ATA_FEATURE_SET_SMART_ENABLED=0

Actually SMART is disabled for your disk (use e.g. hdparm(8) to enable it) so we are doing the correct thing by not trying to use any of the SMART commands [1] on it. It's subtle but the UI actually says "SMART is not enabled" as opposed to "SMART is not available".

Why does it work this way? Because if SMART is disabled [1] we assume it's disabled for a reason - e.g. to avoid the OS poking and interfering with the drive.

Closing NOTABUG since there things are working as intended.

[1] : SMART is enabled by default on new disks coming out of the factory (for all drives that I've ever seen)

Comment 9 Joachim Backes 2012-09-24 15:29:50 UTC
Hi David,

sorry, but I don't understand what you wrote!

What I did, was "sudo smartctl -s on /dev/sda" and "sudo smartctl -s on /dev/sdb".

The man page of smartctl says:


  -s VALUE, --smart=VALUE
              Enables  or  disables  SMART  on device.  The valid arguments to
              this option are on and off...

So using "on" should enable smart for these drives.

Still palimpsest is not successful in reading the smart info :-(

Additionally, hdparm has no option to enable smart (I scanned the whole "man 8 hdparm" output for smart, and nothing was found!

Obviously I'm doing something wrong?less

Kind regards

Joachim

Comment 10 David Zeuthen 2012-09-24 15:51:37 UTC
You have to either reboot or do something like this

 echo change > /sys/block/sda/uevent

otherwise the udev database and the rest of userspace is not notified about the change.

Comment 11 Joachim Backes 2012-09-24 16:10:00 UTC
(In reply to comment #10)
> You have to either reboot or do something like this
> 
>  echo change > /sys/block/sda/uevent
> 
> otherwise the udev database and the rest of userspace is not notified about
> the change.

Hi David, thank you very much for this information! Now I can read smart data with palimpsest :-)

Kind regards

Joachim

Comment 12 David Zeuthen 2012-09-24 17:00:45 UTC
Glad to hear you can read SMART data. I've now filed

 https://bugzilla.gnome.org/show_bug.cgi?id=684729

to have a switch button to turn SMART on and off from the GUI.