LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
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-27-2010, 07:51 PM   #1
Caligari2k
LQ Newbie
 
Registered: Oct 2010
Posts: 1

Rep: Reputation: 0
Creating backup disk image of RAID 1 array (MDADM)


We have some servers that run in very harsh environments (research vessel) that need to have high-availability.

We have software RAID 1 for some measure of resiliency, along with proper data backups (tapes etc), however we would like to be able to break out a new server and re-image it (including RAID setup) from a known good copy if the hardware completely fails on the production box. Simplicity of the process is a big plus.

I am interested in any advice on the best way to approach this. My current approach (relatively new to Linux administration, totally new to MDADM) is to use DD to take a complete gzipped copy of one of the RAID'ed devices (from a live CD):
Code:
dd if=/dev/sda bs=4096 | gzip -c > /mnt/external/image/test.img
then reverse the process on the new PC, finally using
Code:
mdadm --assemble
to re-create and re-build the array.

I'm not sure that this is the best approach, or if it will even work. Any advice would be great.
 
Old 10-29-2010, 05:30 AM   #2
feinbein
Member
 
Registered: Jan 2010
Location: Norway
Posts: 76

Rep: Reputation: 12
If your new server is similar hardware (most importantly diskcontroller) you could just clone both disks to the disks in the new server and then put them in to new server at the same position. e.g cloned disk from sata-port0 on original motherboard should go to sata-port0 on new motherboard and the same for sata-port1.
It should boot without having to touch mdadm. You can clone the disks without going through an image file by using something like
Code:
dd if=dev/sda of=/dev/sdb
to save some time. Just make absolutely sure you get the partition-names right to avoid dataloss!!! Check twice before you commit! Believe me, I've been there!

Last edited by feinbein; 10-29-2010 at 05:39 AM.
 
  


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



Similar Threads
Thread Thread Starter Forum Replies Last Post
RAID mdadm cant add disks to array vockleya Linux - Software 4 09-13-2010 05:37 PM
mdadm create,, raid array is not clean dbj Linux - Server 2 11-16-2009 05:36 PM
[SOLVED] Software RAID (mdadm) - RAID 0 returns incorrect status for disk failure/disk removed Marjonel Montejo Linux - General 4 10-04-2009 06:15 PM
I need help on repairing a mdadm raid 5 array compgeek50 Linux - Hardware 0 02-24-2008 08:06 AM
mdadm: re-assembling raid array on new installation hamish Linux - Server 3 06-10-2007 02:23 PM

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

All times are GMT -5. The time now is 08:50 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
Open Source Consulting | Domain Registration