[TUTORIAL] Update smartctl Datenbank

sb-jw

Famous Member
Jan 23, 2018
1,843
288
128
32
Hallo zusammen,

da die Datenbank unter PVE hier etwas veraltet scheint oder nicht geupdatet wird, habe ich hier mal eine kleine Anleitung um die Datenbank zu aktualisieren. Auf einem Single Node mit PVE 5.4-3 war noch immer eine Datenbank vom 30.07.2016 enthalten, was in der Regel daher keine neueren SSDs oder auch HDDs unterstützt und daher einige Werte nur mit "Unknown_Attribute" übersetzt.

Command (ich denke, die paar Befehle sind selbst erklärend? :) ):
Code:
mv /var/lib/smartmontools/drivedb/{drivedb.h,drivedb.h.old} &&
\wget -q -P /var/lib/smartmontools/drivedb/ https://raw.githubusercontent.com/mirror/smartmontools/master/drivedb.h &&
\chown root: /var/lib/smartmontools/drivedb/drivedb.h

Output vorher:
Code:
root@<HOST>:~# smartctl -a /dev/sda
smartctl 6.6 2016-05-31 r4324 [x86_64-linux-4.15.18-11-pve] (local build)
Copyright (C) 2002-16, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Device Model:     WDC WDS120G2G0A-00JH30
Serial Number:    xxxxxxxxxxxx
LU WWN Device Id: 5 001b44 xxxxxxxx
Firmware Version: UE450000
User Capacity:    120,040,980,480 bytes [120 GB]
Sector Size:      512 bytes logical/physical
Rotation Rate:    Solid State Device
Form Factor:      2.5 inches
Device is:        Not in smartctl database [for details use: -P showall]
ATA Version is:   ACS-2 T13/2015-D revision 3
SATA Version is:  SATA 3.2, 6.0 Gb/s (current: 6.0 Gb/s)
Local Time is:    Sun Apr 21 15:41:45 2019 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:  (0x00) Offline data collection activity
                                        was never started.
                                        Auto Offline Data Collection: Disabled.
Self-test execution status:      (  32) The self-test routine was interrupted
                                        by the host with a hard or soft reset.
Total time to complete Offline
data collection:                (  120) seconds.
Offline data collection
capabilities:                    (0x15) SMART execute Offline immediate.
                                        No Auto Offline data collection support.
                                        Abort Offline collection upon new
                                        command.
                                        No Offline surface scan supported.
                                        Self-test supported.
                                        No Conveyance Self-test supported.
                                        No 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:        (  21) minutes.

SMART Attributes Data Structure revision number: 1
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  5 Reallocated_Sector_Ct   0x0032   100   100   000    Old_age   Always       -       0
  9 Power_On_Hours          0x0032   100   100   000    Old_age   Always       -       2630
 12 Power_Cycle_Count       0x0032   100   100   000    Old_age   Always       -       14
165 Unknown_Attribute       0x0032   100   100   000    Old_age   Always       -       3000
166 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       56
167 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       0
168 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       135
169 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       57
170 Unknown_Attribute       0x0032   100   100   ---    Old_age   Always       -       0
171 Unknown_Attribute       0x0032   100   100   000    Old_age   Always       -       0
172 Unknown_Attribute       0x0032   100   100   000    Old_age   Always       -       0
173 Unknown_Attribute       0x0032   100   100   000    Old_age   Always       -       56
174 Unknown_Attribute       0x0032   100   100   000    Old_age   Always       -       12
184 End-to-End_Error        0x0032   100   100   ---    Old_age   Always       -       0
187 Reported_Uncorrect      0x0032   100   100   000    Old_age   Always       -       0
188 Command_Timeout         0x0032   100   100   ---    Old_age   Always       -       0
194 Temperature_Celsius     0x0022   061   042   000    Old_age   Always       -       39 (Min/Max 19/42)
199 UDMA_CRC_Error_Count    0x0032   100   100   ---    Old_age   Always       -       0
230 Unknown_SSD_Attribute   0x0032   100   100   000    Old_age   Always       -       9041092020281
232 Available_Reservd_Space 0x0033   100   100   005    Pre-fail  Always       -       100
233 Media_Wearout_Indicator 0x0032   100   100   ---    Old_age   Always       -       6736
234 Unknown_Attribute       0x0032   100   100   000    Old_age   Always       -       16691
241 Total_LBAs_Written      0x0030   100   100   000    Old_age   Offline      -       5279
242 Total_LBAs_Read         0x0030   100   100   000    Old_age   Offline      -       27
244 Unknown_Attribute       0x0032   000   100   ---    Old_age   Always       -       0

SMART Error Log Version: 1
No Errors Logged

SMART Self-test log structure revision number 1
No self-tests have been logged.  [To run self-tests, use: smartctl -t]

Selective Self-tests/Logging not supported

Output nachher:
Code:
root@<HOST>:~# smartctl -a /dev/sda
smartctl 6.6 2016-05-31 r4324 [x86_64-linux-4.15.18-11-pve] (local build)
Copyright (C) 2002-16, Bruce Allen, Christian Franke, www.smartmontools.org

=== START OF INFORMATION SECTION ===
Model Family:     WD Blue and Green SSDs
Device Model:     WDC WDS120G2G0A-00JH30
Serial Number:    xxxxxxxxxxxx
LU WWN Device Id: 5 001b44 xxxxxxxx
Firmware Version: UE450000
User Capacity:    120,040,980,480 bytes [120 GB]
Sector Size:      512 bytes logical/physical
Rotation Rate:    Solid State Device
Form Factor:      2.5 inches
Device is:        In smartctl database [for details use: -P show]
ATA Version is:   ACS-2 T13/2015-D revision 3
SATA Version is:  SATA 3.2, 6.0 Gb/s (current: 6.0 Gb/s)
Local Time is:    Sun Apr 21 15:42:47 2019 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:  (0x00) Offline data collection activity
                                        was never started.
                                        Auto Offline Data Collection: Disabled.
Self-test execution status:      (  32) The self-test routine was interrupted
                                        by the host with a hard or soft reset.
Total time to complete Offline
data collection:                (  120) seconds.
Offline data collection
capabilities:                    (0x15) SMART execute Offline immediate.
                                        No Auto Offline data collection support.
                                        Abort Offline collection upon new
                                        command.
                                        No Offline surface scan supported.
                                        Self-test supported.
                                        No Conveyance Self-test supported.
                                        No 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:        (  21) minutes.

SMART Attributes Data Structure revision number: 1
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  5 Reallocated_Sector_Ct   0x0032   100   100   000    Old_age   Always       -       0
  9 Power_On_Hours          0x0032   100   100   000    Old_age   Always       -       2630
 12 Power_Cycle_Count       0x0032   100   100   000    Old_age   Always       -       14
165 Block_Erase_Count       0x0032   100   100   000    Old_age   Always       -       3000
166 Minimum_PE_Cycles_TLC   0x0032   100   100   ---    Old_age   Always       -       56
167 Max_Bad_Blocks_per_Die  0x0032   100   100   ---    Old_age   Always       -       0
168 Maximum_PE_Cycles_TLC   0x0032   100   100   ---    Old_age   Always       -       135
169 Total_Bad_Blocks        0x0032   100   100   ---    Old_age   Always       -       57
170 Grown_Bad_Blocks        0x0032   100   100   ---    Old_age   Always       -       0
171 Program_Fail_Count      0x0032   100   100   000    Old_age   Always       -       0
172 Erase_Fail_Count        0x0032   100   100   000    Old_age   Always       -       0
173 Average_PE_Cycles_TLC   0x0032   100   100   000    Old_age   Always       -       56
174 Unexpected_Power_Loss   0x0032   100   100   000    Old_age   Always       -       12
184 End-to-End_Error        0x0032   100   100   ---    Old_age   Always       -       0
187 Reported_Uncorrect      0x0032   100   100   000    Old_age   Always       -       0
188 Command_Timeout         0x0032   100   100   ---    Old_age   Always       -       0
194 Temperature_Celsius     0x0022   061   042   000    Old_age   Always       -       39 (Min/Max 19/42)
199 UDMA_CRC_Error_Count    0x0032   100   100   ---    Old_age   Always       -       0
230 Media_Wearout_Indicator 0x0032   100   100   000    Old_age   Always       -       0x08390b140839
232 Available_Reservd_Space 0x0033   100   100   005    Pre-fail  Always       -       100
233 NAND_GB_Written_TLC     0x0032   100   100   ---    Old_age   Always       -       6736
234 NAND_GB_Written_SLC     0x0032   100   100   000    Old_age   Always       -       16691
241 Total_Host_GB_Written   0x0030   100   100   000    Old_age   Offline      -       5279
242 Total_Host_GB_Read      0x0030   100   100   000    Old_age   Offline      -       27
244 Temp_Throttle_Status    0x0032   000   100   ---    Old_age   Always       -       0

SMART Error Log Version: 1
No Errors Logged

SMART Self-test log structure revision number 1
No self-tests have been logged.  [To run self-tests, use: smartctl -t]

Selective Self-tests/Logging not supported
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!