2

Possible Duplicate:
Using DD for disk cloning

What's the easiest and most reliable, risk free, way of making an exact copy of a hard drive?

We have a drive that's been messed up by someone re-initialising RAID on it and before we start playing with solutions for fixing it i'd like to get an exact copy of it.

Bearing in mind it won't mount to Linux or Windows at this point, what are the options?

The only one that springs to my mind is DD in Linux. Recommendations appreciated.

Matt Peddlesden
  • 165
  • 2
  • 8
  • 2
    This *is* a duplicate, but I don't think it deserves a downvote... – Ben Pilbrow Mar 29 '11 at 07:34
  • Thanks, the main reason for posting this question was to find out if using DD was going to be the right way - it's a fair while since I used it for this kind of thing and wanted to ensure that my approach wasn't going to be an old outdated approach that had since been superceded by modern tools. Thanks to all for confirming! – Matt Peddlesden Mar 29 '11 at 09:27
  • I used the examples in the question I linked to only a few weeks ago - definitely still relevant and still very good :-) – Ben Pilbrow Mar 29 '11 at 09:31

3 Answers3

3

If the device is there at /mnt/md0 or wherever then dd will work, to backup to a file use:

dd if=/dev/md0 of=/tmp/raid1.img

the output can be another device:

dd if=/dev/md0 of=/dev/sdb
Decado
  • 1,949
  • 11
  • 17
2

There are a variety of tools that you can use. dd is probably as good as many. Clonezilla is a good tool, there are more on this wikipedia page too.

user9517
  • 114,104
  • 20
  • 206
  • 289
1

Bearing in mind it won't mount to Linux or Windows at this point, what are the options?

As advised use DD or Clonezilla. They do not need the drive to be mounted - just present and visible by the OS (i guess at one of these points: /dev/sd[0-9] ). If you want to do it to more than one drive from a raid configuration - image/backup them one by one writing their position (sequence in raid) so you know which one after which was in the raid configuration and to witch raid controller port connected

Angel
  • 104
  • 3