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

OCPBUGS-29271: Rebase lvms registry.access.redhat.com lvms4 lvms operator bundle v4.15.0 #2993

Conversation

jakobmoellerdev
Copy link
Contributor

Which issue(s) this PR addresses:

Update to LVMS 4.15, also solves https://issues.redhat.com/browse/USHIFT-1874 by moving to an embedded lvmd implementation which has feature parity but uses less containers and slightly fewer resources. The lvmd socket is not necessary.

Closes #

@openshift-ci-robot openshift-ci-robot added jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. labels Feb 8, 2024
@openshift-ci-robot
Copy link

@jakobmoellerdev: This pull request references Jira Issue OCPBUGS-29271, which is valid. The bug has been moved to the POST state.

3 validation(s) were run on this bug
  • bug is open, matching expected state (open)
  • bug target version (4.16.0) matches configured target version for branch (4.16.0)
  • bug is in the state ASSIGNED, which is one of the valid states (NEW, ASSIGNED, POST)

The bug has been updated to refer to the pull request using the external bug tracker.

In response to this:

Which issue(s) this PR addresses:

Update to LVMS 4.15, also solves https://issues.redhat.com/browse/USHIFT-1874 by moving to an embedded lvmd implementation which has feature parity but uses less containers and slightly fewer resources. The lvmd socket is not necessary.

Closes #

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@jakobmoellerdev
Copy link
Contributor Author

/test images

@openshift-ci openshift-ci bot requested review from copejon and jogeo February 8, 2024 21:06
@jakobmoellerdev jakobmoellerdev force-pushed the rebase-lvms-registry.access.redhat.com-lvms4-lvms-operator-bundle-v4.15.0 branch from 6b62ceb to 417336a Compare February 8, 2024 21:10
@jakobmoellerdev
Copy link
Contributor Author

/test images

cpu: 1m
memory: 16Mi
cpu: 2m
memory: 35Mi
Copy link
Contributor

Choose a reason for hiding this comment

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

Those are still small numbers, but they're doubling. Is that absolutely necessary?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

I am removing an entire container whose work is now done in this one. Total usage is still down, but we can of course always reduce further if the requests are continously lower than 70%. However the gains introduced by the container unification are 5-15% from my experience

Copy link
Contributor

Choose a reason for hiding this comment

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

Nice, that sounds like a good improvement overall.

scripts/auto-rebase/lvms_assets.yaml Show resolved Hide resolved
@@ -181,6 +169,10 @@ download_lvms_operator_bundle_manifest(){
local namespace="openshift-storage"
extract_lvms_rbac_from_cluster_service_version "${PWD}" "${csv}" "${namespace}"

# Push the configMap to the kube-public namespace so that it is available to all users/apps
generate_version_config_map "${version}" "lvms-version" "kube-public"\
Copy link
Contributor

Choose a reason for hiding this comment

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

Do we get one of these per ${ARCHS} now? Are the contents the same?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

The contents are identical but you use one staging environment per arch (not sure when or why this was introduced), so if i want to generate files I have to do this per arch.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

If you look at release-aarch64 / x86_64, the docker manifests are exactly the same because we build multi-arch containers, so Im not sure why one per arch is necessary

Copy link
Contributor

Choose a reason for hiding this comment

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

Maybe that's a legacy from when we were using images that were not multi-arch. @pmtk would likely know.

Copy link
Member

@pmtk pmtk Feb 9, 2024

Choose a reason for hiding this comment

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

I recall something about osbuild not handling multiarch images correctly while embedding? @ggiguash is that correct?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Im wondering how that fits together. LVMS has multiarch images since forever (4.12 I believe already had them), so im wondering how they wouldnt work with osbuild? Is that even relevant?

Copy link
Member

Choose a reason for hiding this comment

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

Wait, I may have misread things.

Previously the file was created at "${REPOROOT}/assets/components/lvms/topolvm-configmap_lvms-version.yaml" and now it ends up there because you removed "ignore" in lvms-assets.yaml.

I don't think we should make that change - entries without ignore are the ones we obtain from lvms' CSV, this is not the case for the file - we generate it during rebase, in microshift repo.

Copy link
Member

Choose a reason for hiding this comment

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

I discussed with @jakobmoellerdev what's going on here and now I know the story: version configmap was not generated correctly.

What Jakob proposed here is not strictly adhering to the flow we have in rebase.sh (that is: any file created during rebase, is created directly in assets, not in staging and then copied; like kustomizes per $ARCH for OLM).

However, I think proposed solution is more elegant - we don't need to use intermediate file where version gets dumped and then read during manifest update - it's generated during "download" which also extracts RBACs from CSV, then just copied with the power of lvms_assets.yaml and handle_assets.py. LGTM

Copy link
Contributor

Choose a reason for hiding this comment

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

I agree. It's still reusing the existing flow, but in a less round-about way.

@jakobmoellerdev
Copy link
Contributor Author

@copejon would be great if you could take a look today, ideally want to open up a rebase with the same functionality for 4.15 so that we finally get LVMS into the correct merge window for microshift-4.15

@jakobmoellerdev
Copy link
Contributor Author

/test images

@jakobmoellerdev
Copy link
Contributor Author

/cherry-pick release-4.15

@openshift-cherrypick-robot

@jakobmoellerdev: once the present PR merges, I will cherry-pick it on top of release-4.15 in a new PR and assign it to you.

In response to this:

/cherry-pick release-4.15

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

@jakobmoellerdev
Copy link
Contributor Author

/test ocp-conformance-rhel-eus-arm

@@ -149,12 +139,10 @@ download_lvms_operator_bundle_manifest(){

# Persist the version of the LVMS operator bundle for use in manifest steps
local version
version="$(parse_version "${bundle_manifest}")"
dump_version "${version}"
Copy link
Member

Choose a reason for hiding this comment

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

Seems this is not used anymore. Should we remove it?

@@ -181,6 +169,10 @@ download_lvms_operator_bundle_manifest(){
local namespace="openshift-storage"
extract_lvms_rbac_from_cluster_service_version "${PWD}" "${csv}" "${namespace}"

# Push the configMap to the kube-public namespace so that it is available to all users/apps
generate_version_config_map "${version}" "lvms-version" "kube-public"\
Copy link
Member

Choose a reason for hiding this comment

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

Wait, I may have misread things.

Previously the file was created at "${REPOROOT}/assets/components/lvms/topolvm-configmap_lvms-version.yaml" and now it ends up there because you removed "ignore" in lvms-assets.yaml.

I don't think we should make that change - entries without ignore are the ones we obtain from lvms' CSV, this is not the case for the file - we generate it during rebase, in microshift repo.

@jakobmoellerdev
Copy link
Contributor Author

jakobmoellerdev commented Feb 9, 2024

@pmtk The file ends up here because it is the canonical way to generate files during rebases. Before the change it was actually run twice.

I changed this logic because it simply does not do what its supposed to do and the lvms assets.yaml was generated directly into the assets directory and was not generated in the staging directory that is usually used in the rebase process.

To replicate, simply run the rebase from current main with the command from the last lvms rebase here without adjusting the script.

We do not obtain any of the RBACs from the CSV, I generate them in the script because you have no other way. Generating the config map with a version imo is the same functionality. Generating content based on the pulled image (in this case the tag instead of the CSV file inside the bundle image). The difference between ignore or not is actually just that ignored ones are ignored in the staging folder. They are still present during rebase but get ignored. They dont actuallyget regenerated, they are static and just dont get updated

@jakobmoellerdev
Copy link
Contributor Author

/test ocp-conformance-rhel-eus-arm

@jakobmoellerdev
Copy link
Contributor Author

/test microshift-metal-tests
/test microshift-metal-tests-arm

@pacevedom
Copy link
Contributor

/test microshift-metal-tests

1 similar comment
@jakobmoellerdev
Copy link
Contributor Author

/test microshift-metal-tests

@jakobmoellerdev
Copy link
Contributor Author

/test microshift-metal-tests
/test microshift-metal-tests-arm

@jakobmoellerdev
Copy link
Contributor Author

/test microshift-metal-tests

1 similar comment
@jakobmoellerdev
Copy link
Contributor Author

/test microshift-metal-tests

@jakobmoellerdev
Copy link
Contributor Author

/test microshift-metal-tests
/test microshift-metal-tests-arm

@jakobmoellerdev jakobmoellerdev force-pushed the rebase-lvms-registry.access.redhat.com-lvms4-lvms-operator-bundle-v4.15.0 branch from a97a9ff to 594b46c Compare February 13, 2024 13:02
@jakobmoellerdev
Copy link
Contributor Author

@copejon Ready for Dev Test / Confirmation

@pmtk
Copy link
Member

pmtk commented Feb 14, 2024

deployed using clusterbot, lvms-version CM and image refs in topolvm Pods look good
/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Feb 14, 2024
Copy link
Contributor

openshift-ci bot commented Feb 14, 2024

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: jakobmoellerdev, pmtk

The full list of commands accepted by this bot can be found here.

The pull request process is described here

Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@openshift-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Feb 14, 2024
Copy link
Contributor

openshift-ci bot commented Feb 14, 2024

@jakobmoellerdev: all tests passed!

Full PR test history. Your PR dashboard.

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. I understand the commands that are listed here.

@openshift-merge-bot openshift-merge-bot bot merged commit 00011b0 into openshift:main Feb 14, 2024
10 checks passed
@openshift-ci-robot
Copy link

@jakobmoellerdev: Jira Issue OCPBUGS-29271: All pull requests linked via external trackers have merged:

Jira Issue OCPBUGS-29271 has been moved to the MODIFIED state.

In response to this:

Which issue(s) this PR addresses:

Update to LVMS 4.15, also solves https://issues.redhat.com/browse/USHIFT-1874 by moving to an embedded lvmd implementation which has feature parity but uses less containers and slightly fewer resources. The lvmd socket is not necessary.

Closes #

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the openshift-eng/jira-lifecycle-plugin repository.

@openshift-cherrypick-robot

@jakobmoellerdev: #2993 failed to apply on top of branch "release-4.15":

Applying: chore: fix version config generation map for lvms
Applying: update last_lvms_rebase.sh
Applying: update LVMS manifests
Using index info to reconstruct a base tree...
M	assets/release/release-aarch64.json
M	assets/release/release-x86_64.json
Falling back to patching base and 3-way merge...
Auto-merging assets/release/release-x86_64.json
CONFLICT (content): Merge conflict in assets/release/release-x86_64.json
Auto-merging assets/release/release-aarch64.json
CONFLICT (content): Merge conflict in assets/release/release-aarch64.json
error: Failed to merge in the changes.
hint: Use 'git am --show-current-patch=diff' to see the failed patch
Patch failed at 0003 update LVMS manifests
When you have resolved this problem, run "git am --continue".
If you prefer to skip this patch, run "git am --skip" instead.
To restore the original branch and stop patching, run "git am --abort".

In response to this:

/cherry-pick release-4.15

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
approved Indicates a PR has been approved by an approver from all required OWNERS files. jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. lgtm Indicates that a PR is ready to be merged.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants