LinuxQuestions.org
Go Job Hunting at the LQ Job Marketplace
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Hardware
User Name
Password
Linux - Hardware This forum is for Hardware issues.
Having trouble installing a piece of hardware? Want to know if that peripheral is compatible with Linux?

Notices

Reply
 
Search this Thread
Old 11-27-2004, 07:00 AM   #1
wrc1944
Member
 
Registered: Aug 2002
Location: Gainesville, Florida
Distribution: Gentoo ~x86 2007.0
Posts: 139

Rep: Reputation: 15
Clone with dd if=/dev/hda of=/dev/hdb question


I have a dual boot 20GB drive with winxp (4 partitions, FAT32), and Mandrake 10.0 (4 partitions, reiser3).

Is there any way to use dd if=/dev/hda of=/dev/hdb from a knoppix live cd boot, to copy the 20GB into a 40GB or larger drive, having it bootable, and also have dd expand all the copied partitions into proportional sizes on the larger drive, using the entire drive? In otherwords, like Drive Image would handle a winxp only installation.

I was just about try this, but then luckily read where expert Neddy Seagoon on the Gentoo formum says not to use dd for this, as it will only make an exact 20GB copy, including the MBR partition table, and thus make the remaining free space on the new drive unusable. Is this correct, and is there any way around this limitation? I've googled for many hours, read the Gentoo and knoppix forums, and can't find anything explaining my exact circumstances.

I need winxp to run professional Music sequencing etc. software- Rosegarden is just not well-developed enough yet (hopefully soon!), compared to Cubase or Cakewalk Sonar4. I use Gentoo for everything else, but unfortunately in this case it appears I'm going to have to use winxp. I need to clone my xp to a new larger faster drive, on the same box.

Thanks,
wrc1944
 
Old 11-27-2004, 10:52 AM   #2
jailbait
Guru
 
Registered: Feb 2003
Location: Blue Ridge Mountain
Distribution: Debian Wheezy, Debian Jessie
Posts: 7,476

Rep: Reputation: 156Reputation: 156
"Is there any way to use dd if=/dev/hda of=/dev/hdb from a knoppix live cd boot, to copy the 20GB into a 40GB or larger drive, having it bootable, and also have dd expand all the copied partitions into proportional sizes on the larger drive, using the entire drive?"

No.

"I was just about try this, but then luckily read where expert Neddy Seagoon on the Gentoo formum says not to use dd for this, as it will only make an exact 20GB copy, including the MBR partition table, and thus make the remaining free space on the new drive unusable. Is this correct, "

Yes.

"is there any way around this limitation?"

Before you start make a boot floppy so that you can get back into your old Mandrake system if something doesn't work right.

Boot into Mandrake. Use fdisk to partition the new drive. Use mkfs to format the new Linux partitions. Use tar to copy the Linux partitions to the new partitions. Edit your grub.conf or lilo.conf on your new drive. chroot to / on new Mandrake and run lilo or grub-install. Boot into the new Mandrake and copy Windows using dd. The Windows file structure is simple minded enough that copying Windows that way should work.

---------------------------
Steve Stites

Last edited by jailbait; 11-27-2004 at 10:55 AM.
 
Old 11-28-2004, 09:10 AM   #3
aus9
Guru
 
Registered: Oct 2003
Posts: 5,056

Rep: Reputation: Disabled
if you have nothing to lose try this

1) dd as above
2) knoppix run qt_parted which you use to resize your partitions
3) hopefully when you click on apply it should overwrite the mbr

4) workaround if above fails....see if qtparted sees your partitions as PRIMARY if they are change one to extended then add a partition for the free space then resize and delete/shrink the newly created one

just a thought never tried it myself
 
  


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
/dev/hda under lilo.conf even thoug my HD is under /dev/hdb Basel Slackware 8 10-27-2005 06:00 PM
dd if=/dev/hda of=dev/hdb taking forever to complete fechin Linux - Hardware 7 06-19-2005 12:04 AM
can't boot anymore /dev/hdb -> /dev/hde broxtor Linux - Hardware 4 11-13-2004 10:55 AM
mv c:\WINDOWS /dev/null; mount /dev/hda treehead LinuxQuestions.org Member Intro 5 10-19-2004 08:53 AM
How can I boot either one of my hard drives /dev/hda or /dev/hdb, I have RH9 and FC2 omogunkristi Linux - General 1 06-21-2004 05:11 AM


All times are GMT -5. The time now is 12:45 PM.

Main Menu
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