Repository navigation
Add KernelArguments to MachineConfig - #762
Conversation
|
Updated and tested with this MC: And I correctly get |
|
Looks good so far! When this makes it in let's not forget to drop the |
Yeah, though we'll need to ratchet by landing this, then switch the installer over to use it, then we can drop the pivot component. And...hum actually this goes straight into https://github.com/coreos/coreos-installer/issues/13 - we're served Ignition, not MachineConfig, so we won't have Hmm. Hmm. I think what we really want to do is have a mechanism to "invert" things and inject the extra stuff (today This would really be moving Or: we make this bit common between FCOS/RHCOS and add kargs into Ignition. |
I feel like that would be a big win and help bring the two closer together if it's feasible. /cc @bgilbert @ajeddeloh @dustymabe |
|
For Ignition kargs discussion, see https://github.com/coreos/ignition-dracut/issues/81. Note that it currently presumes a mechanism along the lines of ostreedev/ostree#479 (comment). |
|
Oh hey cool, this passed the new e2e test I added! But it failed units...looking at that. Will look at the other review comments here too. But we need to close the debate pretty soon - are we all OK with extending |
This is tricky, we got so may inputs and ideas (at a point, we wanted also something on top of MachineConfig to be more sugar to allow for a nice upgrade to ignv2s3). The CRD to allow us My preference would go to a new CRD though ( |
Yeah...what has me hesitating about that is all the copy-paste involved in the "sub-controllers". But eh, we can figure that out.
That's an interesting point. I had thought that for this we'd "bypass" Maybe there aren't that many special things that aren't basically files (i.e. Ignition), so we won't have to duplicate too much...I am actually having a bit of trouble thinking of anything besides kargs and osimageurl that are special. |
sebooleans? we had a doc at some point 🤔 but maybe sebooleans (timeservers and the like) aren't really operating system |
Oh yeah that's a good one. As far as other things like timeservers - this topic is kind of more about things that can't obviously "compile down" to just writing files or changing kernel args. Timeservers should basically just be writing a file. I think FIPS is potentially a good example as you need to run this |
oh yeah, FIPS is the follow up of this anyway (I'm ok on a pre-shipped unit as well if it works for RHCOS, but exercising it w/o a unit would be nice also). Ok, let's sum this up, I believe we can overload MachineConfig with Kargs|FIPS|Sebooleans and abstract those out with CRDs in follow ups if we really want to (even before next release for kargs|fips). |
|
/retest |
|
|
/test e2e-aws-upgrade |
|
The upgrade failure seems unrelated, seeing that in a few other jobs in https://prow.svc.ci.openshift.org/?job=*e2e-aws-upgrade*&state=failure |
We need to support things like adding `nosmt` to the kernel commandline, for users that want to choose security over performance; this is particularly relevant for multi-tenant clusters. There are a lot of other "tuning" features that are expressed as kernel cmdline args; another good exmaple is to have `node-tuning-operator` to write something like `machineconfig/05-node-tuning-operator`. Per discussion in the PR, we down the line probably want to add an `operatingsystem` type or so that would be a high level wrapper for this, but today everything else is expressed in `MachineConfig`, so we need to extend this type. There have also been some discussions about extending Ignition, but that's not likely to land soon, and even if it did we still need to handle "early pivot" pulling `machine-os-content`, and scoping both OS updates and kargs into Ignition is too far out. This is the first step which will support "day 2" configuration. After this lands, we have further work to have the MCS provide `MachineConfig` and not just Ignition, so that we can replace the "early pivot" with MCD code. Closes: openshift#388
|
OK, updated the commit message, and also updated the I think this is probably good to go ⏩ ? |
|
/retest |
|
Uhm, looks like upgrade is stuck from e2e? |
|
/retest |
|
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: cgwalters, runcom The full list of commands accepted by this bot can be found here. The pull request process is described here DetailsNeeds approval from an approver in each of these files:
Approvers can indicate their approval by writing |
This functionality has been replaced within the MCO. See: openshift/machine-config-operator#762 This reverts commit 9383200.
| return nil | ||
| } | ||
| if dn.OperatingSystem != machineConfigDaemonOSRHCOS { | ||
| return fmt.Errorf("Updating kargs on non-RHCOS nodes is not supported: %v", diff) |
There was a problem hiding this comment.
now that I'm looking at this, should we just return nicely as we do for updateOS 🤔
| // kargs | ||
| if err := dn.updateKernelArguments(oldConfig, newConfig); err != nil { | ||
| return err | ||
| } |
There was a problem hiding this comment.
and I've now found that we need to roll this back if we fail 😄
Add KernelArguments to MachineConfig
We need to support things like adding
nosmtto the kernelcommandline, for users that want to choose security over performance;
this is particularly relevant for multi-tenant clusters.
There are a lot of other "tuning" features that are expressed as
kernel cmdline args; down the line we want
node-tuning-operatorto write something like
machineconfig/05-node-tuning-operator.Per discussion in the PR, we may consider adding
an
operatingsystemCRD or so that would be a high level wrapperfor this, but today everything else is expressed in
MachineConfig,so we need to extend this type.
There have also been some discussions about extending Ignition,
but that's not likely to land soon, and even if it did we still
need to handle "early pivot" pulling
machine-os-content, andscoping both OS updates and kargs into Ignition is too far out.
This is the first step which will support "day 2" configuration.
After this lands, we have further work to have the MCS provide
MachineConfigand not just Ignition, so that we can replacethe "early pivot" with MCD code.
Closes: #388