docs: document the clean --raid modes - #1080
Open
ideaship wants to merge 2 commits into
Open
Conversation
`osism baremetal clean` gained `--raid {delete,keep,recreate}`, replacing the
earlier boolean flag. None of it was documented: no `clean` flag appears
anywhere on these pages, and the software RAID page described the array as
something only `osism baremetal deploy` applies.
Cover it in the two places an operator would look. Node deployment gets the
three modes, the bare `--raid` shorthand, how `--metadata-only` interacts with
them, and the `recreate` refusal rules, including that `--all` skips and
reports rather than aborting and then exits non-zero. Software RAID gets a
section on building or rebuilding the declared array without a deployment,
which is what `--raid recreate` is for, along with the reason delete and erase
have to precede the create step and the `--metadata-only` variant for hardware
whose disks cannot be erased in band.
Also note that a full clean removes the array by default. That was already
true before the flag existed and is easy to be surprised by, since the array
is otherwise only ever mentioned as something a deploy creates.
The argument order caveat is documented because it is not guessable: `--raid`
takes an optional value, so argparse claims a node name written directly after
it and `clean --raid node101` is rejected.
Assisted-by: Claude:claude-opus-5
Signed-off-by: Roger Luethi <luethi@osism.tech>
Two gaps in the first pass, both found by working through what an operator actually asks when they hit this. The refusal was justified only as not deleting the array it was asked to rebuild. The concrete consequence is what makes it understandable: Ironic accepts the request and fails on the create step, which runs last, so the disks are already erased and the node ends up in `clean failed` with maintenance mode set. Recovering means clearing the flag and cleaning again. Knowing that turns the refusal from an obstacle into an obvious kindness. The mixed fleet was also unaddressed, and it is the common case: half the nodes have a `target_raid_config` and half have no RAID interface at all. Because the modes only ever apply to nodes with a RAID interface, one `--all` run does the right thing for both halves, and there is nothing to select. Worth saying, because there is no way to select a subset of nodes even if it were needed. Assisted-by: Claude:claude-opus-5 Signed-off-by: Roger Luethi <luethi@osism.tech>
✅MegaLinter analysis: Success
See detailed reports in MegaLinter artifacts Your project could benefit from a custom flavor, which would allow you to run only the linters you need, and thus improve runtime performances. (Skip this info by defining
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.

Documents the RAID handling of
osism baremetal clean, including the three named modesadded in:
Neither page mentioned any
cleanflag before this — not--raid, not--metadata-only— andsoftware-raid.mddescribed the array as something onlyosism baremetal deployever applies.node-deployment.mdExtends the existing clean section with the three modes, the bare
--raidshorthand,how
--metadata-onlyinteracts with them, and therecreaterefusal rules includingthat
--allskips and reports rather than aborting, then exits non-zero.Also states that a mixed fleet needs no special handling. That is the common case — half
the nodes have a
target_raid_config, half have no RAID interface at all — and sincethe modes only ever apply to nodes with a RAID interface, one
--allrun does the rightthing for both halves. Worth saying explicitly, because there is no way to select a
subset of nodes even if one were needed.
The argument order caveat is documented because it is not guessable:
--raidtakes anoptional value, so a node name written directly after it is claimed as the value and
clean --raid node101is rejected.software-raid.mdNew section on building or rebuilding the declared array without a deployment, which is
what
--raid recreateis for, plus the reason delete and erase have to precede thecreate step (Ironic's create step does not remove existing disks and fails on a
partitioned target) and the
--metadata-only --raid recreatevariant for hardware whosedisks cannot be erased in band.
Two things an operator can be caught by, now stated:
existed, and the page otherwise only ever mentions the array as something a deploy
creates.
recreaterefuses a node with notarget_raid_configrather than proceeding.Ironic accepts such a request and fails on the create step, which runs last, so the
disks are already erased and the node lands in
clean failedwith maintenance modeset. Recovering means clearing the flag and cleaning again.
Checks
yarn buildpasses, which matters here becauseonBrokenLinks: 'throw'and the twopages now cross-reference each other.
markdown-table-formatter --checkreports nothingto reformat and
codespellis clean.Draft until the companion PR is reviewed; they should land together, since this
documents flags that do not exist on
mainyet.