Page 1 of 2 12 LastLast
Results 1 to 10 of 12

Thread: HELP. Editing Partitions and Lost Everything

  1. #1
    Join Date
    May 2009
    Location
    Boston, MA
    Beans
    26
    Distro
    Ubuntu 13.10 Saucy Salamander

    Exclamation HELP. Editing Partitions and Lost Everything

    I was editing my partitions last night because i had done a poor job allocating space when i installed ubuntu. I had given root 280gb and it turns out it didnt need nearly that much. So i decided to shrink it to 50gb, leave 100gb open to install windows xp on, and put the rest into my home partition. I used the live cd and everything seemed to work fine. When i rebooted it was all good.

    However when i tried to install windows i kept getting an error message that windows could not write to the hard disk and i needed to create a partition windows could use. I tried a few times to create an ntfs partition in the 100gb partition but no dice. So i figured it was a bad cd and quit the setup process. When i rebooted this time it said it could not find the OS. I fired up the live cd again, which i'm on now and checked the partitions, thinking windows had mislabeled something, and it says my whole HD is unallocated with no partitions. I don't know how this happened, what i did, or how to fix it. I need some help here.

  2. #2
    Join Date
    Mar 2009
    Beans
    18

    Re: HELP. Editing Partitions and Lost Everything

    I'am in no way anywhere as familiar with Linux as a lot of these people, and have only been using Ubuntu a few weeks, so I'm not really gonna try to give you technical help.

    There are some tools you could try aside from the partion tool on the Live CD.

    You could search a torrent site for "HiRen bootcd". I think the latest version is 9.8. There are several tools on there you could try.

    Theres also GParted Live:
    http://gparted.sourceforge.net/livecd.php

    You could burn that or put it on a USB drive and see if anything pops up.

  3. #3
    Join Date
    Jul 2007
    Location
    Magic City of the Plains
    Beans
    Hidden!
    Distro
    Xubuntu 15.04 Vivid Vervet

    Re: HELP. Editing Partitions and Lost Everything

    Can you run this command while booted to the LiveCD, and paste the results here?
    Code:
    sudo fdisk -l

  4. #4
    Join Date
    May 2009
    Location
    Boston, MA
    Beans
    26
    Distro
    Ubuntu 13.10 Saucy Salamander

    Re: HELP. Editing Partitions and Lost Everything

    ubuntu@ubuntu:~$ sudo fdisk -l
    omitting empty partition (5)

    Disk /dev/sda: 500.1 GB, 500107862016 bytes
    255 heads, 63 sectors/track, 60801 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Disk identifier: 0x776b776b

    Device Boot Start End Blocks Id System
    /dev/sda1 * 1 42528 341606128+ 83 Linux
    /dev/sda2 42529 60801 146777872+ 5 Extended
    /dev/sda3 59478 60801 10634998+ 82 Linux swap / Solaris
    /dev/sda5 42530 46467 31631953+ 83 Linux
    /dev/sda6 46468 59477 104502793+ e W95 FAT16 (LBA)

    Disk /dev/sdb: 1000.2 GB, 1000204886016 bytes
    255 heads, 63 sectors/track, 121601 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Disk identifier: 0x44fdfe06

    Device Boot Start End Blocks Id System
    /dev/sdb1 1 121601 976760001 83 Linux
    ubuntu@ubuntu:~$

  5. #5
    Join Date
    Jun 2006
    Beans
    7,419
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: HELP. Editing Partitions and Lost Everything

    either the attempted resize or windows messed up the partition table

    omitting empty partition (5)
    doesn't look like sda1 shrank at all

    what does
    sudo sfdisk -d
    show?

  6. #6
    Join Date
    May 2009
    Location
    Boston, MA
    Beans
    26
    Distro
    Ubuntu 13.10 Saucy Salamander

    Re: HELP. Editing Partitions and Lost Everything

    It did shrink the partition though, at least at first. After changed the partitions around i was worried i messed something up because i've never changed the partitions so much while there was data on them before. But i restarted immediately after and everything worked fine, and the partitions were all the right sizes. It wasn't until i tried installing windows that this happened.


    ubuntu@ubuntu:~$ sudo sfdisk -d
    # partition table of /dev/sda
    unit: sectors

    /dev/sda1 : start= 63, size=683212257, Id=83, bootable
    /dev/sda2 : start=683212320, size=293555745, Id= 5
    /dev/sda3 : start=955498068, size= 21269997, Id=82
    /dev/sda4 : start= 0, size= 0, Id= 0
    /dev/sda5 : start=683228448, size= 63263907, Id=83
    /dev/sda6 : start=746492418, size=209005587, Id= e
    # partition table of /dev/sdb
    unit: sectors

    /dev/sdb1 : start= 63, size=1953520002, Id=83
    /dev/sdb2 : start= 0, size= 0, Id= 0
    /dev/sdb3 : start= 0, size= 0, Id= 0
    /dev/sdb4 : start= 0, size= 0, Id= 0

  7. #7
    Join Date
    Jun 2006
    Beans
    7,419
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: HELP. Editing Partitions and Lost Everything

    Try this:

    sudo sfdisk -d /dev/sda | sudo sfdisk --force /dev/sda
    to correct the partition table

    After you do that run
    sudo fdisk -l
    again and post output.

    Then maybe you can install windows

  8. #8
    Join Date
    May 2009
    Location
    Boston, MA
    Beans
    26
    Distro
    Ubuntu 13.10 Saucy Salamander

    Re: HELP. Editing Partitions and Lost Everything

    Here's the output:

    ubuntu@ubuntu:~$ sudo fdisk -l

    Disk /dev/sda: 500.1 GB, 500107862016 bytes
    255 heads, 63 sectors/track, 60801 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Disk identifier: 0x776b776b

    Device Boot Start End Blocks Id System
    /dev/sda1 * 1 42528 341606128+ 83 Linux
    /dev/sda2 42529 60801 146777872+ 5 Extended
    /dev/sda3 59478 60801 10634998+ 82 Linux swap / Solaris
    /dev/sda5 42530 46467 31631953+ 83 Linux
    /dev/sda6 46468 59477 104502793+ e W95 FAT16 (LBA)

    Disk /dev/sdb: 1000.2 GB, 1000204886016 bytes
    255 heads, 63 sectors/track, 121601 cylinders
    Units = cylinders of 16065 * 512 = 8225280 bytes
    Disk identifier: 0x44fdfe06

    Device Boot Start End Blocks Id System
    /dev/sdb1 1 121601 976760001 83 Linux
    ubuntu@ubuntu:~$

    I'm gonna try to restart and see if this worked. I'll let you know what happens.

  9. #9
    Join Date
    May 2009
    Location
    Boston, MA
    Beans
    26
    Distro
    Ubuntu 13.10 Saucy Salamander

    Re: HELP. Editing Partitions and Lost Everything

    If someone could help me just get the information from my home folder off the HD, i'll just do a clean install. I want to try to avoid losing all my settings if i can. I can't access my home folder from the live cd for some reason. I changed the permissions of it to allow me read/write acess but now instead of saying i don't have permissions it just shows the folder as being empty. Is there something else i have to do that i'm not doing?
    Last edited by danger pigeon; May 16th, 2009 at 06:15 PM.

  10. #10
    Join Date
    Jun 2006
    Beans
    7,419
    Distro
    Ubuntu 8.04 Hardy Heron

    Re: HELP. Editing Partitions and Lost Everything

    Well, at least that cleared the partition table of the 'empty' ones (I think).

    Does Gparted show the disk partitions now correctly?

    So, you still can't boot ubuntu install on sda1 and now you can't even see anything in /home from the live cd? You shouldn't have changed the permissions though--if you applied it recursively to the entire dir then you screwed things up and will definitely have to reinstall.

    Are you sure it's mounted and you're looking in the right place? Did you try mounting it manually?

    sudo mkdir /media/ubuntu

    sudo mount -t ext3 /dev/sda1 /media/ubuntu

    ls -l /media/ubuntu/home/<yourusername>

Page 1 of 2 12 LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •