Recover stupid mistake
Roberto Ragusa
mail at robertoragusa.it
Fri May 28 12:44:28 UTC 2010
Mike Martin wrote:
> Well I've made some progress, I have my /,boot and home via parted rescue
> Only problem is that now parted only sees swap as p4, rather than an
> extended partition with swap and my main 711 Gig storage partition
You know where the extended partition starts and ends, you just miss
the end-of-swap/begin-of-data position.
I suppose your swap partition is a well rounded number (1G? 1.5G? 2G?).
Can you read any logs generated when the system was ok?
Or you can try a trick like this:
[root at thinkpad ~]# file -s /dev/sda7
/dev/sda7: Linux/i386 swap file (new style) 1 (4K pages) size 1222821 pages
[root at thinkpad ~]$ bc
bc 1.06
Copyright 1991-1994, 1997, 1998, 2000 Free Software Foundation, Inc.
This is free software with ABSOLUTELY NO WARRANTY.
For details type `warranty'.
1222821*4096
5008674816
quit
[rragusa at thinkpad ~]$
where I understand that my swap partition is around 5,000,000,000 bytes,
which is probably what fdisk gave me for "+5G".
I think the partition size is written into swap space by mkswap, so you
will have the correct number even if you temporarily create a bigger
swap extending partly into your 711G partition.
--
Roberto Ragusa mail at robertoragusa.it
More information about the users
mailing list