Skip to content

[release-4.18] CORENET-5568: Stabilize IPsec E2E tests - #29632

Closed
pperiyasamy wants to merge 6 commits into
openshift:release-4.18from
pperiyasamy:stabilize-ipsec-e2e-4.18
Closed

[release-4.18] CORENET-5568: Stabilize IPsec E2E tests #29632
pperiyasamy wants to merge 6 commits into
openshift:release-4.18from
pperiyasamy:stabilize-ipsec-e2e-4.18

Conversation

@pperiyasamy

Copy link
Copy Markdown
Member

Backport of PRs #28797, #29437 and #29452. No Conflicts.

The ipsec test suite takes about 5-6 hours to finish running the tests
for e2e-aws-ovn-ipsec-serial CI lane, Hence this commit optimizes ipsec
tests so that it doesn't cause much of node reboots when changing ipsec
modes.

Signed-off-by: Periyasamy Palanisamy <pepalani@redhat.com>
(cherry picked from commit 1ee6b62)
Signed-off-by: Periyasamy Palanisamy <pepalani@redhat.com>
(cherry picked from commit 3d52d74)
This attempts to fix following error seen from ipsec test run:

I1118 11:08:34.394429 461 delete.go:70] Wait up to 5m0s for pod "ipsec-tcpdump-hostpod-vftlk" to be fully deleted
I1118 11:09:07.535653 461 exec_util.go:59] ExecWithOptions {Command:[/bin/sh -c cat /release-manifests/image-references] Namespace:e2e-test-ipsec-48sdq PodName:extract-release-imagerefs ContainerName:imagerefs Stdin:<nil> CaptureStdout:true CaptureStderr:true PreserveWhitespace:false Quiet:false}
I1118 11:09:07.536406 461 exec_util.go:66] ExecWithOptions: Clientset creation
I1118 11:09:07.536456 461 exec_util.go:83] ExecWithOptions: execute(POST https://api.ci-op-6ic49xd0-f3b46.aws-2.ci.openshift.org:6443/api/v1/namespaces/e2e-test-ipsec-48sdq/pods/extract-release-imagerefs/exec?command=%2Fbin%2Fsh&command=-c&command=cat+%2Frelease-manifests%2Fimage-references&container=imagerefs&container=imagerefs&stderr=true&stdout=true)
I1118 11:09:07.642284 461 exec_util.go:111] Exec stderr: ""
I1118 11:09:07.642418 461 exec_util.go:112] Unexpected error: failed to execute command in pod extract-release-imagerefs, container imagerefs: error sending request: Post "https://api.ci-op-6ic49xd0-f3b46.aws-2.ci.openshift.org:6443/api/v1/namespaces/e2e-test-ipsec-48sdq/pods/extract-release-imagerefs/exec?command=%2Fbin%2Fsh&command=-c&command=cat+%2Frelease-manifests%2Fimage-references&container=imagerefs&container=imagerefs&stderr=true&stdout=true": read tcp 10.131.68.7:51092->54.244.16.237:6443: read: connection reset by peer:
     <*errors.errorString | 0xc006aabf10>:
      error sending request: Post "https://api.ci-op-6ic49xd0-f3b46.aws-2.ci.openshift.org:6443/api/v1/namespaces/e2e-test-ipsec-48sdq/pods/extract-release-imagerefs/exec?command=%2Fbin%2Fsh&command=-c&command=cat+%2Frelease-manifests%2Fimage-references&container=imagerefs&container=imagerefs&stderr=true&stdout=true": read tcp 10.131.68.7:51092->54.244.16.237:6443: read: connection reset by peer
      {
          s: "error sending request: Post \"https://api.ci-op-6ic49xd0-f3b46.aws-2.ci.openshift.org:6443/api/v1/namespaces/e2e-test-ipsec-48sdq/pods/extract-release-imagerefs/exec?command=%2Fbin%2Fsh&command=-c&command=cat+%2Frelease-manifests%2Fimage-references&container=imagerefs&container=imagerefs&stderr=true&stdout=true\": read tcp 10.131.68.7:51092->54.244.16.237:6443: read: connection reset by peer",
      }
    [FAILED] in [It] - k8s.io/kubernetes@v1.31.1/test/e2e/framework/pod/exec_util.go:112 @ 11/18/24 11:09:07.701

Signed-off-by: Periyasamy Palanisamy <pepalani@redhat.com>
(cherry picked from commit 7386625)
When IPsec tests configuring certificates into libreswan nss db for
north south traffic via a machine config, it's rebooting worker nodes
by default which still makes one of the following monitor test to fail.

4 unexpected clusteroperator state transitions during e2e test run.  These did not match any known exceptions, so they cause this test-case to fail:

Jan 15 19:44:18.575 E clusteroperator/kube-storage-version-migrator condition/Available reason/KubeStorageVersionMigrator_Deploying status/False KubeStorageVersionMigratorAvailable: Waiting for Deployment
Jan 15 19:44:18.575 - 5s    E clusteroperator/kube-storage-version-migrator condition/Available reason/KubeStorageVersionMigrator_Deploying status/False KubeStorageVersionMigratorAvailable: Waiting for Deployment
Jan 15 20:06:29.820 E clusteroperator/kube-storage-version-migrator condition/Available reason/KubeStorageVersionMigrator_Deploying status/False KubeStorageVersionMigratorAvailable: Waiting for Deployment
Jan 15 20:06:29.820 - 1s    E clusteroperator/kube-storage-version-migrator condition/Available reason/KubeStorageVersionMigrator_Deploying status/False KubeStorageVersionMigratorAvailable: Waiting for Deployment

2 unwelcome but acceptable clusteroperator state transitions during e2e test run.  These should not happen, but because they are tied to exceptions, the fact that they did happen is not sufficient to cause this test-case to fail:

Jan 15 19:44:24.518 W clusteroperator/kube-storage-version-migrator condition/Available reason/AsExpected status/True All is well (exception: Available=True is the happy case)
Jan 15 20:06:31.725 W clusteroperator/kube-storage-version-migrator condition/Available reason/AsExpected status/True All is well (exception: Available=True is the happy case)

Actually it is not required to reboot the nodes just for configuring
certs on the nss db. Hence adding nod edisruption machine configuration
policy so that nodes are not rebooted while deploying certificates on the
worker nodes.

Signed-off-by: Periyasamy Palanisamy <pepalani@redhat.com>
(cherry picked from commit 14e7f6c)
When IPsec mode are changed across tests within IPsec test suite,
it causes reboot of ovnkube-node daemonset pods, It's expected
workload traffic would fail temporarily until pods are settle down
after IPsec is properly configured in every node's OVN and OvS across
the cluster. So we should not test ipsec mode change in the ipsec
test suite and instead for every ipsec mode, there should be one CI lane,
then in the test corresponding configuration and traffic must be tested.

So this commit removes everything related to IPsec mode changes and having
a single test which can be run from Full and External IPsec mode CI lanes.

Signed-off-by: Periyasamy Palanisamy <pepalani@redhat.com>
(cherry picked from commit c53288d)
This commit fixes following test failures seen in CI runs.

1. [sig-auth] all workloads in ns/openshift-nmstate must set the 'openshift.io/required-scc' annotation

https://prow.ci.openshift.org/view/gs/test-platform-results/pr-logs/pull/29437/pull-ci-openshift-origin-master-e2e-aws-ovn-ipsec-serial/1879584910717489152

2. Wait enough to get nmstate-handler daemonset running state.

[sig-network][Feature:IPsec] when using openshift ovn-kubernetes [BeforeAll] check traffic [apigroup:config.openshift.io] [Suite:openshift/network/ipsec] with IPsec in full mode
  [BeforeAll] github.com/openshift/origin/test/extended/networking/ipsec.go:449
  [It] github.com/openshift/origin/test/extended/networking/ipsec.go:628

  [FAILED] Unexpected error:
      <*errors.errorString | 0xc0015847e0>:
      failed to get nmstate handler running: context deadline exceeded
      {
          s: "failed to get nmstate handler running: context deadline exceeded",
      }
  occurred
  In [BeforeAll] at: github.com/openshift/origin/test/extended/networking/ipsec.go:464 @ 01/16/25 11:12:58.598

https://prow.ci.openshift.org/view/gs/test-platform-results/logs/multi-pr-openshift-cluster-network-operator-2606-openshift-origin-29437-e2e-aws-ovn-ipsec-serial/1879821657376296960

Signed-off-by: Periyasamy Palanisamy <pepalani@redhat.com>
(cherry picked from commit e2e54ef)
@openshift-ci
openshift-ci Bot requested review from celebdor and danwinship April 1, 2025 10:11
@pperiyasamy

Copy link
Copy Markdown
Member Author

/test e2e-aws-ovn-ipsec-serial

@pperiyasamy

Copy link
Copy Markdown
Member Author

/assign @martinkennelly @zshi-redhat

@pperiyasamy

Copy link
Copy Markdown
Member Author

@pperiyasamy

Copy link
Copy Markdown
Member Author

/test e2e-aws-ovn-ipsec-serial

@pperiyasamy

Copy link
Copy Markdown
Member Author

/testwith openshift/origin/release-4.18/e2e-aws-ovn-ipsec-serial openshift/machine-config-operator#4967

@martinkennelly martinkennelly left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Lgtm .. Waiting on ci. Any changes you needed to make ? Ive only a cosmetic question.

}

func findIPsecPodonNode(oc *exutil.CLI, nodeName string) (string, error) {
out, err := runOcWithRetry(oc.AsAdmin(), "get",

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Kube client not available ?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

@martinkennelly of course kube client is available and it can be simplified with that, but i think we can do it with another PR. let us keep this backport as it is now. are you ok ?

@openshift-ci

openshift-ci Bot commented Apr 1, 2025

Copy link
Copy Markdown
Contributor

@pperiyasamy: The following tests failed, say /retest to rerun all failed tests or /retest-required to rerun all mandatory failed tests:

Test name Commit Details Required Rerun command
ci/prow/e2e-aws-ovn-kube-apiserver-rollout de269f4 link false /test e2e-aws-ovn-kube-apiserver-rollout
ci/prow/e2e-metal-ipi-ovn-ipv6 de269f4 link true /test e2e-metal-ipi-ovn-ipv6
ci/prow/e2e-metal-ipi-ovn de269f4 link false /test e2e-metal-ipi-ovn
ci/prow/e2e-aws-ovn-serial de269f4 link true /test e2e-aws-ovn-serial
ci/prow/e2e-aws-ovn-edge-zones de269f4 link true /test e2e-aws-ovn-edge-zones
ci/prow/e2e-aws-ovn-single-node-serial de269f4 link false /test e2e-aws-ovn-single-node-serial
ci/prow/e2e-aws-ovn-fips de269f4 link true /test e2e-aws-ovn-fips
ci/prow/e2e-metal-ipi-ovn-kube-apiserver-rollout de269f4 link false /test e2e-metal-ipi-ovn-kube-apiserver-rollout

Full PR test history. Your PR dashboard.

Details

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-sigs/prow repository. I understand the commands that are listed here.

@pperiyasamy

Copy link
Copy Markdown
Member Author

/test e2e-aws-ovn-ipsec-serial

@martinkennelly

Copy link
Copy Markdown
Contributor

/lgtm

looked at the ipsec lane and saw it executed one ipsec test for 6min.
@pperiyasamy where does this lane run? what repos? release payload?

@openshift-ci openshift-ci Bot added the lgtm Indicates that a PR is ready to be merged. label Apr 7, 2025
@pperiyasamy

Copy link
Copy Markdown
Member Author

/assign @dgoodwin

@dgoodwin

dgoodwin commented Apr 9, 2025

Copy link
Copy Markdown
Contributor

/approve

@openshift-ci

openshift-ci Bot commented Apr 9, 2025

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dgoodwin, martinkennelly, pperiyasamy

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

The pull request process is described here

Details 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 Apr 9, 2025
@dgoodwin

dgoodwin commented Apr 9, 2025

Copy link
Copy Markdown
Contributor

/label backport-risk-assessed

@openshift-ci openshift-ci Bot added the backport-risk-assessed Indicates a PR to a release branch has been evaluated and considered safe to accept. label Apr 9, 2025
@pperiyasamy pperiyasamy changed the title [release-4.18] Stabilize IPsec E2E tests [release-4.18] CORENET-5568: Stabilize IPsec E2E tests Apr 14, 2025
@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Apr 14, 2025
@openshift-ci-robot

openshift-ci-robot commented Apr 14, 2025

Copy link
Copy Markdown

@pperiyasamy: This pull request references CORENET-5568 which is a valid jira issue.

Warning: The referenced jira issue has an invalid target version for the target branch this PR targets: expected the story to target the "4.18.z" version, but no target version was set.

Details

In response to this:

Backport of PRs #28797, #29437 and #29452. No Conflicts.

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-bot

Copy link
Copy Markdown
Contributor

Issues go stale after 90d of inactivity.

Mark the issue as fresh by commenting /remove-lifecycle stale.
Stale issues rot after an additional 30d of inactivity and eventually close.
Exclude this issue from closing by commenting /lifecycle frozen.

If this issue is safe to close now please do so with /close.

/lifecycle stale

@openshift-ci openshift-ci Bot added the lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. label Jul 14, 2025
@openshift-bot

Copy link
Copy Markdown
Contributor

Stale issues rot after 30d of inactivity.

Mark the issue as fresh by commenting /remove-lifecycle rotten.
Rotten issues close after an additional 30d of inactivity.
Exclude this issue from closing by commenting /lifecycle frozen.

If this issue is safe to close now please do so with /close.

/lifecycle rotten
/remove-lifecycle stale

@openshift-ci openshift-ci Bot added lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed. and removed lifecycle/stale Denotes an issue or PR has remained open with no activity and has become stale. labels Aug 13, 2025
@openshift-bot

Copy link
Copy Markdown
Contributor

Rotten issues close after 30d of inactivity.

Reopen the issue by commenting /reopen.
Mark the issue as fresh by commenting /remove-lifecycle rotten.
Exclude this issue from closing again by commenting /lifecycle frozen.

/close

@openshift-ci openshift-ci Bot closed this Sep 13, 2025
@openshift-ci

openshift-ci Bot commented Sep 13, 2025

Copy link
Copy Markdown
Contributor

@openshift-bot: Closed this PR.

Details

In response to this:

Rotten issues close after 30d of inactivity.

Reopen the issue by commenting /reopen.
Mark the issue as fresh by commenting /remove-lifecycle rotten.
Exclude this issue from closing again by commenting /lifecycle frozen.

/close

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-sigs/prow 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. backport-risk-assessed Indicates a PR to a release branch has been evaluated and considered safe to accept. 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. lifecycle/rotten Denotes an issue or PR that has aged beyond stale and will be auto-closed.

Projects

None yet

Development

Successfully merging this pull request may close these issues.