LINUX.IE, website of the Irish Linux Users' Group
Tux rules!

   
Home
New Users
Articles
Download
Projects
Community
Vendors

  Print Version
Email to...
 
Archives:


planetILUG

Recent News

News Archive


Join the
ILUG
on FaceBook


Join the
ILUG
on LinkedIn


Join the
ILUG SETI
Group



















 
 :: Mailing Lists

[ILUG] Dead disc?

[ILUG] Dead disc?

Pádraig Brady P at draigBrady.com
Thu Oct 7 01:37:55 IST 2010


On 06/10/10 20:40, Brendan Halpin wrote:
> On Wed, Oct 06 2010, Brendan Halpin wrote:
> 
>> Thanks everyone for the suggestions.
>>
>> Pádraig Brady wrote:
>>
>>> sounds like someone messed with your partition table
>>> (using a "recovery cd" of some sort?).
>>
>> That's what I'm thinking. 
>>
>>> You should then be able to use grub and fdisk
>>> to recreate mbr and partition tables etc.
>>> If you don't know offsets then you may need
>>> to search for your file systems with something
>>> like gpart.
>>
>> OK, that's where I am, and I've just got gpart to spit out a lot of
>> numbers to me which look like my missing partitions, with size and
>> offset in megabytes. How do I use this? Via fdisk? gparted?
> 
> Philip Trickett pointed me to "gpart -W ..." and now I can read several,
> but not all, of my partitions (home, /, /usr) which means I can see my
> fstab. That shows that I did use LVM the last time (I don't understand
> LVM!) and that I am missing /var /and /usr/local -- it would be good to
> have these back too. Looking at it in GParted doesn't help: 100%
> unallocated according to that!
> 
> fdisk gives this:
> 
> +---------------------------------------------------------------------
> |Disk /dev/sda: 160.0 GB, 160041885696 bytes
> |255 heads, 63 sectors/track, 19457 cylinders
> |Units = cylinders of 16065 * 512 = 8225280 bytes
> |Disk identifier: 0x38000000
> |
> |   Device Boot      Start         End      Blocks   Id  System
> |/dev/sda1               1        1305    10482376    7  HPFS/NTFS
> |/dev/sda2            1306        3736    19527000    7  HPFS/NTFS
> |/dev/sda3            3737        4399     5325547+   5  Extended
> |/dev/sda4            7586       19196    93265324   83  Linux
> |/dev/sda5   *        3750        3791      337333+  83  Linux
> |/dev/sda6            3792        4764     7815591   83  Linux
> |/dev/sda7   ?      186466      186580      917750+  ed  Unknown
> +---------------------------------------------------------------------
> 
> These start and ends look crazy to me. Shouldn't the end of sda3 overlap
> with the logical partitions it contains? I presume the start and end for
> sda7 are just nonsense?

I guess gpart is being unclever with the extended partition 3
That should encapsulate all your extended partitions.
So I'd recreate that with fdisk with the end at 19457.

lvm complicates matters. Google will give you more
info that I could detail here.

If you get stuck, you could always just mount the above partitions
using the live CD, and copy the data somewhere before reinstalling.
As a shortcut to not need to copy it back, you could reinstall
(after verifying file systems with fsck) and mount /home without
reformating.

cheers,
Pádraig.


More information about the ILUG mailing list
Read this without the formatting.
                                                                                                    

 

Hosted by HEAnet


Maintained by the ILUG website team. The aim of Linux.ie is to support and help commercial and private users of Linux in Ireland. You can display ILUG news in your own webpages, read backend information to find out how. Networking services kindly provided by HEAnet, server kindly donated by Dell. Linux is a trademark of Linus Torvalds, used with permission. No penguins were harmed in the production or maintenance of this highly praised website. Looking for the Indian Linux Users' Group? Try here. If you've read all this and aren't a lawyer: you should be!
RSS Version
Powered by Dell