Skip to content

Instantly share code, notes, and snippets.

@ancorgs
Last active May 31, 2019 11:01
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ancorgs/c7c9d7ccd3feb38b3f40e85d58e4a671 to your computer and use it in GitHub Desktop.
Save ancorgs/c7c9d7ccd3feb38b3f40e85d58e4a671 to your computer and use it in GitHub Desktop.
SUMA Guided Setup

This shows a preliminary idea on how the SUMA requirements could be addressed reusing a lot of code from the current partitioning proposal and from the current Guided Setup.

In the control file, we just need to add a new attribute to identify volumes that must be allocated in its own separate LVM VG. The rest of the <partitioning> section of control.xml would stay as it is now.

And then, the new wizard would reuse many of the steps already present in the current Guided Setup.

In the general case, the first step is identical to one already existing in the current Guided Setup.

First standard

If any of the volumes in the control file contains the new attribute, that screen will contain more specific options about how to use LVM (wording to be improved).

First

The second step is basically the same than the current step to configure the various volumes/filesystems specified in control.xml. The only change here is that volumes marked with the new attribute will be described as "Separate $PATH Volume Group" if the option to use separate volume groups was marked in the first screen.

Second

The third step is the only completely new one, compared to the classic Guided Setup. It will offer the option to select in which disk to allocate every VG or Partition.

Third

The first obvious remark about this third step if that is could obviously be skipped if there is only one disk in the system.

If there are several disks and "Enable LVM for the Base System" was selected in the first screen, then the options for root, swap and any other "regular" volume (i.e. volumes not marked with the new attribute) will be merged into a single option "Disk for the System Volume Group".

If the option to use LVM for the base system was marked but the option to use separate volume groups was not, then there is only one volume group to allocate. Maybe that case needs better handling than a screen with just one question.

The last step is, again, basically reused from the classic Guided Setup.

Fourth

Since in SUMA it's always desired to delete the whole previous content of all the modified disks, it would be possible to add another attribute to control.xml to make that screen optional. So the "delete even if not needed" option (or any other) can be enforced for all types of partitions via control file without offering to the user the possibility of changing that.

The described wizard makes easy for the user to select where to place every volume, with the small restriction of every volume group been placed in only one disk (i.e. a particular volume group cannot be specified to be over several disks).

About the initial settings (i.e. the values used for the very first attempt before the user has had the chance to go through the wizard), I wouldn't do anything special about the location of each volume group. I would keep the current general behavior of trying to place everything in the first disk (or in the second if that fails and so on). Because it would be close to impossible to get the initial settings right anyway. So the more simple and deterministic the better. The user will only need to go through the new wizard to get the desired distribution.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment