LinuxQuestions.org
Help answer threads with 0 replies.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices


Reply
  Search this Thread
Old 02-19-2013, 11:51 AM   #1
!! hack-back !!
Member
 
Registered: Nov 2009
Posts: 183

Rep: Reputation: 2
check if hard disk is bad


hello minds ,
i have 6 hard disk in my squid server
1 for system and 5 for caching dirs
my squid cache is tooo slow in browsing
i think the problem i from hard disk
so how i can know if there is bad a hard disk in those 6th ??
thank you
 
Old 02-19-2013, 11:55 AM   #2
amani
Senior Member
 
Registered: Jul 2006
Location: Kolkata, India
Distribution: Debian 64-bit GNU/Linux, Kubuntu64, Fedora QA, Slackware,
Posts: 2,766

Rep: Reputation: Disabled
gsmartctl or smartctl
 
Old 02-19-2013, 12:03 PM   #3
!! hack-back !!
Member
 
Registered: Nov 2009
Posts: 183

Original Poster
Rep: Reputation: 2
what is the full command !!
and i dont want to repair i just know which one is bad and which one is good !!
and should i unmount it before use the command ?
 
Old 02-19-2013, 12:09 PM   #4
amani
Senior Member
 
Registered: Jul 2006
Location: Kolkata, India
Distribution: Debian 64-bit GNU/Linux, Kubuntu64, Fedora QA, Slackware,
Posts: 2,766

Rep: Reputation: Disabled
gsmartctl has a GUI interface.
It will tell you a lot.
No need to unmount, but it is always better to do the long tests from a live parted magic/ system rescue cd.

E.g.

smartctl -a /dev/sda

for sda

---------- Post added Feb 19th, 2013 at 23:40 ----------

smartctl -a /dev/sda

is for smart information (not testing).
 
Old 02-19-2013, 12:13 PM   #5
!! hack-back !!
Member
 
Registered: Nov 2009
Posts: 183

Original Poster
Rep: Reputation: 2
Code:
root@debian:~# smartctl -a /dev/sdb
smartctl 5.40 2010-07-12 r3124 [x86_64-unknown-linux-gnu] (local build)
Copyright (C) 2002-10 by Bruce Allen, http://smartmontools.sourceforge.net

=== START OF INFORMATION SECTION ===
Device Model:     WDC WD1002FAEX-00Y9A0
Serial Number:    WD-WCAW33915529
Firmware Version: 05.01D05
User Capacity:    1,000,204,886,016 bytes
Device is:        Not in smartctl database [for details use: -P showall]
ATA Version is:   8
ATA Standard is:  Exact ATA specification draft version not indicated
Local Time is:    Tue Feb 19 13:12:58 2013 EST
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:  (0x82) Offline data collection activity
                                        was completed without error.
                                        Auto Offline Data Collection: Enabled.
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:                 (17400) seconds.
Offline data collection
capabilities:                    (0x7b) SMART execute Offline immediate.
                                        Auto Offline data collection on/off support.
                                        Suspend Offline collection upon new
                                        command.
                                        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:        (   2) minutes.
Extended self-test routine
recommended polling time:        ( 179) minutes.
Conveyance self-test routine
recommended polling time:        (   5) minutes.
SCT capabilities:              (0x3035) SCT Status supported.
                                        SCT Feature Control supported.
                                        SCT Data Table supported.

SMART Attributes Data Structure revision number: 16
Vendor Specific SMART Attributes with Thresholds:
ID# ATTRIBUTE_NAME          FLAG     VALUE WORST THRESH TYPE      UPDATED  WHEN_FAILED RAW_VALUE
  1 Raw_Read_Error_Rate     0x002f   191   190   051    Pre-fail  Always       -       210
  3 Spin_Up_Time            0x0027   176   175   021    Pre-fail  Always       -       4175
  4 Start_Stop_Count        0x0032   100   100   000    Old_age   Always       -       853
  5 Reallocated_Sector_Ct   0x0033   200   200   140    Pre-fail  Always       -       0
  7 Seek_Error_Rate         0x002e   200   200   000    Old_age   Always       -       0
  9 Power_On_Hours          0x0032   100   100   000    Old_age   Always       -       319
 10 Spin_Retry_Count        0x0032   100   100   000    Old_age   Always       -       0
 11 Calibration_Retry_Count 0x0032   100   100   000    Old_age   Always       -       0
 12 Power_Cycle_Count       0x0032   100   100   000    Old_age   Always       -       853
192 Power-Off_Retract_Count 0x0032   199   199   000    Old_age   Always       -       851
193 Load_Cycle_Count        0x0032   200   200   000    Old_age   Always       -       1
194 Temperature_Celsius     0x0022   104   100   000    Old_age   Always       -       43
196 Reallocated_Event_Count 0x0032   200   200   000    Old_age   Always       -       0
197 Current_Pending_Sector  0x0032   200   200   000    Old_age   Always       -       9
198 Offline_Uncorrectable   0x0030   200   200   000    Old_age   Offline      -       10
199 UDMA_CRC_Error_Count    0x0032   200   200   000    Old_age   Always       -       0
200 Multi_Zone_Error_Rate   0x0008   200   200   000    Old_age   Offline      -       13

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]


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.


---------- Post added 02-19-13 at 01:14 PM ----------

iam on command line not gui
 
Old 02-19-2013, 12:59 PM   #6
!! hack-back !!
Member
 
Registered: Nov 2009
Posts: 183

Original Poster
Rep: Reputation: 2
is this command good ?
badblocks -v /dev/sdc
 
Old 02-19-2013, 01:09 PM   #7
whizje
Member
 
Registered: Sep 2008
Location: The Netherlands
Distribution: Slackware64 current
Posts: 593

Rep: Reputation: 140Reputation: 140
Code:
smartctl --test=long /dev/sda          #(Executes extended disk self-test)
smartctl --test=short /dev/sda          #(Executes short disk self-test)
 
Old 02-19-2013, 02:14 PM   #8
Habitual
LQ Veteran
 
Registered: Jan 2011
Location: Yawnstown, Ohio
Distribution: Mojave
Posts: 9,374
Blog Entries: 37

Rep: Reputation: Disabled
Quote:
Originally Posted by !! hack-back !! View Post
is this command good ?
badblocks -v /dev/sdc
An OS version build/platform may just help!
 
Old 02-19-2013, 03:57 PM   #9
!! hack-back !!
Member
 
Registered: Nov 2009
Posts: 183

Original Poster
Rep: Reputation: 2
thank you i used badblocks -v /dev/{device}
but it take about 4-5 hours to finish
 
Old 02-20-2013, 11:02 AM   #10
jsaravana87
Member
 
Registered: Aug 2011
Location: Chennai,India
Distribution: Redhat,Centos,Ubuntu,Dedian
Posts: 558
Blog Entries: 5

Rep: Reputation: Disabled
Below command gives you extended information of failing hardrive


#smartctl --attributes --log=selftest /dev/sda
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
how do I check my hard disk for errors. possible hard disk failure lgtrean Linux - Hardware 6 06-22-2011 04:06 PM
Check hda (disk with centos) for bad blocks (LVM) c087 Linux - Hardware 3 09-11-2008 06:37 PM
Bad hard disk? Anything I can try? jnsg Slackware 10 08-21-2006 01:28 AM
NMI, Machine check errors=bad hard drive? robber49 Linux - Hardware 1 04-08-2005 07:59 PM
How to I check a Linux formated hard drive for bad sectors NewtoLinuxWorld Linux - Hardware 1 02-27-2004 03:46 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 09:20 AM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration