[Techtalk] Partitioning issues.

Jacinta Richardson jarich at perltraining.com.au
Fri Jul 25 16:28:00 EST 2003


G'day Staci,

I'm sorry to hear that you took the bad advice and you've got these
problems.  This is my advice (well and my fiance's advice too).  I
personally have never ever ever been in this situation, but I have some
ideas on what you want to do now.

a)  back up what you've got now.  100%.  Do a disk copy of your current
hard drive (the unhappyily partitioned one) onto other media.  dd might be
your friend here or you might have some other tool.  copying to tape is
good, or to another hard drive if you have one spare with enough room.

The idea is to ensure you have a backup of your data in case something in
the recovery step goes disasterously wrong.

b) test the above backup.  Make sure the data on both mediums is now
identical.

c)  write down all the things you've done so far.
    you used fdisk, that's not the end of the world.

    Have you changed your data at all?  What does gpart do?

If all you've done is messed around with the partition table, if you
haven't run mke2fs or fsck you might be in luck.

If you haven't trashed your data, you may be able to rebuild the partition
table to what it was.  (You took a backup of the partition table?  If yes
dd may be your friend, if no.....)

When you rebuild the partition table (using the same tool as you first
changed it with, fdisk in this case?)  you MUST make sure that the
cylinders for the start of your partition are the same as what they were
before.  This is the hard bit.

It may be possible to walk over your disk in a read only manner to detect
the edges of your previous partitions and work out the cylinders from
that.  Let me know if you need more help in this area.

You said that you had one big partition.  If this is it then this should
be easy enough to put back, starts at start of disk, ends at end.  :)

Once you've repartitioned, make sure that the kernal gets the new
partition table (which may require a reboot) and then try mounting it in
read only mode.  Make sure that this partition is NOT in /etc/fstab
because running fsck over it could corrupt your data in this fragile
state.

If it all looks good, you can probably run a manual fsck over it (it'll
ask before making changes) or if it looks good try to recover your data
from it directly.

All the best, and good luck.

	Jacinta

PS:  if any of the above is unclear please feel free to ask more
questions.


--
   ("`-''-/").___..--''"`-._          |  Jacinta Richardson         |
    `6_ 6  )   `-.  (     ).`-.__.`)  |  Perl Training Australia    |
    (_Y_.)'  ._   )  `._ `. ``-..-'   |      +613 9354 6001         |  
  _..`--'_..-_/  /--'_.' ,'           | contact at perltraining.com.au |
(il),-''  (li),'  ((!.-'              |   www.perltraining.com.au   |



More information about the Techtalk mailing list