В домашнем сервере есть жёсткий диск Toshiba DT01ACA300 на 3 TB который работает почти 8 лет или 69623 часов, если быть точным.
На этой неделе мониторинг оповестил что показатель S.M.A.R.T. "Current_Pending_Sector" у этого диска вырос до 32
при этом показатели Reallocated_Sector_Ct и Reallocated_Event_Count пока по нулям.
Для меня это означает что пора искать замену для этого старичка, но особой спешки нет, т.к. этот диск - часть RAID1 и потерю одного диска можно пережить. Однако существует вероятность что второй диск откажет в момент синхронизации массива после добавления нового диска. Прошлый раз менять диск в массиве пришлось 4,5 года назад, но тогда ситуация была печальнее.
На замену взял диск Seagate ST4000VX015 на 4 TB. У этого диска технология записи CMR (Conventional Magnetic Recording), он предназначен для работы 24x7 и есть поддержка Error Recovery Control. Скорость вращения шпинделя меньше 7200 RPM (я не нашёл точной цифры в документации производителя, а продавцы указывают 5900 RPM), но это перестало быть критичным после переноса системы на SSD.
Отчёт smartmontools для Seagate ST4000VX015:
$ sudo smartctl -x /dev/sdc
smartctl 7.3 2022-02-28 r5338 [x86_64-linux-6.1.0-31-amd64] (local build)
Copyright (C) 2002-22, Bruce Allen, Christian Franke, www.smartmontools.org
=== START OF INFORMATION SECTION ===
Device Model: ST4000VX015-3CU104
Serial Number: [REDACTED]
LU WWN Device Id: 5 000c50 0e906d78f
Firmware Version: CV10
User Capacity: 4,000,787,030,016 bytes [4.00 TB]
Sector Sizes: 512 bytes logical, 4096 bytes physical
Rotation Rate: 5400 rpm
Form Factor: 3.5 inches
Device is: Not in smartctl database 7.3/5660
ATA Version is: ACS-3 T13/2161-D revision 5
SATA Version is: SATA 3.1, 6.0 Gb/s (current: 3.0 Gb/s)
Local Time is: Sat Mar 8 14:58:30 2025 +03
SMART support is: Available - device has SMART capability.
SMART support is: Enabled
AAM feature is: Unavailable
APM feature is: Unavailable
Rd look-ahead is: Enabled
Write cache is: Enabled
DSN feature is: Unavailable
ATA Security is: Disabled, NOT FROZEN [SEC1]
Wt Cache Reorder: 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: ( 0) The previous self-test routine completed
without error or no self-test has ever
been run.
Total time to complete Offline
data collection: ( 0) seconds.
Offline data collection
capabilities: (0x73) SMART execute Offline immediate.
Auto Offline data collection on/off support.
Suspend Offline collection upon new
command.
No 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: ( 1) minutes.
Extended self-test routine
recommended polling time: ( 469) minutes.
Conveyance self-test routine
recommended polling time: ( 2) minutes.
SCT capabilities: (0x70bd) SCT Status supported.
SCT Error Recovery Control supported.
SCT Feature Control supported.
SCT Data Table supported.
SMART Attributes Data Structure revision number: 10
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME FLAGS VALUE WORST THRESH FAIL RAW_VALUE
1 Raw_Read_Error_Rate POSR-- 079 064 006 - 72465658
3 Spin_Up_Time PO---- 100 100 000 - 0
4 Start_Stop_Count -O--CK 100 100 020 - 1
5 Reallocated_Sector_Ct PO--CK 100 100 010 - 0
7 Seek_Error_Rate POSR-- 061 060 045 - 1226237
9 Power_On_Hours -O--CK 100 100 000 - 5
10 Spin_Retry_Count PO--C- 100 100 097 - 0
12 Power_Cycle_Count -O--CK 100 100 020 - 1
183 Runtime_Bad_Block -O--CK 100 100 000 - 0
184 End-to-End_Error -O--CK 100 100 099 - 0
187 Reported_Uncorrect -O--CK 100 100 000 - 0
188 Command_Timeout -O--CK 100 100 000 - 0
189 High_Fly_Writes -O-RCK 100 100 000 - 0
190 Airflow_Temperature_Cel -O---K 067 066 040 - 33 (Min/Max 28/34)
191 G-Sense_Error_Rate -O--CK 100 100 000 - 0
192 Power-Off_Retract_Count -O--CK 100 100 000 - 1
193 Load_Cycle_Count -O--CK 100 100 000 - 1
194 Temperature_Celsius -O---K 033 040 000 - 33 (0 28 0 0 0)
195 Hardware_ECC_Recovered -O-RC- 079 064 000 - 72465658
197 Current_Pending_Sector -O--C- 100 100 000 - 0
198 Offline_Uncorrectable ----C- 100 100 000 - 0
199 UDMA_CRC_Error_Count -OSRCK 200 200 000 - 0
240 Head_Flying_Hours ------ 100 253 000 - 5 (31 58 0)
241 Total_LBAs_Written ------ 100 253 000 - 5298367670
242 Total_LBAs_Read ------ 100 253 000 - 61060
||||||_ K auto-keep
|||||__ C event count
||||___ R error rate
|||____ S speed/performance
||_____ O updated online
|______ P prefailure warning
General Purpose Log Directory Version 1
SMART Log Directory Version 1 [multi-sector log support]
Address Access R/W Size Description
0x00 GPL,SL R/O 1 Log Directory
0x01 SL R/O 1 Summary SMART error log
0x02 SL R/O 5 Comprehensive SMART error log
0x03 GPL R/O 5 Ext. Comprehensive SMART error log
0x04 GPL,SL R/O 8 Device Statistics log
0x06 SL R/O 1 SMART self-test log
0x07 GPL R/O 1 Extended self-test log
0x08 GPL R/O 2 Power Conditions log
0x09 SL R/W 1 Selective self-test log
0x0c GPL R/O 2048 Pending Defects log
0x10 GPL R/O 1 NCQ Command Error log
0x11 GPL R/O 1 SATA Phy Event Counters log
0x21 GPL R/O 1 Write stream error log
0x22 GPL R/O 1 Read stream error log
0x24 GPL R/O 512 Current Device Internal Status Data log
0x30 GPL,SL R/O 9 IDENTIFY DEVICE data log
0x80-0x9f GPL,SL R/W 16 Host vendor specific log
0xa1 GPL,SL VS 24 Device vendor specific log
0xa2 GPL VS 8160 Device vendor specific log
0xa6 GPL VS 192 Device vendor specific log
0xa8-0xa9 GPL,SL VS 136 Device vendor specific log
0xab GPL VS 1 Device vendor specific log
0xb0 GPL VS 9048 Device vendor specific log
0xbe-0xbf GPL VS 65535 Device vendor specific log
0xc0 GPL,SL VS 1 Device vendor specific log
0xc1 GPL,SL VS 16 Device vendor specific log
0xc3 GPL,SL VS 8 Device vendor specific log
0xc4 GPL,SL VS 24 Device vendor specific log
0xd1 GPL VS 264 Device vendor specific log
0xd3 GPL VS 1920 Device vendor specific log
0xe0 GPL,SL R/W 1 SCT Command/Status
0xe1 GPL,SL R/W 1 SCT Data Transfer
SMART Extended Comprehensive Error Log Version: 1 (5 sectors)
No Errors Logged
SMART Extended Self-test Log Version: 1 (1 sectors)
No self-tests have been logged. [To run self-tests, use: smartctl -t]
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.
SCT Status Version: 3
SCT Version (vendor specific): 522 (0x020a)
Device State: Active (0)
Current Temperature: 33 Celsius
Power Cycle Min/Max Temperature: 28/34 Celsius
Lifetime Min/Max Temperature: 26/34 Celsius
Under/Over Temperature Limit Count: 0/0
SCT Temperature History Version: 2
Temperature Sampling Period: 3 minutes
Temperature Logging Interval: 94 minutes
Min/Max recommended Temperature: 1/61 Celsius
Min/Max Temperature Limit: 2/60 Celsius
Temperature History Size (Index): 128 (5)
Index Estimated Time Temperature Celsius
6 2025-02-28 07:52 ? -
... ..(120 skipped). .. -
127 2025-03-08 05:26 ? -
0 2025-03-08 07:00 26 *******
1 2025-03-08 08:34 ? -
2 2025-03-08 10:08 28 *********
3 2025-03-08 11:42 33 **************
4 2025-03-08 13:16 34 ***************
5 2025-03-08 14:50 34 ***************
SCT Error Recovery Control:
Read: Disabled
Write: Disabled
Device Statistics (GP Log 0x04)
Page Offset Size Value Flags Description
0x01 ===== = = === == General Statistics (rev 1) ==
0x01 0x008 4 1 --- Lifetime Power-On Resets
0x01 0x010 4 5 --- Power-on Hours
0x01 0x018 6 5298399551 --- Logical Sectors Written
0x01 0x020 6 5551485 --- Number of Write Commands
0x01 0x028 6 61060 --- Logical Sectors Read
0x01 0x030 6 1196 --- Number of Read Commands
0x01 0x038 6 - --- Date and Time TimeStamp
0x03 ===== = = === == Rotating Media Statistics (rev 1) ==
0x03 0x008 4 5 --- Spindle Motor Power-on Hours
0x03 0x010 4 5 --- Head Flying Hours
0x03 0x018 4 1 --- Head Load Events
0x03 0x020 4 0 --- Number of Reallocated Logical Sectors
0x03 0x028 4 0 --- Read Recovery Attempts
0x03 0x030 4 0 --- Number of Mechanical Start Failures
0x03 0x038 4 0 --- Number of Realloc. Candidate Logical Sectors
0x03 0x040 4 1 --- Number of High Priority Unload Events
0x04 ===== = = === == General Errors Statistics (rev 1) ==
0x04 0x008 4 0 --- Number of Reported Uncorrectable Errors
0x04 0x010 4 0 --- Resets Between Cmd Acceptance and Completion
0x05 ===== = = === == Temperature Statistics (rev 1) ==
0x05 0x008 1 33 --- Current Temperature
0x05 0x010 1 - --- Average Short Term Temperature
0x05 0x018 1 - --- Average Long Term Temperature
0x05 0x020 1 34 --- Highest Temperature
0x05 0x028 1 32 --- Lowest Temperature
0x05 0x030 1 - --- Highest Average Short Term Temperature
0x05 0x038 1 - --- Lowest Average Short Term Temperature
0x05 0x040 1 - --- Highest Average Long Term Temperature
0x05 0x048 1 - --- Lowest Average Long Term Temperature
0x05 0x050 4 0 --- Time in Over-Temperature
0x05 0x058 1 70 --- Specified Maximum Operating Temperature
0x05 0x060 4 0 --- Time in Under-Temperature
0x05 0x068 1 0 --- Specified Minimum Operating Temperature
0x06 ===== = = === == Transport Statistics (rev 1) ==
0x06 0x008 4 0 --- Number of Hardware Resets
0x06 0x010 4 0 --- Number of ASR Events
0x06 0x018 4 0 --- Number of Interface CRC Errors
|||_ C monitored condition met
||__ D supports DSN
|___ N normalized value
Pending Defects log (GP Log 0x0c)
No Defects Logged
SATA Phy Event Counters (GP Log 0x11)
ID Size Value Description
0x000a 2 1 Device-to-host register FISes sent due to a COMRESET
0x0001 2 0 Command failed due to ICRC error
0x0003 2 0 R_ERR response for device-to-host data FIS
0x0004 2 0 R_ERR response for host-to-device data FIS
0x0006 2 0 R_ERR response for device-to-host non-data FIS
0x0007 2 0 R_ERR response for host-to-device non-data FIS
В отчёте S.M.A.R.T. видны высокие значения для атрибутов Raw_Read_Error_Rate, Seek_Error_Rate и Hardware_ECC_Recovered, но если заглянуть в Seagate SMART Attribute Specification, то оказывается что эти атрибуты требуют иного подхода к декодированию и на самом деле их значение складывается из количества операций и количества ошибок.
Посмотреть правильные значения можно через Seagate RAW SMART Attributes to Error Converter или через указание вендорских атрибутов для smartctl
$ sudo smartctl -A -v 1,raw48:54 -v 7,raw48:54 -v 195,raw48:54 /dev/sdc smartctl 7.3 2022-02-28 r5338 [x86_64-linux-6.1.0-31-amd64] (local build) Copyright (C) 2002-22, Bruce Allen, Christian Franke, www.smartmontools.org === START OF READ SMART DATA SECTION === SMART Attributes Data Structure revision number: 10 Vendor Specific SMART Attributes with Thresholds: ID# ATTRIBUTE_NAME FLAG VALUE WORST THRESH TYPE UPDATED WHEN_FAILED RAW_VALUE 1 Raw_Read_Error_Rate 0x000f 084 064 006 Pre-fail Always - 0 3 Spin_Up_Time 0x0003 100 100 000 Pre-fail Always - 0 4 Start_Stop_Count 0x0032 100 100 020 Old_age Always - 1 5 Reallocated_Sector_Ct 0x0033 100 100 010 Pre-fail Always - 0 7 Seek_Error_Rate 0x000f 062 060 045 Pre-fail Always - 0 9 Power_On_Hours 0x0032 100 100 000 Old_age Always - 6 10 Spin_Retry_Count 0x0013 100 100 097 Pre-fail Always - 0 12 Power_Cycle_Count 0x0032 100 100 020 Old_age Always - 1 183 Runtime_Bad_Block 0x0032 100 100 000 Old_age Always - 0 184 End-to-End_Error 0x0032 100 100 099 Old_age Always - 0 187 Reported_Uncorrect 0x0032 100 100 000 Old_age Always - 0 188 Command_Timeout 0x0032 100 100 000 Old_age Always - 0 189 High_Fly_Writes 0x003a 100 100 000 Old_age Always - 0 190 Airflow_Temperature_Cel 0x0022 066 066 040 Old_age Always - 34 (Min/Max 28/34) 191 G-Sense_Error_Rate 0x0032 100 100 000 Old_age Always - 0 192 Power-Off_Retract_Count 0x0032 100 100 000 Old_age Always - 1 193 Load_Cycle_Count 0x0032 100 100 000 Old_age Always - 1 194 Temperature_Celsius 0x0022 034 040 000 Old_age Always - 34 (0 28 0 0 0) 195 Hardware_ECC_Recovered 0x001a 084 064 000 Old_age Always - 0 197 Current_Pending_Sector 0x0012 100 100 000 Old_age Always - 0 198 Offline_Uncorrectable 0x0010 100 100 000 Old_age Offline - 0 199 UDMA_CRC_Error_Count 0x003e 200 200 000 Old_age Always - 0 240 Head_Flying_Hours 0x0000 100 253 000 Old_age Offline - 6 (107 48 0) 241 Total_LBAs_Written 0x0000 100 253 000 Old_age Offline - 6980579164 242 Total_LBAs_Read 0x0000 100 253 000 Old_age Offline - 61060
Или пропатчить drivedb чтобы эти атрибуты всегда применялись
--- /var/lib/smartmontools/drivedb/drivedb.orig.h 2025-03-08 16:29:43.152143558 +0300
+++ /var/lib/smartmontools/drivedb/drivedb.h 2025-03-08 17:28:43.291338127 +0300
@@ -4761,9 +4761,12 @@
"", "", ""
},
{ "Seagate Skyhawk", // tested with ST3000VX010-2H916L/CV11, ST6000VX0023-2EF110/SC60
- "ST(1000VX005|2000VX008|3000VX0(09|10)|4000VX007|6000VX00(1|23)|8000VX00(4|22))-.*",
+ "ST(1000VX005|2000VX008|3000VX0(09|10)|4000VX0(07|15)|6000VX00(1|23)|8000VX00(4|22))-.*",
"", "",
+ "-v 1,raw48:r54 "
+ "-v 7,raw48:54 "
"-v 9,msec24hour32 " // CV* Firmware only?
+ "-v 195,raw48:r54 "
"-v 240,msec24hour32"
},
{ "Seagate DB35", // tested with ST3250823ACE/3.03, ST3300831SCE/3.03
Копируем таблицу разделов со старого диска (/dev/sdb) на новый (/dev/sdc) и генерируем новые GUID'ы для скопированных разделов
$ sudo apt-get install gdisk $ sudo sgdisk --backup=sdb-partitions /dev/sdb The operation has completed successfully. $ sudo sgdisk --load-backup=sdb-partitions /dev/sdc Creating new GPT entries in memory. Warning! Current disk size doesn't match that of the backup! Adjusting sizes to match, but subsequent problems are possible! The operation has completed successfully. $ sudo sgdisk --randomize-guids /dev/sdc The operation has completed successfully.
Ставим загрузчик GRUB на новый диск
$ sudo grub-install /dev/sdc Installing for i386-pc platform. Installation finished. No error reported.
Добавляем новый диск в RAID1 и меняем конфигурацию массива чтобы начать синхронизацию
$ sudo mdadm --manage /dev/md0 --add /dev/sdc2
mdadm: added /dev/sdc2
$ sudo mdadm --manage /dev/md1 --add /dev/sdc3
mdadm: added /dev/sdc3
$ sudo mdadm --grow /dev/md0 --raid-devices 3
raid_disks for /dev/md0 set to 3
$ sudo mdadm --grow /dev/md1 --raid-devices 3
raid_disks for /dev/md1 set to 3
$ cat /proc/mdstat
Personalities : [raid1] [linear] [multipath] [raid0] [raid6] [raid5] [raid4] [raid10]
md0 : active raid1 sdc2[4] sdb2[3] sda2[2]
306880 blocks super 1.2 [3/3] [UUU]
bitmap: 0/1 pages [0KB], 65536KB chunk
md1 : active raid1 sdc3[4] sda3[2] sdb3[3]
2929819904 blocks super 1.2 [3/2] [UU_]
[>....................] recovery = 0.1% (3683328/2929819904) finish=278.0min speed=175399K/sec
bitmap: 0/22 pages [0KB], 65536KB chunk
md2 : active raid1 nvme1n1p1[1] nvme0n1p1[0]
976625664 blocks super 1.2 [2/2] [UU]
bitmap: 3/8 pages [12KB], 65536KB chunk
unused devices: <none>
После окончания синхронизации нужно удалить старый диск из массива и изменить количество устройств обратно на 2.
$ sudo mdadm --manage /dev/md0 --fail /dev/sdb2
mdadm: set /dev/sdb2 faulty in /dev/md0
$ sudo mdadm --manage /dev/md0 --remove /dev/sdb2
mdadm: hot removed /dev/sdb2 from /dev/md0
$ sudo mdadm --manage /dev/md1 --fail /dev/sdb3
mdadm: set /dev/sdb3 faulty in /dev/md1
$ sudo mdadm --manage /dev/md1 --remove /dev/sdb3
mdadm: hot removed /dev/sdb3 from /dev/md1
$ sudo mdadm --grow /dev/md0 --raid-devices 2
raid_disks for /dev/md0 set to 2
$ sudo mdadm --grow /dev/md1 --raid-devices 2
raid_disks for /dev/md1 set to 2
$ cat /proc/mdstat
Personalities : [raid1] [linear] [multipath] [raid0] [raid6] [raid5] [raid4] [raid10]
md0 : active raid1 sdc2[4] sda2[2]
306880 blocks super 1.2 [2/2] [UU]
bitmap: 0/1 pages [0KB], 65536KB chunk
md1 : active raid1 sdc3[4] sda3[2]
2929819904 blocks super 1.2 [2/2] [UU]
bitmap: 0/22 pages [0KB], 65536KB chunk
md2 : active raid1 nvme1n1p1[1] nvme0n1p1[0]
976625664 blocks super 1.2 [2/2] [UU]
bitmap: 3/8 pages [12KB], 65536KB chunk
unused devices: <none>
Подскажите пожалуйста, что за программа на первом скрине
ОтветитьУдалитьЭто "староверный" Nagios 4 (nagios.org)
УдалитьБлагодарю, и спасибо за эмоциональный окрас "староверный" - попробую осилить zabbix
УдалитьОчень надеюсь что из вашего сообщения вырастит моя новая профессия