void-linux / void-linux/void-mklive

GPT PMBR size mismatch on generated image

Open
#246 1 comment 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Shell
Stars
516
Forks
270
PR merge metrics
No merged PRs in 30d

Description

I'm trying to build an image for the Pinebook Pro, doing the following:

> sudo ./mkrootfs.sh -o aarch64latest aarch64
> sudo ./mkplatformfs.sh pinebookpro aarch64latest
> sudo ./mkimage.sh void-pinebookpro-PLATFORMFS-20220403.tar.xz

This all completes without any errors, but when I write the resulting image to an SD card and then open that SD card with fdisk, it gives this error message:

> xzcat void-pinebookpro-20220403.img.xz | dd of=/dev/sde bs=4M status=progress
> sudo fdisk /dev/sde

Welcome to fdisk (util-linux 2.37.2).
Changes will remain in memory only, until you decide to write them.
Be careful before using the write command.

GPT PMBR size mismatch (4194303 != 125173759) will be corrected by write.
The backup GPT table is not on the end of the device. This problem will be corrected by write.

The SD card boots OK in the Pinebook Pro, but it will freeze up if I do anything disk intensive, and if I make any changes in fdisk (such as recreating the root partition to increase its size, or creating new partitions) then the SD card no longer boots.

Not sure if I'm doing something wrong when generating the image, or if there is actually a problem.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Reproduce the Pinebook Pro image with mkrootfs.sh, mkplatformfs.sh, and mkimage.sh, then inspect the resulting image with fdisk before and after writing it to an SD card. Compare the generated GPT and partition boundaries with the target device size and verify whether disk-intensive use and partition changes remain reliable. Done means the image no longer reports the GPT PMBR mismatch and continues to boot after valid partition changes.

Written by the indexing model from the issue text.

Assessment

Tech stack
shell
Domain
build-system, operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.