Linux Help
guides forums blogs
Home Desktops Distributions ISO Images Logos Newbies Reviews Software Support & Resources Linuxhelp Wiki

Welcome Guest ( Log In | Register )



Advanced DNS Management
New ZoneEdit. New Managment.

FREE DNS Is Back

Sign Up Now
 
Reply to this topicStart new topic
> Copying A Partition
frodo44
post Apr 19 2003, 03:04 PM
Post #1


./configure
***

Group: Members
Posts: 95
Joined: 2-December 02
Member No.: 213



I've been trying to copy a partition (hda6 to hda7) and so far have had no luck. At first I thought I would just make an obesely large image file of 6 with dd, the reverse it into 7, but it turns out that singles files are limited to 2 gigs, at least on a fat32 partition. I guess I should explain how I'm doing this. I copy the image file onto one of my windows partitions wich is like 40gigs or something (ample space to put an eight gig file on). Then from there I would put the image onto the hda7 partition, but since I couldn't get the image, it won't work. After that I tried using some crappy program called parted, but it has little documentation, and the --help tag is very cryptic. I did get it to start once, but it gave me something about one of the drives was in incompatibility mode, or something like that. If anyone has a better program/method to suggest I would really appreciate it.

Eric

PS. I'm doing this because I want to put FreeBSD on my system, but it requires a primary, which can't appear after a logical partition, like my linux partitions are. So my plan was to copy my existing slackware installation onto hda7 and then alter fstab and lilo.conf, and a couple other things to get it to work properly.


--------------------
Windows XP; Debian 3.0r2 (Woody)
---
Shuttle AK32 Mobo w/ Athlon XP 1700+ @ 266 FSB
GeForce 4 mx440 64mb
Turtle Beach Santa Cruz 5.1 Surround Sound
256 MB DDRAM
Seagate 80gb, Western Digital 40gb
---
weezle@charter.net
Go to the top of the page
 
+Quote Post
jetblackz
post Apr 20 2003, 12:31 AM
Post #2


./configure
***

Group: Members
Posts: 98
Joined: 1-April 03
Member No.: 613



After you created a new Linux part with cfdisk, fdisk, parted, do

su
mkfs /dev/hda7
* while booted to hda6 *
mkdir /mnt/hda7
mount /dev/hda7 /mnt/hda7
cp -a /bin /boot ...*includes all top directories*... /mnt/hda7


--------------------
Go to the top of the page
 
+Quote Post
frodo44
post Apr 20 2003, 11:20 AM
Post #3


./configure
***

Group: Members
Posts: 95
Joined: 2-December 02
Member No.: 213



I understand what your trying to say there, but I actually tried something similar to that. I just did a straight copy like this

cp /dev/hda6 /dev/hda7

But it didn't work for boot. I think the problem is a little lower level than just copying files from one partition to another. It's probably in the boot sector of the partition (I think like the first 512 bytes). It's hard to say.

Another thing I was thinking of was doing a direct image copy. I hadn't thought of this before (I wanted to make an image file then copy it to the second partition). I guess you could try this:

dd if=/dev/hda6 of=/dev/hda7

But again I think I would have the trouble with my boot sector. If anyone has any tried and true methods it would be helpful, but hey... what's the worse that could happen? Reinstall Linux again? Bwah hah hah ha! I've probably installed linux like 10 times in the last month or so. Anyway, I'm babbling now so I'll shut up.

Eric

PS. Oh yeah, BTW the two partitions are identical in size, so that's the reason why it would work to do a direct image copy. Guess I forgot to mention that.


--------------------
Windows XP; Debian 3.0r2 (Woody)
---
Shuttle AK32 Mobo w/ Athlon XP 1700+ @ 266 FSB
GeForce 4 mx440 64mb
Turtle Beach Santa Cruz 5.1 Surround Sound
256 MB DDRAM
Seagate 80gb, Western Digital 40gb
---
weezle@charter.net
Go to the top of the page
 
+Quote Post
jetblackz
post Apr 20 2003, 02:00 PM
Post #4


./configure
***

Group: Members
Posts: 98
Joined: 1-April 03
Member No.: 613



I don't think you should bother with dd if you're copying the boot sector. It will probably not work because the physical location changed.

If you want pure backup for boot sector,

dd if=/dev/hda6 of=/linux.lnx bs=512 count=1

Don't copy it to /dev/hda7 boot sector. Keep it for backup. After you're done and recovering your system, do

dd if=/linux.lnx of=/dev/hda6

If you must migrate hd6 to 7,

edit /etc/lilo.conf
lilo -v
done


--------------------
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 12th December 2017 - 06:49 PM