Author Topic: <SOLVED>Installed new disk--500.1 GB getting FATAL ERROR Er, Old-Polack, ready?  (Read 1358 times)

Offline barryc

  • Sr. Member
  • ****
  • Posts: 321
Here is fdisk printout of my second disk and the cfdisk printout of the same.

[root@BigBee barry]# fdisk -l /dev/sdb

Disk /dev/sdb: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 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: 0x00000000

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1              63   976773167   488386552+  83  Linux
/dev/sdb2   *           0           0           0    0  Empty
/dev/sdb3   *           0           0           0    0  Empty
/dev/sdb4   *           0           0           0    0  Empty

[root@BigBee barry]# cfdisk -P s /dev/sdb
FATAL ERROR: Bad primary partition 0: Partition ends in the final partial cylinder

1. first, there is no * shown for sdb1 (I think this indicates if partition is bootable)
2. second, sdb2, sdb3 and sdb4 have not been configured or formatted.  Why are they listed?  The
disk has only one large partition and is being used for data only.
3. When running cfdisk -P s /dev/sdb I get the FATAL ERROR below:

FATAL ERROR: Bad primary partition 2: Partition ends in the final partial cylinder

Current fdisk program is v 2.1.8

What's the problem?  And, ahem, what's the solution?

O-P, you knew I'd be back.  :)
« Last Edit: June 05, 2012, 06:40:39 PM by barryc »
You gotta have balls to play golf.

Offline djohnston

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 6227
  • I don't do Windows
barryc,

If you have any data on that, back it up. Then read this procedure.

Bare metal                           VBox
AMD Athlon 7750 Dual-Core    Single core
4GiB RAM                              1GiB RAM
nVidia GeForce FX 5200          64MB video
LXDE 32bit                            KDE 64bit

Registered Linux User #416378

Offline Old-Polack

  • Administrator
  • Super Villain
  • *****
  • Posts: 11532
  • ----IOFLU----
Here is fdisk printout of my second disk and the cfdisk printout of the same.

[root@BigBee barry]# fdisk -l /dev/sdb

Disk /dev/sdb: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 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: 0x00000000

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1              63   976773167   488386552+  83  Linux
/dev/sdb2   *           0           0           0    0  Empty
/dev/sdb3   *           0           0           0    0  Empty
/dev/sdb4   *           0           0           0    0  Empty

[root@BigBee barry]# cfdisk -P s /dev/sdb
FATAL ERROR: Bad primary partition 0: Partition ends in the final partial cylinder

1. first, there is no * shown for sdb1 (I think this indicates if partition is bootable)
2. second, sdb2, sdb3 and sdb4 have not been configured or formatted.  Why are they listed?  The
disk has only one large partition and is being used for data only.
3. When running cfdisk -P s /dev/sdb I get the FATAL ERROR below:

FATAL ERROR: Bad primary partition 2: Partition ends in the final partial cylinder

Current fdisk program is v 2.1.8

What's the problem?  And, ahem, what's the solution?

O-P, you knew I'd be back.  :)


I don't know what application did the partitioning, but it obviously screwed up. Not having a boot flag is not a problem for Linux, and having a boot flag may be the cause of the problem with the nonexistent /dev/sdb2 - /dev/sdb4.

Something to try, and use caution with this, use fdisk /dev/sdb to open the drive for editing the partition table. From the menu, a   toggle a bootable flag, use the a command on each of the partitions, /dev/sdb2 - /dev/sdb4 then use the p command to get a printout of the partition table, as it then appears. The ghost partitions may, or may not, be deleted by this action.

The biggest problem with using the current fdisk version is that it cannot build a partition table starting at sector 63. Since the rewrite to enable partitioning drives larger than 2 TB, and the use of 4096 byte physical sectors, the default starting point for the first partition of any drive is sector 2048.

If you have an older PCLinuxOS liveCD with the older version of fdisk, (prior to the rewrite) you could use that with the o command, to create a new partition table, then use the n command to create just one partition starting at sector 63 and ending at sector 976773167. The w command would then write the corrected partition table to the hard drive MBR, without disturbing the data contained in the existing filesystem.

If you don't have an older version of fdisk, you would definitely need to back up any data on the drive before repartitioning with the current fdisk version, and formatting the new partition.

You could, with the new fdisk, try the d command to delete partitions 2 - 4, then use the p command to see what you would get if you used the w command. If it shows the one single partition you want, without any sign of the current ghost partitions, then enter the w command. If it shows anything undesirable, use the q command to quit fdisk without making any changes.
Old-Polack

Of what use be there for joy, if not for the sharing thereof?



Lest we forget...

Online DeBaas

  • Hero Member
  • *****
  • Posts: 1515
    • PCLinuxOS.nl
Worth a try ?
Same (kind of) problem.
Opened the disk with Gparted, marked the bootflag from sdb1 as boot, problems magically solved.

Offline barryc

  • Sr. Member
  • ****
  • Posts: 321
Quote
Worth a try ?
Same (kind of) problem.
Opened the disk with Gparted, marked the bootflag from sdb1 as boot, problems magically solved.

Yup.  That did it.  I tried it last night with kde partition editor and all seems normal now.  sb2, sb3 and sb4 magically disappeared.

I originally set up the disk with the pccontrol disk management tool.  Here's what I get with fdisk now:

[root@BigBee barry]# fdisk -l /dev/sdb

Disk /dev/sdb: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 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: 0x00035887


Device           Boot      Start         End           Blocks        Id   System
/dev/sdb1         *          63      976773167   488386552+  83   Linux


« Last Edit: June 05, 2012, 10:17:47 AM by barryc »
You gotta have balls to play golf.

Offline Old-Polack

  • Administrator
  • Super Villain
  • *****
  • Posts: 11532
  • ----IOFLU----
Quote
Worth a try ?
Same (kind of) problem.
Opened the disk with Gparted, marked the bootflag from sdb1 as boot, problems magically solved.

Yup.  That did it.  I tried it last night with kde partition editor and all seems normal now.  sb2, sb3 and sb4 magically disappeared.

I originally set up the disk with the pccontrol disk management tool.  Here's what I get with fdisk now:

[root@BigBee barry]# fdisk -l /dev/sdb

Disk /dev/sdb: 500.1 GB, 500107862016 bytes
255 heads, 63 sectors/track, 60801 cylinders, total 976773168 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: 0x00035887


Device           Boot      Start         End           Blocks        Id   System
/dev/sdb1         *          63      976773167   488386552+  83   Linux



Just FYI, Linux doesn't use the boot flag for anything; it's a Windows thing. From my computer;

[root@fatman ~]# fdisk -l
Code: [Select]
Disk /dev/sdb: 750.2 GB, 750156374016 bytes
255 heads, 63 sectors/track, 91201 cylinders, total 1465149168 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: 0x2db1883a

   Device Boot      Start         End      Blocks   Id  System
/dev/sdb1              63      208844      104391   83  Linux
/dev/sdb2          208845    12225464     6008310   82  Linux swap / Solaris
/dev/sdb3        12225465    72244304    30009420   83  Linux
/dev/sdb4        72244305  1465144064   696449880    5  Extended
/dev/sdb5        72244368   272253554   100004593+  83  Linux
/dev/sdb6       272253618   670713749   199230066   83  Linux
/dev/sdb7       670713813   731278799    30282493+  83  Linux
/dev/sdb8       731278863   811378889    40050013+  83  Linux
/dev/sdb9       811378953  1045767239   117194143+  83  Linux
/dev/sdb10     1045767303  1280155589   117194143+  83  Linux
/dev/sdb11     1280155653  1465144064    92494206   83  Linux

Disk /dev/sdc: 2000.4 GB, 2000398934016 bytes
255 heads, 63 sectors/track, 243201 cylinders, total 3907029168 sectors
Units = sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disk identifier: 0x18eee7ae

   Device Boot      Start         End      Blocks   Id  System
/dev/sdc1            2048     2099199     1048576   83  Linux
/dev/sdc2         2099200    18876415     8388608   82  Linux swap / Solaris
/dev/sdc3        18876416    81790975    31457280   83  Linux
/dev/sdc4        81790976  3907029167  1912619096    5  Extended
/dev/sdc5        81793024   176164863    47185920   83  Linux
/dev/sdc6       176166912   281024511    52428800   83  Linux
/dev/sdc7       281026560   385884159    52428800   83  Linux
/dev/sdc8       385886208   805316607   209715200   83  Linux
/dev/sdc9       805318656   857747455    26214400   83  Linux
/dev/sdc10      857749504   910178303    26214400   83  Linux

Disk /dev/sda: 1000.2 GB, 1000204886016 bytes
255 heads, 63 sectors/track, 121601 cylinders, total 1953525168 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: 0x0000d21c

   Device Boot      Start         End      Blocks   Id  System
/dev/sda1              63      626534      313236   83  Linux
/dev/sda2          626535    16820054     8096760   82  Linux swap / Solaris
/dev/sda3        16820055   114495254    48837600   83  Linux
/dev/sda4       114495255  1953520064   919512405    5  Extended
/dev/sda5       114495318   329332499   107418591   83  Linux
/dev/sda6       329332563   534434354   102550896   83  Linux
/dev/sda7       534434418   596943269    31254426   83  Linux
/dev/sda8       596943333   659452184    31254426   83  Linux
/dev/sda9       659452248   721961099    31254426   83  Linux
/dev/sda10      721961163   784470014    31254426   83  Linux
/dev/sda11      784470078   994198589   104864256   83  Linux
/dev/sda12      994198653  1623368249   314584798+  83  Linux
/dev/sda13     1623368313  1685893229    31262458+  83  Linux
/dev/sda14     1685893293  1749366044    31736376   83  Linux
/dev/sda15     1749366108  1816485614    33559753+  83  Linux
/dev/sda16     1816487663  1889887982    36700160   83  Linux
/dev/sda17     1889892080  1953520064    31813992+  83  Linux

Note the complete absence of any boot flags on any of my drives. From grub, one can determine the partitions from which my various installations boot.

[root@fatman ~]# grub
Code: [Select]
Probing devices to guess BIOS drives. This may take a long time.


    GNU GRUB  version 0.97  (640K lower / 3072K upper memory)

 [ Minimal BASH-like line editing is supported.  For the first word, TAB
   lists possible command completions.  Anywhere else TAB lists the possible
   completions of a device/filename. ]
grub> find /boot/grub/stage2
find /boot/grub/stage2
 (hd0,0)
 (hd0,6)
 (hd0,7)
 (hd0,8)
 (hd0,12)
 (hd0,13)
 (hd0,14)
 (hd0,16)
 (hd1,0)
 (hd1,7)
 (hd2,0)
 (hd2,2)
 (hd2,4)
 (hd2,5)
 (hd2,6)
 (hd2,8)
 (hd2,9)
grub>

It doesn't hurt anything having the boot flag where it is, on your drive, but it also serves no function either.
Old-Polack

Of what use be there for joy, if not for the sharing thereof?



Lest we forget...

Offline barryc

  • Sr. Member
  • ****
  • Posts: 321
Quote from Old-Polack
Quote
It doesn't hurt anything having the boot flag where it is, on your drive, but it also serves no function either.

True.  Just wondering why, when I added the boot label to sdb1 and wrote it , the other (sdb2-sdb4) partitions disappeared.  This
was done using (kde) partitionmanager.
« Last Edit: June 06, 2012, 10:55:59 AM by barryc »
You gotta have balls to play golf.

Offline Old-Polack

  • Administrator
  • Super Villain
  • *****
  • Posts: 11532
  • ----IOFLU----
Quote from Old-Polack
Quote
It doesn't hurt anything having the boot flag where it is, on your drive, but it also serves no function either.

True.  Just wondering why, when I added the boot label to sdb1 and wrote it , the other (sdb2-sdb4) partitions disappeared.  This
was done using (kde) partitionmanager.

Undoubtedly, recognizing that only one boot flag should be allowed, it removed the others, which were the only things allowing the ghost partitions to be shown in the first place. My concern would be more about which application set boot flags to partitions that do not exist.  ???
Old-Polack

Of what use be there for joy, if not for the sharing thereof?



Lest we forget...

Offline Wildman

  • PCLinuxOS Tester
  • Hero Member
  • *******
  • Posts: 7548
  • Symphony for a Unstrung Tongue
Quote from Old-Polack
Quote
It doesn't hurt anything having the boot flag where it is, on your drive, but it also serves no function either.

True.  Just wondering why, when I added the boot label to sdb1 and wrote it , the other (sdb2-sdb4) partitions disappeared.  This
was done using (kde) partitionmanager.

Undoubtedly, recognizing that only one boot flag should be allowed, it removed the others, which were the only things allowing the ghost partitions to be shown in the first place. My concern would be more about which application set boot flags to partitions that do not exist???

fwiw,, the only times I have seen anything close to this problem, was when installing over a previous installation, or installing without formatting first.  Helpful maybe  ???
Happiness is not having what you want, but wanting what you have!

Joe Gable, "Joble" Was my Friend..
Dave "Exwintech" has also gone on...
Linux Counter #288984

Offline barryc

  • Sr. Member
  • ****
  • Posts: 321
O-P

Originally partitioned new disk with the pccontrol disk utility.
You gotta have balls to play golf.

Online DeBaas

  • Hero Member
  • *****
  • Posts: 1515
    • PCLinuxOS.nl
With PCC HDD management it's also possible to create more than 4 primairy partitions.
When you throw this disk to the M$ diskmanagement it's going highwire.
Evenso Gparted is not happy with this disk.
« Last Edit: June 06, 2012, 02:43:38 PM by DeBaas »

Offline Old-Polack

  • Administrator
  • Super Villain
  • *****
  • Posts: 11532
  • ----IOFLU----
O-P

Originally partitioned new disk with the pccontrol disk utility.

I've done that many times, and have never seen such behavior. There has to have been more to it than that. Either you did something unusual, or the image download, or burn, was less than bit perfect.

For what it's worth, I dislike any tool that tries to do too many lobs, all at the same time. For the most part, I use Linux fdisk to create my partitions, mkfs -t <filesystem-type> -L <label> /dev/<whatever> to format the regular partitions, and mkswap -L <label> /dev/<whatever> to format the swap partition, prior to doing the actual installation.
Old-Polack

Of what use be there for joy, if not for the sharing thereof?



Lest we forget...

Offline Old-Polack

  • Administrator
  • Super Villain
  • *****
  • Posts: 11532
  • ----IOFLU----
With PCC HDD management it's also possible to create more than 4 primairy disks.
When you throw this disk to the M$ diskmanagement it's going highwire.
Evenso Gparted is not happy with this disk.

How, exactly, would that be done? The DOS partition table only allows four, including one used as an extended partition. There is no place in the MBR to register a fifth primary partition. ???
Old-Polack

Of what use be there for joy, if not for the sharing thereof?



Lest we forget...

Offline barryc

  • Sr. Member
  • ****
  • Posts: 321
O-P

Originally partitioned new disk with the pccontrol disk utility.

I've done that many times, and have never seen such behavior. There has to have been more to it than that. Either you did something unusual, or the image download, or burn, was less than bit perfect.

For what it's worth, I dislike any tool that tries to do too many lobs, all at the same time. For the most part, I use Linux fdisk to create my partitions, mkfs -t <filesystem-type> -L <label> /dev/<whatever> to format the regular partitions, and mkswap -L <label> /dev/<whatever> to format the swap partition, prior to doing the actual installation.

O-P
I remember when partitioning the new disk, In one of the pulldowns, I did not check the boot flag entry.  Once the disk was formatted
the original result (no boot flag on sdb1) and 3 additional ghost partitions with boot flags.  Is this a bug in the pcc disk utility or am I the bug causing the problem? ??? ???
You gotta have balls to play golf.

Online DeBaas

  • Hero Member
  • *****
  • Posts: 1515
    • PCLinuxOS.nl
The greatest software problem is always between chair and keyboard ;)