PDA

View Full Version : [ubuntu] 9.10 Partition problem during install?



Steve'O
March 26th, 2010, 09:26 PM
I am trying to install Ubuntu 9.10 x64 onto a new drive with Windows 7 x

64 on it. Here is a shot of my partition under Win 7:

http://i117.photobucket.com/albums/o75/SteveO-photo/ubuntu/Untitled.png

When I try to install 9.10 and get to the partition screen I have the following problem. It does not show the accurate partitions. The bars are solid with no slider. When I try to use largest space option, it says space is too small. The partitions are incorrectly displayed all together when you try to do it manual as well.

Any ideas?

Steve'O
March 26th, 2010, 11:00 PM
Anyone have any idea?

stlsaint
March 27th, 2010, 02:32 AM
Try going into System>Admin>partition editor at the livecd to double check there if you can see correct partitions. Also what partitions are being displayed under the manual option at the install.

Steve'O
March 27th, 2010, 04:29 AM
Yes, I tried going into the partition editor through the live CD and got the same result. Here is what was shown in the Ubuntu partition:

free space 0 MB

/dev/sda1 fat32 209 MB 209 MB

free space 1 MB

/dev/sda2 2498489 MB unknown

free space 0 MB

I had 9.10 running no problem on a 32 bit vista system. Is this a 64 bit issue?

Steve'O
March 27th, 2010, 04:48 PM
Anyone have any ideas?

oldfred
March 27th, 2010, 06:16 PM
If the partition has flags set because it will want to run chkdsk or is in hibernation Ubuntu and I think gparted will not mount it. Did you hibernate or when you boot windows does it want to run chkdsk or is it clean?

srs5694
March 27th, 2010, 06:17 PM
Boot a Linux emergency disc or Live CD, open a shell, and type the following (you may need to add "sudo" to the start of the line):



fdisk -l


Post the results. This will tell us what's really on your disk, with some precision.

It sounds like libparted (upon which most Linux partitioning tools are based) may be getting confused. There are a lot of posts about this here. You may be able to work around it by using fdisk instead of libparted-based tools to create your Linux partitions, but I can't promise this will work, since I don't fully understand what's causing these problems or how much the Ubuntu installer relies on data from libparted.

Steve'O
March 27th, 2010, 06:46 PM
ubuntu@ubuntu:~$ sudo fdisk -1
fdisk: invalid option -- '1'

Usage: fdisk [-b SSZ] [-u] DISK Change partition table
fdisk -l [-b SSZ] [-u] DISK List partition table(s)
fdisk -s PARTITION Give partition size(s) in blocks
fdisk -v Give fdisk version
Here DISK is something like /dev/hdb or /dev/sda
and PARTITION is something like /dev/hda7
-u: give Start and End in sector (instead of cylinder) units
-b 2048: (for certain MO disks) use 2048-byte sectors
ubuntu@ubuntu:~$
http://i117.photobucket.com/albums/o75/SteveO-photo/Screenshot.png

oldfred
March 27th, 2010, 07:27 PM
The fine print says you have a gpt partition which is the newer partition version used by apple and windows servers. Many tools are still based on MBR partitions but have updates to make sure they do not destroy GPT partitions. Linux works with GPT but you have to use updated tools.

GPT fdisk Tutorial -srs5694 in forums
http://www.rodsbooks.com/gdisk/
The emergency disks I know of that include GPT fdisk are:
* SystemRescueCd
* PartedMagic

http://www.cyberciti.biz/tips/fdisk-unable-to-create-partition-greater-2tb.html
http://www.ibm.com/developerworks/linux/library/l-gpt/
http://en.wikipedia.org/wiki/GUID_Partition_Table
MBR details including 2TiB limit and GPT link
http://en.wikipedia.org/wiki/Master_boot_record

I ddi not notice that srs5694 was posting in this thread, he knows a whole lot more than me on GPT.

Steve'O
March 28th, 2010, 04:50 AM
OK, I have been looking at numerous threads about GPT disk partitions and I do not see a straight forward process for installing Ubuntu. Does anyone have experience installing Ubuntu on a Windows 7 system with this partition situation?

srs5694
March 28th, 2010, 05:30 AM
First, a semi-moot point: The command I specified was "fdisk -l" with a lowercase "L", not a digit "1".

Now to the real issue: I suspect, but am not sure, that you've got either a hybrid MBR (http://www.rodsbooks.com/gdisk/hybrid.html) with mis-matched GPT and MBR partition tables or a disk that was originally partitioned for GPT and then re-partitioned for MBR with a GPT-unaware utility. Either condition is a minefield, so you should proceed with caution. You say that this is a new disk. Do you mean brand-new out of the box? If so, does it look like it might have been restocked? I'm just wondering how these inconsistent partition tables could have gotten onto the disk, and if it had been partitioned for GPT, returned, restocked, and sold to you, that's one possibility. Another is if you didn't mean "brand-new" when you wrote "new," but in fact the disk had been used in another computer (maybe a Mac, which uses GPT).

Anyhow, to get on with fixing the problem, you should first download either PartedMagic (http://partedmagic.com/) or System Rescue Cd (http://www.sysresccd.org/Main_Page), boot it, and get to a text-mode console (a text-mode login or a Terminal-type program in GUI mode). Type the following commands and post the results (cut-and-paste to a text file on a USB flash drive or the like, or take a photo with a digital camera if necessary):



Type "gdisk -l /dev/sda". Note that's "gdisk", not "fdisk", and a lowercase "L", not a digit "1". Also, your disk might be /dev/hda, not /dev/sda, with one of those emergency disks. The program may display notices about conversions or inconsistencies. Be sure to include the four lines following the text "Partition table scan:" in what you post.
Type "fdisk -lu /dev/sda". Again, that's a lowercase "L", and your disk device might be different. Note that I'm including a "u" after the "l", too.



These two commands display the GPT and MBR partition tables, respectively. You can compare the two partition tables yourself. If the MBR table consists of a single partition of type 0xEE that spans the whole disk, then my suspicions are all wrong and you've got a conventional GPT disk. If you've got a smaller 0xEE MBR partition along with one to three others, then it's a hybrid MBR (MBR+GPT) disk. If there's no 0xEE partition at all, then it's an MBR disk, although there could be leftover GPT data causing problems -- the gdisk partition scan should reveal that. Pay attention to the MBR and GPT partition start points. The 0xEE MBR protective partition won't match, but if other partitions don't match, then that means trouble.

What you do from here depends on precisely what you find in terms of MBR and GPT data structures, but there is one other factor: How is Windows treating the disk? Does your computer have a conventional BIOS, or is it one of the few EFI-based PCs? Windows can only boot from MBR disks on BIOS-based computers. This and the fact that the Windows screenshot you posted shows different partitions than the GParted screenshot (which identifies the partitions as GPT) makes me think that Windows is seeing the MBR side and that the GPT side is out of date.

The gdisk and/or fdisk programs can correct mis-matched GPT and MBR data structures, but to provide further advice I need to know the details of what's actually on the disk. If the GPT data is leftover fragments, gdisk can erase it and fdisk can remove any unnecessary 0xEE partition. If the GPT data should have primacy, gdisk can construct a new conventional protective MBR or a matching hybrid MBR.

Also, DO NOT USE GPARTED ON THIS DISK!!!!!!!! GParted, or at least some versions of it, has a tendency to overwrite MBR data on hybrid MBR disks, so if my suspicions are correct, every time you run GParted on this disk is a chance for you to completely hose your Windows installation.

Steve'O
March 28th, 2010, 05:50 AM
Thanks for the reply. Oddly enough, the disk I am using was bought as clearance at Micro Center. So, it may have been returned. Big question mark there. Would I have better luck if i got a for sure brand new disk? Or is this a fairly simple fix once we know what we are looking at. I will run the disk again and do what you asked and repost later. I can always wipe this disk and start from scratch with fresh windows install. This a MSI GT725-75 laptop. I changed out the original disk with Vista 32bit and installed the new disk with 7 x64. I had my Vista disk dual boot with 9.10 with no problems.

srs5694
March 28th, 2010, 06:36 AM
The fix is fairly simple once the diagnosis is complete, at least if either of my leading two hypotheses is correct.

Steve'O
March 28th, 2010, 03:49 PM
Ok, here is the info:

root@PartedMagic:~# gdisk -l /dev/sda
GPT fdisk (gdisk) version 0.6.4

Partition table scan:
MBR: MBR only
BSD: not present
APM: not present
GPT: present

Found valid MBR and GPT. Which do you want to use?
1 - MBR
2 - GPT
3 - Create blank GPT

root@PartedMagic:~# gdisk -l /dev/hda
GPT fdisk (gdisk) version 0.6.4

Problem reading disk in MBRData::ReadMBRData()!
Warning! Read error 25; strange behavior now likely!
Warning! Read error 25; strange behavior now likely!
Partition table scan:
MBR: not present
BSD: not present
APM: not present
GPT: not present

Creating new GPT entries.
Disk /dev/hda: 0 sectors, 0 bytes
Logical sector size: 512 bytes
Disk identifier (GUID): 739833F2-3AE2-47A4-B61D-EBF0A6E898B0
Partition table holds up to 128 entries
First usable sector is 34, last usable sector is 18446744073709551582
Total free space is 18446744073709551549 sectors (16384.0 PiB)

Number Start (sector) End (sector) Size Code Name

root@PartedMagic:~# fdisk -lu /dev/sda

WARNING: GPT (GUID Partition Table) detected on '/dev/sda'! The util fdisk doesn't support GPT. Use GNU Parted.


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: 0x0c465ca5

Device Boot Start End Blocks Id System
/dev/sda1 * 2048 206847 102400 7 HPFS/NTFS
Partition 1 does not end on cylinder boundary.
/dev/sda2 206848 163842047 81817600 7 HPFS/NTFS
/dev/sda3 163842048 424904703 130531328 7 HPFS/NTFS

srs5694
March 28th, 2010, 05:01 PM
OK, then, it looks like you've got a new MBR with residual GPT data, which is confusing GParted. You'll have to wipe the GPT data. Here's how:



Boot your PartedMagic or System Rescue CD emergency disc.
For safety, back up your MBR by typing "dd if=/dev/sda of=sda-backup.mbr bs=512 count=1" and then copying the resulting file (sda-backup.mbr) to a USB flash drive, network share, or some other medium. Be sure to get the if= and of= parameters right, though!
Launch gdisk by typing "gdisk /dev/sda". When asked whether to use the MBR or GPT data, either will work.
Type "x" to enter the experts' menu. The command prompt should change.
Type "z" to "zap" (destroy) the GPT data. Tell it to proceed, but answer "N" to the question about blanking the MBR.



That's it. Windows should boot as it did before and you should now be able to continue your installation of Ubuntu; its installer should now see the same partitions as Windows.

Steve'O
March 30th, 2010, 02:55 AM
This worked! Thanks! Now, I am just trying to get 64 bit flash installed and not enjoying it so far, LOL!

QIII
February 24th, 2013, 01:02 AM
Thank you for sharing. Everyone’s questions and answers are valuable.

If a thread has had no activity for about a year or more, it is best to start a new thread of your own. Not only will you be more likely to get a response, but things change so quickly in the software world that an old thread may cause you more trouble than it will help due to outdated information.

Please feel free to add a link to this thread in the new one you start.

Best wishes!

Thread closed.