[smartmontools-support] problem with scterc on a mac

Dennis Couzin dcouzin at yahoo.com
Sat Feb 8 15:16:44 CET 2020


Dear Christian,
I don't understand why you asked, but I confirmed that  "smartctl -l scttemp" running on Darwin does print the temperature table:

	evas-system:~ evaheldmann$ smartctl -l scttemp /dev/disk4
	smartctl 7.0 2018-12-30 r4883 [Darwin 16.7.0 x86_64] (local build)
	Copyright (C) 2002-18, Bruce Allen, Christian Franke, www.smartmontools.org

	=== START OF READ SMART DATA SECTION ===
	SCT Status Version:                  3
	SCT Version (vendor specific):       256 (0x0100)
	Device State:                        Active (0)
	Current Temperature:                    28 Celsius
	...
	  13    2020-02-08 13:47    28  *********

I also don't understand the 2008 ATA8-ACS final draft's statement: "a device shall not change these settings while processing a hardware reset or a software reset".  What are hardware or software resets and when do they occur?  Powering off and on certainly does change the ERC settings on some drives (e.g., my WD Red Pro, manufactured 2016) but not on other drives (e.g., my Toshiba N300, manufactured 2019).

Sincerely,
Dennis 


-----Original Message-----
From: Smartmontools-support <smartmontools-support-bounces at listi.jpberlin.de> On Behalf Of Christian Franke
Sent: Friday, 7 February 2020 21:48
To: Dennis Couzin <dcouzin at yahoo.com>
Cc: Smartmontools-support at listi.jpberlin.de
Subject: Re: [smartmontools-support] problem with scterc on a mac

Dennis Couzin via Smartmontools-support wrote:
> Christian Franke, Sun 02/02/2020 16:27, replied to my post of Wed 29/01/2020 22:33:
>
>> The API supports the SMART_WRITE_LOG command, so it should
>> work to set ERC. But you cannot check the result because get
>> ERC does not work due to API restrictions.
>>
>> This may not work because ERC settings are usually not
>> persistent across power cycles and device resets.
> Thanks for warning about non-persistent ERC settings.  Sure enough, for my WD Red Pro drive (4TB SATA), Linux smartctl could set arbitrary scterc,x,y, but on restart the drive reverted to its default settings (70,70).  However, my Toshiba N300 drive (6TB SATA) does take persistent ERC settings.  That is, they persist when set in Linux.

My assumption about device resets was wrong. Here a quote from the 
original spec of this functionality (ATA8-ACS final draft, 2008):

"Read and Write Command Timer values are set to default values at 
power-on but may be altered by an SCT command at any time. A device 
shall not change these settings while processing a hardware reset or a 
software reset."

ACS-4 (2017) added new commands to get/set the Power-on Timer values and 
to restore the factory defaults. Not yet supported by smartctl. May be 
supported by recent devices where smartctl prints "Minimum supported ERC 
Time Limit: ..." in "SCT Status ..." section.


> The Darwin smartctl seems to do something very bad on the Toshiba N300 drive.  It pretends to make new ERC settings, but it actually kills the ERC settings.  Restarting the drive with Linux, I found neither the new ERC settings from the Darwin smartctl nor the previous ERC settings from the Linux smartctl.  Instead there was reversion to this drive's default settings (0,0).  If my experiment was correct, then "smartctl -l scterc,x,y" in Darwin is worse than ineffective; it is dangerous.

Does "smartctl -l scttemp" print the temperature table? If not, we 
should possibly block SMART_WRITE_LOG commands in the Darwin interface 
module.

Regards,
Christian

_______________________________________________
Smartmontools-support mailing list
Smartmontools-support at listi.jpberlin.de
https://listi.jpberlin.de/mailman/listinfo/smartmontools-support




More information about the Smartmontools-support mailing list