LinuxQuestions.org
Review your favorite Linux distribution.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - General
User Name
Password
Linux - General This Linux forum is for general Linux questions and discussion.
If it is Linux Related and doesn't seem to fit in any other forum then this is the place.

Notices


Reply
  Search this Thread
Old 04-12-2007, 05:10 PM   #1
squarecmb
LQ Newbie
 
Registered: Apr 2007
Posts: 2

Rep: Reputation: 0
how to map a physical disk block to a file


IHAC who has a system running RHEL 4 with a direct attached raid array. Recently a disk failed in the array. I replaced the drive, but the rebuild failed halfway through. The reason the rebuild failed was because another drive in the lun has some bad blocks. I've identified the bad blocks, but need a way to map these blocks to a particular file(s) so I can remove it/them and rebuild the array without any corruption and minimal data loss. Is there an easy way to map a physical disk block to a file? The file system is EXT3 and the luns are mounted using the device path (/dev/sde1). There are no LVMs.
 
Old 04-12-2007, 06:30 PM   #2
stress_junkie
Senior Member
 
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873

Rep: Reputation: 335Reputation: 335Reputation: 335Reputation: 335
I would probably take the approach of taking the computer off line, making a fresh backup, destroy the RAID configuration and recreate it with the new disk, then restore from the backup. I know that a hot swap and RAID rebuild is nice but if I ran into any problems using that approach I would do what I said above. Sometimes it's quicker to take the long road right away.
 
Old 04-12-2007, 09:06 PM   #3
squarecmb
LQ Newbie
 
Registered: Apr 2007
Posts: 2

Original Poster
Rep: Reputation: 0
Yea that was another option. Doing a back up of the file system. Any files contained in the bad blocks will break the back up, but we can work around those files and then start over from scratch with that lun. Thanks for the tip :-)
 
  


Reply



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 On
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
Is there any threat from hard disk having physical bad sectors ??? b0nd Linux - Hardware 3 06-23-2006 12:08 AM
Linking a file on disk to a fake block device? fyhuang Linux - Software 2 10-31-2005 07:23 AM
SYSERR(root): hash map "generics": missing map file /etc/mail/genericstable.db? singying304 Linux - Networking 4 02-28-2005 06:49 AM
Determine physical disk size Kristijan Linux - General 4 01-23-2005 05:56 PM
Installing on more than one physical disk Squiddy Slackware 5 11-02-2003 11:50 AM

LinuxQuestions.org > Forums > Linux Forums > Linux - General

All times are GMT -5. The time now is 06:53 PM.

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
Open Source Consulting | Domain Registration