Dailydave mailing list archives

Re: The Small Company's Guide to Hard Drive Failure and Linux]


From: miah <jjohnson () sunrise-linux com>
Date: Thu, 18 Nov 2004 11:11:08 -0500

Hi Dave,

On Thu, Nov 18, 2004 at 09:49:09AM -0500, Dave Aitel wrote:
One might think you could use dd to duplicate your drive. I initially 
tried this, and my results were not good. I did remember to use dd 
if=/dev/hda of=/dev/hdc conv=noerror (the noerror flag is important). 
However, this takes forever and a day. Basically it'll take all night. 
So be prepared for that, even on a small drive and a fast system.  They 
sell devices that can do it faster, I think, but you don't have one, do 
you?

Don't forget to increase the blocksize otherwise you're copying
512 bytes at a time, which will take forever. bs=1024k can speed up a
dd disk imaging.  It'll still take a while though.

The other issue with dd is that typically replaces every sector on the 
disk. So you'll need a disk EXACTLY the same size as the previous disk. 
My disk was one meg smaller (40.0 Meg instead of 40.9 Meg). This was an 
annoying problem.

So instead of that, one nice option is just to get your new drive, make 
the partitions manually with fdisk on it to replicate the original 
drive, and then use tar to copy the contents across. I used knoppix 
heavily here.
   
LVM could be good then.  You can do snapshots, and you can migrate
groups to new servers/disks easily.  It also supports hot-resizing of
volumes (depends on filesystem support), you can also easily add space
to your volume groups, and do raid ontop of them as well.

The next step after doing all this is typically to make a plan that 
involves not having to ever do this again. For those of you not in the 
know - you want a hardware supported (get a good modern motherboard) 
RAID-1 solution and you want to be able to swap out one of your two 
drives (mirrored) when Linux tells you that one is bad. You also want to 
have some sort of backup solution running (of course), and you want to 
have a secondary DNS server and a backup machine somewhere in another 
state (or country) that can take over if your main CO-LO goes under or 
something. Something that can provide basic mail and web services is 
nice. It might be good to hire an admin who is not you.
  

Be careful here.  Some ide hardware raid implementations are not really
hardware raid at all, but a software/bios raid that relys on drivers.
Linux has had built in software raid for a while, thats usually faster
than the ide hardware raid, and its supported very well.


-miah

http://www.linuxmafia.com/faq/Hardware/sata.html#fakeraid
http://www.tldp.org/HOWTO/LVM-HOWTO/index.html
http://www.tldp.org/HOWTO/Software-RAID-HOWTO.html
_______________________________________________
Dailydave mailing list
Dailydave () lists immunitysec com
https://lists.immunitysec.com/mailman/listinfo/dailydave


Current thread: