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

Wipe Disks Improvements #885

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

ibrokethecloud
Copy link
Contributor

Problem:

We introduced a field in Harvester config named wipeDisks which when set ran a script in the installer to iterate over all disk devices visible to the host and wipe them.

This ended up being too aggressive, not to mention not all disks may contain old Harvester installations.

Solution:

PR introduces two new fields in the harvester config wipeDisksList and wipeAllDisks and drops the old wipeDisks introduced in v1.3

There is an extra panel in disk configuration page. The extra panel contains a drop down menu which gets rendered and populated if installer finds additional disks with existing elemental based installations which are not already used in install device or additional data device.

The extra Wipe Disks panels will only be available when there are additional disks visible to the host which have a partition with COS_OEM label and such disk is not already being used in Install Device or Install Data Device.

image

User can also pass these fields via ipxe using the following two new fields

install:
  wipeAllDisks: true

or

install:
  wipeDisksList: 
     - device1
     - device2

wipeAllDisks uses the same logic as the installers Wipe Disks Panel where it will identify additional disks with COS_OEM partition which are not already being used as Install Device or Install Data Device.

Related Issue:
harvester/harvester#6304
harvester/harvester#6533

Test plan:

pkg/console/util.go Show resolved Hide resolved
pkg/console/util.go Show resolved Hide resolved
pkg/console/util_test.go Show resolved Hide resolved
@ibrokethecloud ibrokethecloud requested a review from ihcsim December 1, 2024 21:45
pkg/config/config.go Show resolved Hide resolved
pkg/console/util.go Show resolved Hide resolved
pkg/console/install_panels.go Show resolved Hide resolved
pkg/console/install_panels.go Show resolved Hide resolved
Copy link

mergify bot commented Dec 27, 2024

This pull request is now in conflict. Could you fix it @ibrokethecloud? 🙏

@ihcsim
Copy link
Contributor

ihcsim commented Jan 10, 2025

LGTM - can approve once conflicts are resolved.

PR introduces two new fields in the harvester config wipeDisksList and
wipeAllDisks and drops the old wipeDisks introduced in v1.3

There is an extra panel in disk configuration page. The extra panel
contains a drop down menu which gets rendered and populated if installer
finds additional disks with existing elemental based installations which
are not already used in install device or additional data device
Copy link
Contributor

@Vicente-Cheng Vicente-Cheng left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, thanks for the enhancement!

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.

3 participants