Mailinglist Archive: opensuse (3378 mails)

< Previous Next >
Re: [SLE] How to put a 4G disk back together??
  • From: Nick LeRoy <nleroy@xxxxxxxxxxx>
  • Date: Wed, 17 Apr 2002 19:30:20 -0500
  • Message-id: <200204180030.g3I0ULV08890@xxxxxxxxxxxxxxxxxxxxx>
On Wednesday 17 April 2002 05:29 pm, Jim Cunning wrote:
> No, I haven't taken the drive apart......
> I have two files, nearly 2G each, that have the two halves of a 4G WinNT
> partition on them. I need to recover, if possible, an erased file from
> somewhere on that disk. The two files I have are:
> -rw-r--r-- 1 root root 2147418112 Apr 11 23:14 hda1-a
> -rw-r--r-- 1 root root 2047441920 Apr 11 23:50 hda1-b
> I created them by booting the 7.3 install floppy, and getting to the point
> where I could switch to one of the other VT consoles and NFS mount my
> Linux system and copy the entire NT partition to my spare Linux drive with
> dd bs=64k if=/dev/hda1 of=/mnt/disk-image/hda1-a
> dd bs=64k skip=32767 if=/dev/hda1 of=/mnt/disk-image/hda1-b

I'm assuming that you did this in 2 chunks because you lacked a single 4G
chunk of free space. Is that correct? I'm also assuming that the first
command also had a count=32767 parameter...

> All this _appeared_ to work fine, and I presume I have the entire NT
> partition in the two files. I have another disk (with identical geometry
> as the NT one) that I'm trying to copy the two files to. I've tried:
> dd bs=64k if=hda1-a of=/dev/hdb1 (this one works fine)
> dd bs=64k seek=32767 if=hda1-b of=/dev/hdb1 (this one fails)

This *should* work. What type of error do you get? A writing past end of
device error?

> cat hda1-a hda1-b >/dev/hdb1 (this fails, too)
> The errors are something like "no room on output file" -- I'm not at the
> machine now, and don't remember exactly. Does anyone have any suggestions
> on how to glue these pieces back together?

I've never tried to do this before, either, but...

How about :
# cat hda1-a hda1-b > hda1
# dd if=hda1 of=/dev/hda1 bs=64k

That's all that I can think of for now. If I come up with something else
I'll follow up.


< Previous Next >
Follow Ups