LinuxQuestions.org
Download your favorite Linux distribution at LQ ISO.
Home Forums Tutorials Articles Register
Go Back   LinuxQuestions.org > Forums > Non-*NIX Forums > Programming
User Name
Password
Programming This forum is for all programming questions.
The question does not have to be directly related to Linux and any language is fair game.

Notices


Reply
  Search this Thread
Old 08-14-2001, 09:36 AM   #1
thecatandmouse
LQ Newbie
 
Registered: Aug 2001
Location: united states
Distribution: redhat 6.something
Posts: 1

Rep: Reputation: 0
Post dd mirror command for 2 OSes


Hello,

We need to mirror a ~4.5 GB HD onto a ~6GB HD, both IDE, using dd. There are a few issues involved. The source disk has two operating systems - Win98 and a non linux Unix. The target disk is an opened, new HD. How does the target HD need to be formatted? After the source hard disk is copied to the target, file recovery tools should be able to run on the 6GB disk. This means all the information from the Win98 partition needs to be copied exactly, including the FAT and any other things needed. Also, is it possible to copy over bits from the reserved sectors of the source hard drive used for bad sectors? How can these be accessed?

The target hard drive should be just like the source. It should have the same MBR. Does the size difference matter? Does it matter what OSes the source drive is running?

What is the dd command to type to copy the disks the way we want? I believe there also needs to be an extra flag to tell dd not to stop if it encounters an unreadable bit?

Second, the computer that the hard drives are hooked up to does not currently run linux. A rescue floppy with dd on it will be needed. How can I make such a floppy disk with RedHat 6.x?

Linux20485721552.8
 
Old 08-14-2001, 06:06 PM   #2
unSpawn
Moderator
 
Registered: May 2001
Posts: 29,415
Blog Entries: 55

Rep: Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600Reputation: 3600
Usually I'm using partimage to nibble partitions. might be beneficial to look into TCT at porcupine.org. The Coroners Toolkit really is a (perl-based) forensics toolbox, it has some nice tools that can find any "dead" data as well.

dd if=/dev/hda of=/dev/hdb bs=512
* the bs= is for blocksize, so it nibbles per sector.
* add "count=1", set if= to the bootable partition, and of= to mbr.dat to just have the bootsector.

The only problems with dd IIRC, is that the disks need to have the same geometry, and shouldnt have disk activity going on.
Another way might be in using dump on each partition, and restoring tru a pipe to the other disks partitions, but Ive never used that.

To make a bootdisk, there should be mkbootdisk or so. U could also go for a 1 floppy distro like the excellent tomsrtbt, use ure RH cd as rescue cd, or use a fullblown distro like finnix (bootable cd).

HTH, somehow.
 
  


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
Alien OSes sancho5 Linux - General 3 01-26-2006 09:36 PM
GRUB and Other OSes Kyl3 SUSE / openSUSE 2 08-28-2005 07:37 PM
Three OSes - Is it possible? Jongi Linux - General 9 05-20-2005 12:21 PM
Different OSes SnowSurfAir Linux - Software 10 04-17-2004 10:42 PM
Two HDs, Two OSes notslim Linux - General 7 08-05-2003 01:47 PM

LinuxQuestions.org > Forums > Non-*NIX Forums > Programming

All times are GMT -5. The time now is 05:34 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