LinuxQuestions.org
Did you know LQ has a Linux Hardware Compatibility List?
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 10-18-2013, 12:18 AM   #1
tkalfaoglu
Member
 
Registered: Oct 2003
Location: Izmir, Turkey
Distribution: Fedora Core 10
Posts: 54

Rep: Reputation: 15
Exclamation RAID1: Urgent.. Two disks out of sync... how to get them back in sync?


Hello. I have a very simple RAID1 system.
Two identical disks sda and sdb, identical partitions on both.

The raid apparently degraded some time ago, and the system kept using /dev/sdb only.

After an fsck, the system booted from /dev/sda..
So, the system went back in time by several months!

I rescued /dev/sdb.. How can I copy stuff from each /dev/sdb partition to /dev/sda?

My intention is to boot from flash, and do a cp -pR from each /dev/sdb partition to its equivalent /dev/sda partition.

Once I collect as much data as possible, I intend to remove sdb to replace it with another drive.

Does that sound good?

Thanks, -turgut

Last edited by tkalfaoglu; 10-18-2013 at 12:46 AM.
 
Old 10-18-2013, 04:42 AM   #2
wildwizard
Member
 
Registered: Apr 2009
Location: Oz
Distribution: slackware64-14.0
Posts: 755

Rep: Reputation: 227Reputation: 227Reputation: 227
You don't want to copy files as that wont fix the RAID flags.

Option 1 both drives in the same place but you can boot sdb
1. You need to boot the system from /dev/sdb
2. You need to check that your running a degraded RAID with only /dev/sdb working
3. You then add /dev/sda back with mdadm --re-add

Option 2 swap the drives so the sdb is sda and boots from there
Similar to option 1 but you swap sda for sdb

re-sync should then be in progress and you can get an indication of the time to completion from /proc/mdstat
 
  


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
LXer: BitTorrent Sync: Automatically sync files on your Linux Devices LXer Syndicated Linux News 0 10-04-2013 04:50 PM
software raid1, underlying disks swamp-dog Linux - General 4 06-08-2013 01:57 PM
New disks (RAID1), not enough space? ScorchPipe Linux - General 1 01-17-2011 02:18 AM
How to re-sync disks (/dev/sdc1, /dev/sdc3, etc) FireRaven Linux - Newbie 1 09-30-2010 01:45 AM
Sync for Samsung Sync master Naphoon Linux - Hardware 1 10-16-2004 07:20 PM


All times are GMT -5. The time now is 12:57 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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration