Invalid partition table

1,485 views
Skip to first unread message

chandan bhagwat

unread,
Nov 4, 2015, 6:48:54 AM11/4/15
to Chromium OS dev
I built the chromium for x85-generic board and put the image on a sandisk cruzerblade (16GB) as in here . After selecting USB from BIOS options, its says "Invalid partition table". 
I even tried "sudo cgpt repair /dev/sdb" , but it does not seem to have an effect on this. Can anybody tell me what I'm doing wrong?
I'm using a machine with core i3-3220 processor with 3GB memory. 

Mike Frysinger

unread,
Nov 4, 2015, 11:34:15 AM11/4/15
to chromium-os-dev

we produce images that use the gpt format. make sure your bios supports that.
-mike

--
--
Chromium OS Developers mailing list: chromiu...@chromium.org
View archives, change email options, or unsubscribe:
http://groups.google.com/a/chromium.org/group/chromium-os-dev?hl=en

Message has been deleted

chandan bhagwat

unread,
Nov 5, 2015, 4:21:08 AM11/5/15
to Chromium OS dev

BIOS supports UEFI boot,

I tried several times, but now
If I select USB from boot menu, screen goes blank,
If I select UEFI USB, it gives out option to select like Local Image A , Local Image B etc , picture below 


After select any of them, I get this 











I noticed "WARNING: Primary GPT header is invalid, WARNING: Secondary GPT header is invalid" on "./build_image --board=${BOARD} --noenable_rootfs_verification --enable_serial tty1 dev" command.
detailed log below

ChromeOS version information:
    CHROME_BRANCH=48
    CHROME_VERSION=
    CHROMEOS_VERSION_STRING=7612.0.2015_11_05_1255
    CHROME_BASE=
INFO    : The following images will be built  chromiumos_image.bin.
INFO    : Clearing shadow utils lockfiles under /build/x86-generic
 * Building file list for packages cleaning...
 * Your packages directory was already clean.
INFO    : Verifying that the base image does not contain a blacklisted package.
INFO    : Generating list of packages for virtual/target-os.
INFO    : No blacklisted packages found.
INFO    : Using image type usb
INFO    : Using disk layout /mnt/host/source/src/scripts/build_library/legacy_disk_layout.json
1+0 records in
1+0 records out
512 bytes (512 B) copied, 0.000100459 s, 5.1 MB/s
WARNING: Primary GPT header is invalid
WARNING: Secondary GPT header is invalid

DBE267BD-7254-AF44-B5E3-5AE17019369C
       start        size    part  contents
           0           1          PMBR (Boot GUID: DBE267BD-7254-AF44-B5E3-5AE17019369C)
           1           1          Pri GPT header
           2          32          Pri GPT table
     2928640     2490368       1  Label: "STATE"
                                  Type: Linux data
                                  UUID: 673DCDE8-12DC-D34E-8ACC-E1174F1D0EC5
       20480       32768       2  Label: "KERN-A"
                                  Type: ChromeOS kernel
                                  UUID: 4528C4D5-EDAF-8041-A9BB-D186E7DF812D
                                  Attr: priority=15 tries=15 successful=0
      286720     2641920       3  Label: "ROOT-A"
                                  Type: ChromeOS rootfs
                                  UUID: 88146C1E-C19E-2344-B23B-D1653123EBD8
       53248       32768       4  Label: "KERN-B"
                                  Type: ChromeOS kernel
                                  UUID: DCD9D658-0C3F-2947-BD4D-CEF124925EE0
                                  Attr: priority=0 tries=0 successful=0
      282624        4096       5  Label: "ROOT-B"
                                  Type: ChromeOS rootfs
                                  UUID: 7C962606-AB65-584F-83E7-E83B7724EAAC
       16448           1       6  Label: "KERN-C"
                                  Type: ChromeOS kernel
                                  UUID: 980645E1-206B-7945-AD31-F63133F0BD0B
                                  Attr: priority=0 tries=0 successful=0
       16449           1       7  Label: "ROOT-C"
                                  Type: ChromeOS rootfs
                                  UUID: 37688F4E-5714-A54A-8DDC-C1AE28E21BA7
       86016       32768       8  Label: "OEM"
                                  Type: Linux data
                                  UUID: E216B90A-7FB9-DB4A-BCF3-789F5A94EFC6
       16450           1       9  Label: "reserved"
                                  Type: ChromeOS reserved
                                  UUID: 74522FE9-FEF0-8040-8EDB-FF94E9F0FBC5
       16451           1      10  Label: "reserved"
                                  Type: ChromeOS reserved
                                  UUID: 209CBA00-80BD-B448-9003-D852AD4E84E1
          64       16384      11  Label: "RWFW"
                                  Type: ChromeOS firmware
                                  UUID: 990E6688-6CBA-484C-8612-46ED60FF41EE
      249856       32768      12  Label: "EFI-SYSTEM"
                                  Type: EFI System Partition
                                  UUID: DBE267BD-7254-AF44-B5E3-5AE17019369C
     5451679          32          Sec GPT table
     5451711           1          Sec GPT header

INFO    : Creating FS for partition 8 with format ext4.
tune2fs 1.42.12 (29-Aug-2014)
Setting maximal mount count to -1
Setting error behavior to 2
Setting interval between checks to 0 seconds
Setting reserved blocks percentage to 0% (0 blocks)
Setting reserved blocks count to 0
Setting time filesystem last checked to Thu Nov 19 11:00:00 2009

INFO    : Creating FS for partition 12 with format vfat.
mkfs.fat 3.0.26 (2014-03-07)
Loop device does not match a floppy size, using default hd params
INFO    : Creating FS for partition 3 with format ext2.
tune2fs 1.42.12 (29-Aug-2014)
Setting maximal mount count to -1
Setting error behavior to 2
Setting interval between checks to 0 seconds
Setting reserved blocks percentage to 0% (0 blocks)
Setting reserved blocks count to 0
Setting time filesystem last checked to Thu Nov 19 11:00:00 2009

INFO    : Creating FS for partition 1 with format ext4.
tune2fs 1.42.12 (29-Aug-2014)
Setting maximal mount count to -1
Setting error behavior to 2
Setting interval between checks to 0 seconds
Setting reserved blocks percentage to 0% (0 blocks)
Setting reserved blocks count to 0
Setting time filesystem last checked to Thu Nov 19 11:00:00 2009


Is this creating any error?

chandan bhagwat

unread,
Nov 5, 2015, 4:30:17 AM11/5/15
to Chromium OS dev
"dmesg | tail"  gave this

[ 9035.592664] sd 9:0:0:0: [sdb] Write Protect is off
[ 9035.592667] sd 9:0:0:0: [sdb] Mode Sense: 43 00 00 00
[ 9035.592933] sd 9:0:0:0: [sdb] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[ 9035.615595] GPT:Primary header thinks Alt. header is not at the end of the disk.
[ 9035.615602] GPT:5451711 != 30529535
[ 9035.615605] GPT:Alternate GPT header not at the end of the disk.
[ 9035.615607] GPT:5451711 != 30529535
[ 9035.615609] GPT: Use GNU Parted to correct GPT errors.
[ 9035.615638]  sdb: sdb1 sdb2 sdb3 sdb4 sdb5 sdb6 sdb7 sdb8 sdb9 sdb10 sdb11 sdb12
[ 9035.618677] sd 9:0:0:0: [sdb] Attached SCSI removable disk


Then I tried GNU parted,

(parted) select /dev/sdb
Using /dev/sdb
(parted) print all                                                       
Error: The backup GPT table is not at the end of the disk, as it should be.  This might mean that another operating system believes the disk is smaller.  Fix, by moving the backup to the end (and removing the old backup)?
parted: invalid token: all
Fix/Ignore/Cancel? Fix                                                   
Warning: Not all of the space available to /dev/sdb appears to be used, you can fix the GPT to use all of the space (an extra 25077824 blocks) or continue with the current setting?
Fix/Ignore? Fix                                                          
Model: SanDisk Cruzer Blade (scsi)
Disk /dev/sdb: 15.6GB
Sector size (logical/physical): 512B/512B
Partition Table: gpt

Number  Start   End     Size    File system  Name        Flags
11      32.8kB  8421kB  8389kB               RWFW
 6      8421kB  8422kB  512B                 KERN-C
 7      8422kB  8422kB  512B                 ROOT-C
 9      8422kB  8423kB  512B                 reserved
10      8423kB  8423kB  512B                 reserved
 2      10.5MB  27.3MB  16.8MB               KERN-A
 4      27.3MB  44.0MB  16.8MB               KERN-B
 8      44.0MB  60.8MB  16.8MB  ext4         OEM         msftdata
12      128MB   145MB   16.8MB  fat16        EFI-SYSTEM  boot
 5      145MB   147MB   2097kB               ROOT-B
 3      147MB   1499MB  1353MB  ext2         ROOT-A
 1      1499MB  2775MB  1275MB  ext4         STATE       msftdata

still no luck.

Mike Frysinger

unread,
Nov 5, 2015, 11:10:01 AM11/5/15
to chandan bhagwat, chromium-os-dev

then the partition table is fine and you just need to select the right boot option in your bios.

as for the screen going blank, this is where you get to debug why it's not working ;). I'd guess missing drivers as that's the biggest reason with commodity hardware.
-mike

Gwendal Grignou

unread,
Nov 5, 2015, 12:37:39 PM11/5/15
to chandan bhagwat, Chromium OS dev
On Thu, Nov 5, 2015 at 1:30 AM, chandan bhagwat <srs.c...@gmail.com> wrote:
"dmesg | tail"  gave this

[ 9035.592664] sd 9:0:0:0: [sdb] Write Protect is off
[ 9035.592667] sd 9:0:0:0: [sdb] Mode Sense: 43 00 00 00
[ 9035.592933] sd 9:0:0:0: [sdb] Write cache: disabled, read cache: enabled, doesn't support DPO or FUA
[ 9035.615595] GPT:Primary header thinks Alt. header is not at the end of the disk.
[ 9035.615602] GPT:5451711 != 30529535
[ 9035.615605] GPT:Alternate GPT header not at the end of the disk.
[ 9035.615607] GPT:5451711 != 30529535
[ 9035.615609] GPT: Use GNU Parted to correct GPT errors.
[ 9035.615638]  sdb: sdb1 sdb2 sdb3 sdb4 sdb5 sdb6 sdb7 sdb8 sdb9 sdb10 sdb11 sdb12
[ 9035.618677] sd 9:0:0:0: [sdb] Attached SCSI removable disk


Then I tried GNU parted,

(parted) select /dev/sdb
Using /dev/sdb
(parted) print all                                                       
Error: The backup GPT table is not at the end of the disk, as it should be.  This might mean that another operating system believes the disk is smaller.  Fix, by moving the backup to the end (and removing the old backup)?
parted: invalid token: all
Fix/Ignore/Cancel? Fix                                                   
Warning: Not all of the space available to /dev/sdb appears to be used, you can fix the GPT to use all of the space (an extra 25077824 blocks) or continue with the current setting?

On USB images, it is expected the GPT table will not describe the full USB stick,but just what is needed. As a consequence, the backup GPT table will not be at the end of the USB stick.
Only when we install chromeos on a fixed drive the stateful partition (#1) will expand to use all the remaining space left in the drive.

I assume the dmesg output is from your local machine. The GPT messages are expected.

As Mike, said, using the BIOS UEFI USB option, you were able to select a kernel but you crashed soon after. I assume you selected "Alternate USB Boot" to boot from the USB stick.
You may want to build your kernel with serial output support to enable some printf at boot time.

Gwendal.
Reply all
Reply to author
Forward
This conversation is locked
You cannot reply and perform actions on locked conversations.
0 new messages