首页 > 代码库 > smartctl 硬盘信息查询
smartctl 硬盘信息查询
1.
/opt/MegaRAID/MegaCli/MegaCli64 -PDList -aALL | grep -E ‘Device Id|Error|Media Type‘
刚刚有提到SSD寿命的问题,在这一并说了吧,使用smartctl可以检测SSD的寿命,当然还有很多其它结果,SSD寿命只是其中一部分,但是对于有RAID卡的主机,需要刚刚获取到的Device Id。
[root@cloud-13 ~]# smartctl -a -d megaraid,4 /dev/sdc1 smartctl 5.43 2012-06-30 r3573 [x86_64-linux-2.6.32-358.123.2.openstack.el6.x86_64] (local build) Copyright (C) 2002-12 by Bruce Allen, http://smartmontools.sourceforge.net/dev/sdc1 [megaraid_disk_04] [SAT]: Device open changed type from ‘megaraid‘ to ‘sat‘Smartctl open device: /dev/sdc1 [megaraid_disk_04] [SAT] failed: SATA device detected, MegaRAID SAT layer is reportedly buggy, use ‘-d sat+megaraid,N‘ to try anyhow
[root@cloud-13 ~]# smartctl -a -d megaraid,4 /dev/sdc1 smartctl 5.43 2012-06-30 r3573 [x86_64-linux-2.6.32-358.123.2.openstack.el6.x86_64] (local build) Copyright (C) 2002-12 by Bruce Allen, http://smartmontools.sourceforge.net/dev/sdc1 [megaraid_disk_04] [SAT]: Device open changed type from ‘megaraid‘ to ‘sat‘Smartctl open device: /dev/sdc1 [megaraid_disk_04] [SAT] failed: SATA device detected, MegaRAID SAT layer is reportedly buggy, use ‘-d sat+megaraid,N‘ to try anyhow [root@cloud-13 ~]# smartctl -a -d sat+megaraid,4 /dev/sdc1 smartctl 5.43 2012-06-30 r3573 [x86_64-linux-2.6.32-358.123.2.openstack.el6.x86_64] (local build) Copyright (C) 2002-12 by Bruce Allen, http://smartmontools.sourceforge.net=== START OF INFORMATION SECTION === Device Model: OCZ INTREPID 3600Serial Number: A21N8061423000004 LU WWN Device Id: 5 e83a97 100006dc5 Firmware Version: 1.4.6.0User Capacity: 800,166,076,416 bytes [800 GB] Sector Size: 512 bytes logical/physical Device is: Not in smartctl database [for details use: -P showall] ATA Version is: 8ATA Standard is: ACS-2 (revision not indicated) Local Time is: Tue Aug 25 15:20:02 2015 CST 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 Warning: This result is based on an Attribute check. General SMART Values: Offline data collection status: (0x00) Offline data collection activity was never started. Auto Offline Data Collection: Disabled.Self-test execution status: ( 249) Self-test routine in progress... 90% of test remaining. Total time to complete Offline data collection: ( 0) seconds. Offline data collection capabilities: (0x1d) SMART execute Offline immediate. No Auto Offline data collection support. Abort Offline collection upon new command. 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: (0x00) Error logging NOT supported. General Purpose Logging supported. Short self-test routine recommended polling time: ( 0) minutes. Extended self-test routine recommended polling time: ( 0) minutes. SMART Attributes Data Structure revision number: 18Vendor Specific SMART Attributes with Thresholds: ID# ATTRIBUTE_NAME FLAG VALUE WORST THRESH TYPE UPDATED WHEN_FAILED RAW_VALUE 5 Reallocated_Sector_Ct 0x0000 100 100 000 Old_age Offline - 0 9 Power_On_Hours 0x0000 100 100 000 Old_age Offline - 3964 12 Power_Cycle_Count 0x0000 100 100 000 Old_age Offline - 28100 Unknown_Attribute 0x0000 100 100 000 Old_age Offline - 2547072171 Unknown_Attribute 0x0000 090 000 000 Old_age Offline - 12030174 Unknown_Attribute 0x0000 071 100 000 Old_age Offline - 20184 End-to-End_Error 0x0000 009 100 000 Old_age Offline - 1282187 Reported_Uncorrect 0x0000 100 100 000 Old_age Offline - 0190 Airflow_Temperature_Cel 0x0000 048 054 000 Old_age Offline - 48195 Hardware_ECC_Recovered 0x0000 000 100 000 Old_age Offline - 0196 Reallocated_Event_Count 0x0000 000 100 000 Old_age Offline - 0197 Current_Pending_Sector 0x0000 000 100 000 Old_age Offline - 0198 Offline_Uncorrectable 0x0000 100 100 000 Old_age Offline - 3562199 UDMA_CRC_Error_Count 0x0000 100 100 000 Old_age Offline - 3443202 Data_Address_Mark_Errs 0x0000 100 100 000 Old_age Offline - 2061332509205 Thermal_Asperity_Rate 0x0000 100 100 000 Old_age Offline - 3000206 Flying_Height 0x0000 000 100 000 Old_age Offline - 0207 Spin_High_Current 0x0000 002 100 000 Old_age Offline - 64208 Spin_Buzz 0x0000 000 100 000 Old_age Offline - 9210 Unknown_Attribute 0x0000 100 100 000 Old_age Offline - 0211 Unknown_Attribute 0x0000 100 100 000 Old_age Offline - 0212 Unknown_Attribute 0x0000 100 100 000 Old_age Offline - 0213 Unknown_Attribute 0x0000 100 100 000 Old_age Offline - 0214 Unknown_Attribute 0x0000 100 100 000 Old_age Offline - 0221 G-Sense_Error_Rate 0x0000 100 100 000 Old_age Offline - 0222 Loaded_Hours 0x0000 100 100 000 Old_age Offline - 0230 Head_Amplitude 0x0000 001 100 000 Old_age Offline - 1233 Media_Wearout_Indicator 0x0000 100 000 000 Old_age Offline - 100249 Unknown_Attribute 0x0000 100 100 000 Old_age Offline - 5792251 Unknown_Attribute 0x0000 100 100 000 Old_age Offline - 22849SMART Error Log not supported Warning! SMART Self-Test Log Structure error: invalid SMART checksum. SMART Self-test log structure revision number 1No self-tests have been logged. [To run self-tests, use: smartctl -t] Device does not support Selective Self Tests/Logging
smartctl 硬盘信息查询
声明:以上内容来自用户投稿及互联网公开渠道收集整理发布,本网站不拥有所有权,未作人工编辑处理,也不承担相关法律责任,若内容有误或涉及侵权可进行投诉: 投诉/举报 工作人员会在5个工作日内联系你,一经查实,本站将立刻删除涉嫌侵权内容。