I just recently removed two Linux operating systems (mint and ubuntu) from my computer, which also contains a windows vista installation. I removed both with the "OSremover" found on boot-repair-disk's live image.

Before removing Ubuntu I forgot that I had encrypted the home directory. The removal worked just fine, and now I can boot into windows as usual.

However, now that I'm trying to install a new Linux OS, I can see that gparted doesn't recognize any partitions on my disk and it says that all of the space there is unallocated. I checked with the disk management service on windows and it can see all my partitions just fine, even the ones I previously used for the two Linux installations (which I've deleted and merged with my windows partition).

I have no idea what's going on, I've tried fixing the mbr with bootrec /fixmbr but that didn't do anything. Also, running fdisk -l from a live image of elementary-os lists my partitions as they should be.

I'm adding outputs from the from the sudo fdisk -l /dev/sda and /sudo parted /dev/sda print commands as per Rod Smith's suggestion. First, fdisk:

Disk /dev/sda: 250.1 GB, 250059350016 bytes
255 heads, 63 sectors/track, 30401 cylinders, total 488397168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disk identifier: 0xcab10bee

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1   *          63   484458486   242229212    7  HPFS/NTFS/exFAT
/dev/sda2       484472205   488408129     1967962+   f  W95 Ext'd (LBA)
/dev/sda5       486434816   488396783      980984   82  Linux swap / Solaris

Now, parted:

Error: Can't have a partition outside the disk!           

Hope this helps.


Ran fixparts and it automatically fixed the error on execution, just had to save the new table with the w command.


Received the following message:

Warning: 0xEE partition doesn't start on sector 1. This can cause problems
in some OSes.
  • 2
    Gparted fails if NTFS has issues. If chkdsk flag or hibernation flag is set then it will not work. And if you resized NTFS from outside Windows or have not rebooted then the NTFS partition(s) need chkdsk. Make sure hibernation is off.
    – oldfred
    Commented Mar 25, 2015 at 4:14
  • @oldfred I tried using powercfg.exe /hibernate off but it looks like it's already been disabled. Commented Mar 27, 2015 at 22:47
  • 3
    Testdisk has been known to do this due to bad rounding. Your extended partition ends after the end of the drive or 488408129 which is greater than drive's 488397168 sectors. First backup current partition table. sudo sfdisk -d /dev/sda > parts_sda.txt and save to another device. I think Rod's suggestion of fixparts may work or just using fdisk and writing table. Since it is "only" the extended partition your data should be ok, but good backups always required.
    – oldfred
    Commented Mar 28, 2015 at 3:49
  • I don't think fdisk will automatically resize the extended partition -- at least, it didn't the last time I looked at this. It could be fixed with fdisk, but you'd need to delete both the logical and extended partitions and then re-create them, which is a little dangerous. FixParts will do this much more simply, with less room for user error.
    – Rod Smith
    Commented Mar 28, 2015 at 17:12

2 Answers 2


Chances are your partition table is damaged, or possibly just a little bit odd. GParted tends to show disks with such partition tables as being completely empty (with no partitions), which is unhelpful.

The solution is to fix the partition table. Unfortunately, it's unclear from your post exactly what's wrong with the partition table. Posting the output of sudo fdisk -l /dev/sda and of sudo parted /dev/sda print might give some clues about what's wrong.

You could also try running my FixParts on the disk, although it's probably better to try to figure out what's wrong first. FixParts can fix a number of common problems, but if used inappropriately it could conceivably cause more damage -- hence my recommendation to post your partition data here first. (You can add this information by editing your post. Be sure to add four spaces to the start of each line of program output; this is a flag to the forum software to preserve the formatting.) Please add a comment to this answer if you add this information; that way I'll notice and check back.

EDIT: Your problem is that your disk is 488,397,168 sectors long, but your extended partition extends out to sector 488,408,129. Fortunately, the logical partition within the extended partition is of legal size. This is one of the problems that FixParts can fix, so try using it. Be sure to read its documentation first. The solution is fairly simple, but you have to know at least the basics of how to use the program; it won't guide you by the hand through the process.

  • Hi Rod, thank you for the suggestions. I've added the outputs to my post now. Commented Mar 27, 2015 at 22:49
  • Please see my edit.
    – Rod Smith
    Commented Mar 28, 2015 at 17:10
  • Your program worked! It did the job and now I can see my partitions in Gparted. Although now I see an extra unallocated partition in Gparted which doesn't show up with fdisk and maybe even Windows (not sure though), and I also received the "Warning: 0xEE partition doesn't start on sector 1. This can cause problems in some OSes." message. But otherwise, everything seems to be in order. Thanks! Commented Mar 28, 2015 at 21:11
  • 1
    There's no such thing as an "unallocated partition;" by definition, a partition is allocated disk space. Unfortunately, some GUIs make unallocated disk space look like partitions, so a lot of people get confused by this. There were gaps even in the partition table you showed, so seeing unallocated space is not surprising. The message about the 0xEE partition is a bug in GPT fdisk (and therefore FixParts) version 0.8.8. Ubuntu 15.04 (currently in beta) ships with 0.8.10, and 1.0.0 (or possibly something later) will be in 15.10. Both versions fix that bug.
    – Rod Smith
    Commented Mar 28, 2015 at 23:00

Gparted is unable to read the partition table of your HDD. Take a back-up of your HDD, then boot to Live Image, open the Gparted,and go to Device > Create partition table.


Note that the by creating/recreating the partition table you'll lose all your data on the Hard Disk. So make a Backup first. Do it on your own risk.


  • This is what I'm avoiding. I'm hoping there might be another way to recover the partition table, maybe with parted but i'm not sure how to work with that. Commented Mar 25, 2015 at 3:46
  • 2
    This advice will destroy the partition table! Since that disk contains a working Windows installation, which ThisIsNotAnId presumably wants to keep, destroying the partition table is the last thing to recommend!
    – Rod Smith
    Commented Mar 27, 2015 at 1:11

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .