How do I prevent the Unsafe Shutdowns reported by smartclt?
5
votes
1
answer
3699
views
Based on a [suggestion by eblock](https://unix.stackexchange.com/questions/621310/is-there-a-way-to-find-the-cause-of-unexpected-power-offs-by-inspecting-logfiles#comment1162035_621310) , I have run
smartctl
several times for the last few days to check for issues. Below, as an example, is the output of sudo smartctl -a /dev/nvme0n1p2
:
smartctl 7.0 2019-05-21 r4917 [x86_64-linux-5.5.7-1-default] (SUSE RPM)
Copyright (C) 2002-18, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF INFORMATION SECTION ===
Model Number: Samsung SSD 970 EVO Plus 500GB
Serial Number: S4EVNZFN503427W
Firmware Version: 2B2QEXM7
PCI Vendor/Subsystem ID: 0x144d
IEEE OUI Identifier: 0x002538
Total NVM Capacity: 500,107,862,016 [500 GB]
Unallocated NVM Capacity: 0
Controller ID: 4
Number of Namespaces: 1
Namespace 1 Size/Capacity: 500,107,862,016 [500 GB]
Namespace 1 Utilization: 94,943,219,712 [94.9 GB]
Namespace 1 Formatted LBA Size: 512
Namespace 1 IEEE EUI-64: 002538 5501ad2a18
Local Time is: Wed Dec 2 11:19:04 2020 CET
Firmware Updates (0x16): 3 Slots, no Reset required
Optional Admin Commands (0x0017): Security Format Frmw_DL Self_Test
Optional NVM Commands (0x005f): Comp Wr_Unc DS_Mngmt Wr_Zero Sav/Sel_Feat Timestmp
Maximum Data Transfer Size: 512 Pages
Warning Comp. Temp. Threshold: 85 Celsius
Critical Comp. Temp. Threshold: 85 Celsius
Supported Power States
St Op Max Active Idle RL RT WL WT Ent_Lat Ex_Lat
0 + 7.80W - - 0 0 0 0 0 0
1 + 6.00W - - 1 1 1 1 0 0
2 + 3.40W - - 2 2 2 2 0 0
3 - 0.0700W - - 3 3 3 3 210 1200
4 - 0.0100W - - 4 4 4 4 2000 8000
Supported LBA Sizes (NSID 0x1)
Id Fmt Data Metadt Rel_Perf
0 + 512 0 0
=== START OF SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED
SMART/Health Information (NVMe Log 0x02)
Critical Warning: 0x00
Temperature: 38 Celsius
Available Spare: 100%
Available Spare Threshold: 10%
Percentage Used: 0%
Data Units Read: 382,321 [195 GB]
Data Units Written: 695,579 [356 GB]
Host Read Commands: 4,525,857
Host Write Commands: 9,680,786
Controller Busy Time: 30
Power Cycles: 205
Power On Hours: 75
Unsafe Shutdowns: 73
Media and Data Integrity Errors: 0
Error Information Log Entries: 209
Warning Comp. Temperature Time: 0
Critical Comp. Temperature Time: 0
Temperature Sensor 1: 38 Celsius
Temperature Sensor 2: 41 Celsius
Error Information (NVMe Log 0x01, max 64 entries)
No Errors Logged
The lines "SMART overall-health self-assessment test result: PASSED" and "No Errors Logged" look reassuring, but the following line doesn't:
Unsafe Shutdowns: 73
According to [Using NVMe Command Line Tools to Check NVMe Flash Health](https://www.percona.com/blog/2017/02/09/using-nvme-command-line-tools-to-check-nvme-flash-health/) by Peter Zaitsev (February 2017), Unsafe Shutdowns refers to
> The number of times a power loss happened without a shutdown notification being sent. Depending on the NVMe device you’re using, an unsafe shutdown might corrupt user data.
There have been a few unexpected shutdowns on my Tuxedo notebook (see [Is there a way to find the cause of unexpected power offs by inspecting logfiles?](https://unix.stackexchange.com/q/621310/158988)) but not 73 times.
According to [this forum post on Tom's Harware (April 2019)](https://forums.tomshardware.com/threads/unsafe-shut-down-smart-data.3468029/) , disabling fast boot might help. Is this correct or is something else needed?
Asked by Tsundoku
(838 rep)
Dec 2, 2020, 10:27 AM
Last activity: Apr 15, 2025, 09:01 PM
Last activity: Apr 15, 2025, 09:01 PM