Skip to content

OCPBUGS-49675, OCPBUGS-55039: In OCL. Usbguard service fails when we install the usbguard extension: IPsec tmpfile.d directives missing when enabling IPsec in OCL #4986

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

Merged
merged 1 commit into from
Apr 23, 2025

Conversation

dkhater-redhat
Copy link
Contributor

@dkhater-redhat dkhater-redhat commented Apr 15, 2025

- What I did
Added the missing tmpfiles.d configurations ipsec and modified permissions for usbguard configuration. This is a patch and will be modified once USBGuard/usbguard#652 is backported into rhel.

- How to verify it

  1. Opt into OCL
  2. Apply a machine config to enable usbguard and ipsec
  3. Ensure that the extensions are properly installed

- Description for the changelog

@openshift-ci-robot openshift-ci-robot added jira/severity-moderate Referenced Jira bug's severity is moderate for the branch this PR is targeting. jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels Apr 15, 2025
@openshift-ci-robot
Copy link
Contributor

@dkhater-redhat: This pull request references Jira Issue OCPBUGS-49675, which is invalid:

  • expected the bug to target the "4.19.0" version, but no target version was set

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

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

In response to this:

- What I did

- How to verify it

- Description for the changelog

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-ci openshift-ci bot added the approved Indicates a PR has been approved by an approver from all required OWNERS files. label Apr 15, 2025
@dkhater-redhat dkhater-redhat changed the title OCPBUGS-49675: In OCL. Usbguard service fails when we install the usbguard extension OCPBUGS-49675, OCPBUGS-55039: In OCL. Usbguard service fails when we install the usbguard extension: IPsec tmpfile.d directives missing when enabling IPsec in OCL Apr 15, 2025
@openshift-ci-robot
Copy link
Contributor

@dkhater-redhat: This pull request references Jira Issue OCPBUGS-49675, which is invalid:

  • expected the bug to target the "4.19.0" version, but no target version was set

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

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

This pull request references Jira Issue OCPBUGS-55039, which is invalid:

  • expected the bug to target the "4.19.0" version, but no target version was set

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

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

In response to this:

- What I did
Added the missing tmpfiles.d configurations ipsec and modified permissions for usbguard configuration. This is a patch and will be modified once USBGuard/usbguard#652 is backported into rhel.

- How to verify it

  1. Opt into OCL
  2. Apply a machine config to enable usbguard and ipsec
  3. Ensure that the extensions are properly installed

- Description for the changelog

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.

@dkhater-redhat
Copy link
Contributor Author

/jira refresh

@openshift-ci-robot
Copy link
Contributor

@dkhater-redhat: This pull request references Jira Issue OCPBUGS-49675, which is invalid:

  • expected the bug to target the "4.19.0" version, but no target version was set

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

This pull request references Jira Issue OCPBUGS-55039, which is invalid:

  • expected the bug to target the "4.19.0" version, but no target version was set

Comment /jira refresh to re-evaluate validity if changes to the Jira bug are made, or edit the title of this pull request to link to a different bug.

In response to this:

/jira refresh

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.

@dkhater-redhat
Copy link
Contributor Author

/jira refresh

@openshift-ci-robot openshift-ci-robot added jira/valid-bug Indicates that a referenced Jira bug is valid for the branch this PR is targeting. and removed jira/invalid-bug Indicates that a referenced Jira bug is invalid for the branch this PR is targeting. labels Apr 15, 2025
@openshift-ci-robot
Copy link
Contributor

@dkhater-redhat: This pull request references Jira Issue OCPBUGS-49675, which is valid.

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

Requesting review from QA contact:
/cc @sergiordlr

This pull request references Jira Issue OCPBUGS-55039, 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.19.0) matches configured target version for branch (4.19.0)
  • bug is in the state New, which is one of the valid states (NEW, ASSIGNED, POST)

Requesting review from QA contact:
/cc @sergiordlr

In response to this:

/jira refresh

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-ci openshift-ci bot requested a review from sergiordlr April 15, 2025 17:01
@umohnani8
Copy link
Contributor

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Apr 15, 2025
@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d5e8466 and 2 for PR HEAD d5ce541 in total

3 similar comments
@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d5e8466 and 2 for PR HEAD d5ce541 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d5e8466 and 2 for PR HEAD d5ce541 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD d5e8466 and 2 for PR HEAD d5ce541 in total

@openshift-ci openshift-ci bot removed the lgtm Indicates that a PR is ready to be merged. label Apr 16, 2025
@umohnani8
Copy link
Contributor

/lgtm

@openshift-ci openshift-ci bot added the lgtm Indicates that a PR is ready to be merged. label Apr 17, 2025
Copy link
Contributor

openshift-ci bot commented Apr 17, 2025

[APPROVALNOTIFIER] This PR is APPROVED

This pull-request has been approved by: dkhater-redhat, umohnani8

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:
  • OWNERS [dkhater-redhat,umohnani8]

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

@ptalgulk01
Copy link

Pre-merge verification
Verified using AWS IPI based TechPreview based 4.19 cluster

  • Applied Below MOSC
MOSC Template
oc create -f - << EOF
apiVersion: machineconfiguration.openshift.io/v1
kind: MachineOSConfig
metadata:
  name: worker-4
spec:
  machineConfigPool:
    name: worker
  imageBuilder:
    imageBuilderType: Job
  baseImagePullSecret:
    name: $(oc get secret -n openshift-config pull-secret -o json | jq "del(.metadata.namespace, .metadata.creationTimestamp, .metadata.resourceVersion, .metadata.uid, .metadata.name)" | jq '.metadata.name="pull-copy"' | oc -n openshift-machine-config-operator create -f - &> /dev/null; echo -n "pull-copy")
  renderedImagePushSecret:
    name: $(oc get -n openshift-machine-config-operator sa builder -ojsonpath='{.secrets[0].name}')
  renderedImagePushSpec: "image-registry.openshift-image-registry.svc:5000/openshift-machine-config-operator/ocb-image:latest"

EOF
machineosconfig.machineconfiguration.openshift.io/worker-4 created

- After MCP update was successful applied below extension MC
oc get machineosbuilds
NAME                                        PREPARED   BUILDING   SUCCEEDED   INTERRUPTED   FAILED   AGE
worker-4-013e7244d67ba32faadf129abd020797   False      False      True        False         False    4m33s
Extension Template
oc create -f - << EOF
apiVersion: machineconfiguration.openshift.io/v1
kind: MachineConfig
metadata:
  labels:
    machineconfiguration.openshift.io/role: worker
  name: tc-56131-all-extensions
spec:
  config:
    ignition:
      version: 3.1.0
  extensions:
  - usbguard
  - kerberos
  - kernel-devel
  - sandboxed-containers
  - ipsec
  - wasm
  - sysstat
EOF
machineconfig.machineconfiguration.openshift.io/tc-56131-all-extensions created
- Check the extension installation
sh-5.1# rpm -qa |grep usbguard
usbguard-selinux-1.0.0-16.el9.noarch
usbguard-1.0.0-16.el9.x86_64
sh-5.1#  systemctl enable --now usbguard
Created symlink /etc/systemd/system/basic.target.wants/usbguard.service → /usr/lib/systemd/system/usbguard.service.
sh-5.1# journalctl -xeu usbguard.service
~
Apr 17 09:16:37 ip-10-0-38-113 systemd[1]: Starting USBGuard daemon...
░░ Subject: A start job for unit usbguard.service has begun execution
░░ Defined-By: systemd
░░ Support: https://access.redhat.com/support
░░ 
░░ A start job for unit usbguard.service has begun execution.
░░ 
░░ The job identifier is 2204.
Apr 17 09:16:37 ip-10-0-38-113 systemd[1]: Started USBGuard daemon.
░░ Subject: A start job for unit usbguard.service has finished successfully
░░ Defined-By: systemd
░░ Support: https://access.redhat.com/support
░░ 
░░ A start job for unit usbguard.service has finished successfully.
░░ 
░░ The job identifier is 2204.
sh-5.1# systemctl status usbguard       
● usbguard.service - USBGuard daemon
     Loaded: loaded (/usr/lib/systemd/system/usbguard.service; enabled; preset: disabled)
     Active: active (running) since Thu 2025-04-17 09:16:37 UTC; 50s ago
       Docs: man:usbguard-daemon(8)
    Process: 12338 ExecStart=/usr/sbin/usbguard-daemon -f -s -K -c /etc/usbguard/usbguard-daemon.conf (code=exited, status=0/SUCCESS)
   Main PID: 12340 (usbguard-daemon)
      Tasks: 3 (limit: 99972)
     Memory: 4.4M
        CPU: 149ms
     CGroup: /system.slice/usbguard.service
             └─12340 /usr/sbin/usbguard-daemon -f -s -K -c /etc/usbguard/usbguard-daemon.conf
Apr 17 09:16:37 ip-10-0-38-113 systemd[1]: Starting USBGuard daemon...
Apr 17 09:16:37 ip-10-0-38-113 systemd[1]: Started USBGuard daemon.
sh-5.1# rpm -V --nomtime crun-wasm kata-containers kernel-devel kernel-headers krb5-workstation libkadm5 libreswan NetworkManager-libreswan sysstat usbguard
missing     /usr/lib/tmpfiles.d/usbguard.conf
sh-5.1# rpm -qf /usr/lib/tmpfiles.d/usbguard.conf
usbguard-1.0.0-16.el9.x86_64
sh-5.1# rpm -qa | grep libreswan
libreswan-5.2-1.el9fdp.x86_64
NetworkManager-libreswan-1.2.24-1.el9.x86_64
sh-5.1# systemctl status libreswan
Unit libreswan.service could not be found.
sh-5.1# systemctl status ipsec
○ ipsec.service - Internet Key Exchange (IKE) Protocol Daemon for IPsec
     Loaded: loaded (/usr/lib/systemd/system/ipsec.service; enabled; preset: disabled)
    Drop-In: /etc/systemd/system/ipsec.service.d
             └─01-after-configure-ovs.conf
     Active: inactive (dead)
       Docs: man:ipsec(8)
             man:pluto(8)
             man:ipsec.conf(5)
sh-5.1# systemctl start ipsec
sh-5.1# systemctl status ipsec
● ipsec.service - Internet Key Exchange (IKE) Protocol Daemon for IPsec
     Loaded: loaded (/usr/lib/systemd/system/ipsec.service; enabled; preset: disabled)
    Drop-In: /etc/systemd/system/ipsec.service.d
             └─01-after-configure-ovs.conf
     Active: active (running) since Thu 2025-04-17 15:50:00 UTC; 3s ago
       Docs: man:ipsec(8)
             man:pluto(8)
             man:ipsec.conf(5)
    Process: 182322 ExecStartPre=/usr/libexec/ipsec/addconn --config /etc/ipsec.conf --checkconfig (code=exited, status=0/SUCCESS)
    Process: 182323 ExecStartPre=/usr/sbin/ipsec checknss (code=exited, status=0/SUCCESS)
    Process: 182327 ExecStartPre=/usr/sbin/ipsec checknflog (code=exited, status=0/SUCCESS)
   Main PID: 182342 (pluto)
     Status: "Startup completed."
      Tasks: 4 (limit: 99972)
     Memory: 6.8M
        CPU: 82ms
     CGroup: /system.slice/ipsec.service
             └─182342 /usr/libexec/ipsec/pluto --leak-detective --config /etc/ipsec.conf --nofork

/label qe-approved

@openshift-ci openshift-ci bot added the qe-approved Signifies that QE has signed off on this PR label Apr 17, 2025
@openshift-ci-robot
Copy link
Contributor

@dkhater-redhat: This pull request references Jira Issue OCPBUGS-49675, which is valid.

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

Requesting review from QA contact:
/cc @sergiordlr

This pull request references Jira Issue OCPBUGS-55039, which is valid.

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

Requesting review from QA contact:
/cc @sergiordlr

In response to this:

- What I did
Added the missing tmpfiles.d configurations ipsec and modified permissions for usbguard configuration. This is a patch and will be modified once USBGuard/usbguard#652 is backported into rhel.

- How to verify it

  1. Opt into OCL
  2. Apply a machine config to enable usbguard and ipsec
  3. Ensure that the extensions are properly installed

- Description for the changelog

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-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD 198d792 and 2 for PR HEAD fc5f032 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD b55822c and 1 for PR HEAD fc5f032 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD b55822c and 2 for PR HEAD fc5f032 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD 320f3d4 and 1 for PR HEAD fc5f032 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD 320f3d4 and 2 for PR HEAD fc5f032 in total

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD 82ece18 and 1 for PR HEAD fc5f032 in total

@dkhater-redhat
Copy link
Contributor Author

/retest-required

2 similar comments
@dkhater-redhat
Copy link
Contributor Author

/retest-required

@dkhater-redhat
Copy link
Contributor Author

/retest-required

@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD 01141a2 and 0 for PR HEAD fc5f032 in total

@openshift-ci-robot
Copy link
Contributor

/hold

Revision fc5f032 was retested 3 times: holding

@openshift-ci openshift-ci bot added the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Apr 22, 2025
@dkhater-redhat
Copy link
Contributor Author

/retest-required

@dkhater-redhat
Copy link
Contributor Author

/unhold

@openshift-ci openshift-ci bot removed the do-not-merge/hold Indicates that a PR should not merge because someone has issued a /hold command. label Apr 22, 2025
@openshift-ci-robot
Copy link
Contributor

/retest-required

Remaining retests: 0 against base HEAD 574295e and 2 for PR HEAD fc5f032 in total

Copy link
Contributor

openshift-ci bot commented Apr 23, 2025

@dkhater-redhat: The following test 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/bootstrap-unit fc5f032 link false /test bootstrap-unit

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

@dkhater-redhat
Copy link
Contributor Author

/test e2e-hypershift

@openshift-merge-bot openshift-merge-bot bot merged commit fd75b3e into openshift:main Apr 23, 2025
9 of 17 checks passed
@openshift-ci-robot
Copy link
Contributor

@dkhater-redhat: Jira Issue OCPBUGS-49675: All pull requests linked via external trackers have merged:

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

Jira Issue OCPBUGS-55039: All pull requests linked via external trackers have merged:

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

In response to this:

- What I did
Added the missing tmpfiles.d configurations ipsec and modified permissions for usbguard configuration. This is a patch and will be modified once USBGuard/usbguard#652 is backported into rhel.

- How to verify it

  1. Opt into OCL
  2. Apply a machine config to enable usbguard and ipsec
  3. Ensure that the extensions are properly installed

- Description for the changelog

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
Contributor

[ART PR BUILD NOTIFIER]

Distgit: ose-machine-config-operator
This PR has been included in build ose-machine-config-operator-container-v4.19.0-202504231110.p0.gfd75b3e.assembly.stream.el9.
All builds following this will include this PR.

cheesesashimi pushed a commit to cheesesashimi/machine-config-operator that referenced this pull request May 1, 2025
OCPBUGS-49675, OCPBUGS-55039: In OCL. Usbguard service fails when we install the usbguard extension: IPsec tmpfile.d directives missing when enabling IPsec in OCL
cheesesashimi pushed a commit to cheesesashimi/machine-config-operator that referenced this pull request May 2, 2025
OCPBUGS-49675, OCPBUGS-55039: In OCL. Usbguard service fails when we install the usbguard extension: IPsec tmpfile.d directives missing when enabling IPsec in OCL
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/severity-moderate Referenced Jira bug's severity is moderate for the branch this PR is targeting. 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. qe-approved Signifies that QE has signed off on this PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants