Lost Filesystem on LInux Partition ! HELP !
  • Yokemate of Keyboards
    Yokemate of Keyboards
    magnetic
    Posts: 2129 from 2003/3/1
    From: Los Angeles
    I lost my ext2 Filesystem on my Linux Partition on my Peg2. I was doing an e2fsck and it wrecked the Filesystem. How can I Recover the partition?

    TIA

    magnetic
    Pegasos 2 Rev 2B3 w/ Freescale 7447 "G4" @ 1ghz / 1gb Nanya Ram
    Quad Boot: MorphOS 2.7 | Amiga OS4.1 U4 | Ubuntu PPC GNU/Linux | OS X 10.4
  • »06.06.04 - 00:08
    Profile Visit Website
  • Acolyte of the Butterfly
    Acolyte of the Butterfly
    DethKnight
    Posts: 139 from 2003/6/24
    From: Central USA
    Maybe some help at this forum

    http://www.linuxquestions.org/questions/search.php?s=&action=showresults&searchid=2133599&sortby=lastpost&sortorder=descending
    I am ; therefore you are
  • »06.06.04 - 01:09
    Profile
  • Yokemate of Keyboards
    Yokemate of Keyboards
    magnetic
    Posts: 2129 from 2003/3/1
    From: Los Angeles
    Thanks for the help. Although its alot of x86 help talking of Rescue disks and such. Anyone else with ideas? Stupid me didnt have a backup and I lost my nice MOL install and networking stuff as well as some documents :(

    magnetic
    Pegasos 2 Rev 2B3 w/ Freescale 7447 "G4" @ 1ghz / 1gb Nanya Ram
    Quad Boot: MorphOS 2.7 | Amiga OS4.1 U4 | Ubuntu PPC GNU/Linux | OS X 10.4
  • »06.06.04 - 16:26
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    dholm
    Posts: 296 from 2003/9/1
    From: Malmo, Sweden
    What exactly happened? Was the data corrupted or did it just disappear from the partition table?

    If data was corrupted you will have to boot from a CD (i.e. the Gentoo LiveCD :) and run fsck again and hope it goes ok this time.
    If it has disappeared from the partition table you can create it if you know the exact bounds and everything should be ok.

    How did you manage to break it with fsck? Did you scan a rw-mounted partition?
  • »06.06.04 - 18:37
    Profile Visit Website
  • Yokemate of Keyboards
    Yokemate of Keyboards
    magnetic
    Posts: 2129 from 2003/3/1
    From: Los Angeles
    Dholm

    Thanks for your post. Here's what happened

    My linux install started giving me probs - Gnome 2.4 was acting funny but KDE was fine then the 2.6 kernel would crash half way through loading periodically... I was about to backup my data and I rebooted the box then it came to the maintenece log in and said I needed to run e2fsck.

    Like a moron I did I mounted the filesystem and ran the e2fsck then started to fix in place errors all of a sudden the screen was filled with numbers and it got crazy, I rebooted and OF said there was no filesystem.

    I booted from another Linux HD and could not run e2fsck, rescue, or anything becuase the partition has No filesystem... So what do I do?

    Thanks alot. This is really important.

    magnetic
    Pegasos 2 Rev 2B3 w/ Freescale 7447 "G4" @ 1ghz / 1gb Nanya Ram
    Quad Boot: MorphOS 2.7 | Amiga OS4.1 U4 | Ubuntu PPC GNU/Linux | OS X 10.4
  • »06.06.04 - 21:42
    Profile Visit Website
  • Order of the Butterfly
    Order of the Butterfly
    dholm
    Posts: 296 from 2003/9/1
    From: Malmo, Sweden
    The first thing I would recommend that you do is to dump the entire partition to a file so that you can experiment with it without losing the data (if something goes wrong). The simplest way of doing this is by using: "dd if=/dev/hda<broken partition> of=part.img". The file will be as large as the partition so make sure you point of= to some place with enough free space.
    After you have an image of your partition you can run "losetup /dev/loop0 part.img", that way the file will be connected to a loop device an any normal tool which works on block-devices (filesystems) can work on the filesystem.

    I'm going to look around for some info on ext2/3 recovery before I give you any further advice, as I have never had to do a recovery on this level before.

    Recovered files will end up in /lost+found and have non-descriptive names. Hopefully all your important files are unharmed, but if they end up in lost+found it might take some time sorting out what is important and some files might be corrupt. This step has to be done manually btw. :(
    The Unix command "file" is a real life-saver in such an event.
  • »07.06.04 - 20:44
    Profile Visit Website