Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: implement device wiping by signatures #116

Merged
merged 1 commit into from
Nov 15, 2024

Conversation

smira
Copy link
Member

@smira smira commented Nov 15, 2024

This allows to wipe specific signatures which are used to detect filesystems and partitions.

This is important for cases like this one:

  • create a GPT partition table
  • format filesystems
  • wipe the whole device
  • re-create GPT partition table with exactly same layout
  • if the signatures for filesystems haven't been properly wiped, the filesystem will re-appear

The previous implementation only wiped first and last 1MB which enough to wipe GPT, but not all filesystems.

Probe now returns offsets of signatures to be wiped.

Fixed some bugs, including extra "recovery" of GPT from alternate header if the primary is completely zeroed out.

Fixes siderolabs/talos#9724

Fixes siderolabs/talos#9530

This allows to wipe specific signatures which are used to detect
filesystems and partitions.

This is important for cases like this one:

* create a GPT partition table
* format filesystems
* wipe the whole device
* re-create GPT partition table with exactly same layout
* if the signatures for filesystems haven't been properly wiped, the
  filesystem will re-appear

The previous implementation only wiped first and last 1MB which enough
to wipe GPT, but not all filesystems.

Probe now returns offsets of signatures to be wiped.

Fixed some bugs, including extra "recovery" of GPT from alternate header
if the primary is completely zeroed out.

Fixes siderolabs/talos#9724

Fixes siderolabs/talos#9530

Signed-off-by: Andrey Smirnov <[email protected]>
@smira
Copy link
Member Author

smira commented Nov 15, 2024

/m

@talos-bot talos-bot merged commit 6d3b4b0 into siderolabs:v2 Nov 15, 2024
14 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

implement wipe by probe signatures "Error probing disks" after upgrade from 1.7.6 to 1.8.1
3 participants