Sun Microsystems, Inc.  Sun System Handbook - ISO 3.4 June 2011 Internal/Partner Edition
   Home | Current Systems | Former STK Products | EOL Systems | Components | General Info | Search | Feedback

Asset ID: 1-71-1009431.1
Update Date:2009-03-04
Keywords:

Solution Type  Technical Instruction Sure

Solution  1009431.1 :   HOWTO: Check a disk for bad blocks / disk errors in Linux  


Related Items
  • Sun Fire V60x Server
  •  
  • Sun Fire V65x Server
  •  
  • Oracle Secure Global Desktop
  •  
  • Sun Fire V20z Server
  •  
  • Red Hat Enterprise Linux x64
  •  
  • Red Hat Enterprise Linux x86
  •  
  • Sun Linux Platform
  •  
  • Sun Fire V40z Server
  •  
  • Sun LX50 Server
  •  
Related Categories
  • GCS>Sun Microsystems>Servers>x64 Servers
  •  

PreviouslyPublishedAs
213032


Description
This document describes how to use the command badblocks to check a linux disk for bad blocks / disk errors.

Steps to Follow
In order to check for bad blocks on a disk device in the Linux[TM], use the command, "badblocks". The example below is a verbose non-destructive write test:
# badblocks -v -n /dev/hda
3189988
3189989
3189990
3189991
3194176
3194177
3194178
3194179
3194664
3194665
3194666
3194667
Pass completed, 12 bad blocks found.
The "badblocks" command can be very useful in isolating problems with sync'ing LVM  partitions within linux. Many times lvm operations will fail due to bad blocks on a disk. bad blocks on either the source or destination disk within a lvm mirror will cause a sync failure.
badblocks can also be used in conjunction with the e2fsck and mke2fs to mark the blocks as bad. Warning: The mis-use of these commands can cause data loss.
Additional information on the command "badblocks" is available using the "man badblocks" command.


Product
Sun Linux 5.0.3 Platform
Sun Linux 5.0 02/03
Sun Linux 5.0
Sun Java Desktop System Release 3 (Linux)
Sun Java Desktop System Release 2
Sun Java Desktop System Release 2 (Solaris x86)

Internal Comments
For the internal use of Sun Employee's.

"badblocks -v -n {device}" is equivalent to a "format, analyze, verify" in Solaris[TM] SPARC and x86
linux, x86, badblock, badblocks, bad, error, lvm
Previously Published As
81294

Change History
Date: 2005-05-05
User Name: 31620
Action: Approved
Comment: Fixed a typo..
Verified Metadata
Verified Keywords
Verified still correct for audience - currently set to free as it contains JDS in the Product field
Audience left at "free" per FvF http://kmo.central/howto/FvF.html
Checked review date - currently set to 2006-04-21
Checked for TM - none needed
Publishing under the current publication rules of 18 Apr 2005:

Attachments
This solution has no attachment
  Copyright © 2011 Sun Microsystems, Inc.  All rights reserved.
 Feedback