Skip to content

Option to verify written image after copy #56

Description

@zhovner

Sometimes an image is written successfully with no errors, but it is actually corrupted on some SD cards when read back.

Currently I verify the image with an extra command:

# Write image to disk
bmaptool copy image.img.gz /dev/sdisk

# Read from disk and verify with the bmap file
bmaptool copy --bmap image.img.bmap /dev/sdisk /dev/null

We need an option to perform the same verification with a single command.

Something like:

bmaptool -v copy — could be misread as the version option
bmaptool -p copy — "protective copy"?
bmaptool -s copy — "secure copy"?

or only full name:

  • --verify
  • --verify-write
  • --readback-verify

This is how tools like rpi-imager, etcher etc. conceptually describe this feature.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions