Skip to content

ROX-30241: Updates for vm scanning#106074

Open
kcarmichael08 wants to merge 1 commit intoopenshift:rhacs-docs-mainfrom
kcarmichael08:ROX-30241-virt
Open

ROX-30241: Updates for vm scanning#106074
kcarmichael08 wants to merge 1 commit intoopenshift:rhacs-docs-mainfrom
kcarmichael08:ROX-30241-virt

Conversation

@kcarmichael08
Copy link
Contributor

@kcarmichael08 kcarmichael08 commented Feb 5, 2026

Version(s): 4.10

Issue: ROX-30241

Link to docs preview:

New sections:

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/examine-images-for-vulnerabilities.html#scanning-virtual-machines_examine-images-for-vulnerabilities

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/manage-vulnerabilities/common-vuln-management-tasks#viewing-view-vms-cves_vms

note to reviewers: Please focus on new sections. We had to fix some issues with modules/assemblies so that our files will pass new pre-migration checks that are being added to the repo in advance of our conversion to DITA and move to a new doc publishing program this year. These changes are included so that the PR will pass but do not affect the new material added to the docs.

Focus on:

  • modules/configuring-vm-scanning.adoc
  • modules/deploy-roxagent.adoc
  • modules/scanning-vms.adoc
  • modules/troubleshooting-vm-scanning.adoc
  • modules/view-vms-cves.adoc
  • modules/vm-scanning-limitations.adoc
  • modules/vm-scanning-requirements.adoc
  • modules/vulnerability-management-components-portal.adoc

Ignore changes in:

  • architecture/acs-architecture.adoc‎
  • cloud_service/upgrading-cloud/upgrade-cloudsvc-roxctl.adoc‎
  • cloud_service/acscs-architecture.adoc
  • modules/about-vulnerabilities.adoc
  • modules/installing-scanner-slim-helm.adoc
  • modules/installing-scanner-slim-operator.adoc
  • modules/installing-scanner-slim.adoc
  • modules/scannerv4-enabling.adoc
  • modules/scanning-about.adoc
  • modules/setting-up-scanning.adoc
  • modules/using-image-scanning.adoc
  • modules/verifying-scanner-installation.adoc
  • operating/manage-vulnerabilities/common-vuln-management-tasks.adoc
  • operating/manage-vulnerabilities/scan-rhcos-node-host.adoc
  • operating/examine-images-for-vulnerabilities.adoc

QE review:

  • QE has approved this change.

Additional information:

@openshift-ci-robot openshift-ci-robot added the jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. label Feb 5, 2026
@openshift-ci-robot
Copy link

openshift-ci-robot commented Feb 5, 2026

@kcarmichael08: This pull request references ROX-30241 which is a valid jira issue.

Details

In response to this:

Version(s): 4.10

(ROX-30241)

Link to docs preview:

QE review:

  • QE has approved this change.

Additional information:

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

openshift-ci-robot commented Feb 5, 2026

@kcarmichael08: This pull request references ROX-30241 which is a valid jira issue.

Details

In response to this:

Version(s): 4.10

Issue: ROX-30241

Link to docs preview:

QE review:

  • QE has approved this change.

Additional information:

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 size/L Denotes a PR that changes 100-499 lines, ignoring generated files. label Feb 5, 2026
@kcarmichael08 kcarmichael08 force-pushed the ROX-30241-virt branch 3 times, most recently from f537670 to 4e41c7a Compare February 5, 2026 19:11
@openshift-ci-robot
Copy link

openshift-ci-robot commented Feb 9, 2026

@kcarmichael08: This pull request references ROX-30241 which is a valid jira issue.

Details

In response to this:

Version(s): 4.10

Issue: ROX-30241

Link to docs preview:

New sections:

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/examine-images-for-vulnerabilities.html#scanning-virtual-machines_examine-images-for-vulnerabilities

https://106054--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/manage-vulnerabilities/common-vuln-management-tasks.html#base-image-vulnerabilities_other

QE review:

  • QE has approved this change.

Additional information:

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

openshift-ci-robot commented Feb 9, 2026

@kcarmichael08: This pull request references ROX-30241 which is a valid jira issue.

Details

In response to this:

Version(s): 4.10

Issue: ROX-30241

Link to docs preview:

New sections:

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/examine-images-for-vulnerabilities.html#scanning-virtual-machines_examine-images-for-vulnerabilities

QE review:

  • QE has approved this change.

Additional information:

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 size/XL Denotes a PR that changes 500-999 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Feb 9, 2026
@openshift-ci-robot
Copy link

openshift-ci-robot commented Feb 9, 2026

@kcarmichael08: This pull request references ROX-30241 which is a valid jira issue.

Details

In response to this:

Version(s): 4.10

Issue: ROX-30241

Link to docs preview:

New sections:

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/examine-images-for-vulnerabilities.html#scanning-virtual-machines_examine-images-for-vulnerabilities

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/manage-vulnerabilities/common-vuln-management-tasks#viewing-view-vms-cves_vms

QE review:

  • QE has approved this change.

Additional information:

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

openshift-ci-robot commented Feb 9, 2026

@kcarmichael08: This pull request references ROX-30241 which is a valid jira issue.

Details

In response to this:

Version(s): 4.10

Issue: ROX-30241

Link to docs preview:

New sections:

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/examine-images-for-vulnerabilities.html#scanning-virtual-machines_examine-images-for-vulnerabilities

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/manage-vulnerabilities/common-vuln-management-tasks#viewing-view-vms-cves_vms

note to reviewers: Please focus on new sections. We had to fix some issues with modules/assemblies so that our files will pass new pre-migration checks that are being added to the repo in advance of our conversion to DITA and move to a new doc publishing program this year.

QE review:

  • QE has approved this change.

Additional information:

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

openshift-ci-robot commented Feb 9, 2026

@kcarmichael08: This pull request references ROX-30241 which is a valid jira issue.

Details

In response to this:

Version(s): 4.10

Issue: ROX-30241

Link to docs preview:

New sections:

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/examine-images-for-vulnerabilities.html#scanning-virtual-machines_examine-images-for-vulnerabilities

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/manage-vulnerabilities/common-vuln-management-tasks#viewing-view-vms-cves_vms

note to reviewers: Please focus on new sections. We had to fix some issues with modules/assemblies so that our files will pass new pre-migration checks that are being added to the repo in advance of our conversion to DITA and move to a new doc publishing program this year. These changes are included so that the PR will pass but do not affect the new material added to the docs.

QE review:

  • QE has approved this change.

Additional information:

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

openshift-ci-robot commented Feb 9, 2026

@kcarmichael08: This pull request references ROX-30241 which is a valid jira issue.

Details

In response to this:

Version(s): 4.10

Issue: ROX-30241

Link to docs preview:

New sections:

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/examine-images-for-vulnerabilities.html#scanning-virtual-machines_examine-images-for-vulnerabilities

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/manage-vulnerabilities/common-vuln-management-tasks#viewing-view-vms-cves_vms

note to reviewers: Please focus on new sections. We had to fix some issues with modules/assemblies so that our files will pass new pre-migration checks that are being added to the repo in advance of our conversion to DITA and move to a new doc publishing program this year. These changes are included so that the PR will pass but do not affect the new material added to the docs.

QE review:

  • QE has approved this change.

Additional information:

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

openshift-ci-robot commented Feb 10, 2026

@kcarmichael08: This pull request references ROX-30241 which is a valid jira issue.

Details

In response to this:

Version(s): 4.10

Issue: ROX-30241

Link to docs preview:

New sections:

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/examine-images-for-vulnerabilities.html#scanning-virtual-machines_examine-images-for-vulnerabilities

https://106074--ocpdocs-pr.netlify.app/openshift-acs/latest/operating/manage-vulnerabilities/common-vuln-management-tasks#viewing-view-vms-cves_vms

note to reviewers: Please focus on new sections. We had to fix some issues with modules/assemblies so that our files will pass new pre-migration checks that are being added to the repo in advance of our conversion to DITA and move to a new doc publishing program this year. These changes are included so that the PR will pass but do not affect the new material added to the docs.

Focus on:

  • modules/configuring-vm-scanning.adoc
  • modules/deploy-roxagent.adoc
  • modules/scanning-vms.adoc
  • modules/troubleshooting-vm-scanning.adoc
  • modules/view-vms-cves.adoc
  • modules/vm-scanning-limitations.adoc
  • modules/vm-scanning-requirements.adoc
  • modules/vulnerability-management-components-portal.adoc

Ignore changes in:

  • architecture/acs-architecture.adoc‎
  • cloud_service/upgrading-cloud/upgrade-cloudsvc-roxctl.adoc‎
  • cloud_service/acscs-architecture.adoc
  • modules/about-vulnerabilities.adoc
  • modules/installing-scanner-slim-helm.adoc
  • modules/installing-scanner-slim-operator.adoc
  • modules/installing-scanner-slim.adoc
  • modules/scannerv4-enabling.adoc
  • modules/scanning-about.adoc
  • modules/setting-up-scanning.adoc
  • modules/using-image-scanning.adoc
  • modules/verifying-scanner-installation.adoc
  • operating/manage-vulnerabilities/common-vuln-management-tasks.adoc
  • operating/manage-vulnerabilities/scan-rhcos-node-host.adoc
  • operating/examine-images-for-vulnerabilities.adoc

QE review:

  • QE has approved this change.

Additional information:

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.

@kcarmichael08 kcarmichael08 force-pushed the ROX-30241-virt branch 3 times, most recently from 6288072 to e67e1e3 Compare February 10, 2026 13:51
* The Sensor deployment on your secured clusters
* Compliance container in the collector daemonset
.. Edit the ***?yaml file?*** to contain the following information:
//Need the filenames or some additional information here about where the environment variable would be located
Copy link
Contributor Author

@kcarmichael08 kcarmichael08 Feb 10, 2026

Choose a reason for hiding this comment

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

Can someone tell me the files that the user needs to specifically edit? Is it the Central and secured cluster CRs? What file needs to be edited in the "compliance container in the Collector daemonset"?

Copy link

Choose a reason for hiding this comment

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

This is about adding environment variables to the central pod - central container, sensor pod - sensor container, and collector pod - compliance container. I see there's already documentation on env vars here.

I am not sure what's the right way of presenting this to users. When I install manually using helm I use this:

--set customize.envVars.ROX_VIRTUAL_MACHINES=true

Copy link

Choose a reason for hiding this comment

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

By the way, I think when the original text mentions editing a file, it's the yaml manifest of an already running ACS (kubectl -n stackrox edit deployment central). I doubt that is what we need in this context.

@openshift-ci
Copy link

openshift-ci bot commented Feb 10, 2026

@kcarmichael08: all tests passed!

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.

* The Sensor deployment on your secured clusters
* Compliance container in the collector daemonset
.. Edit the ***?yaml file?*** to contain the following information:
//Need the filenames or some additional information here about where the environment variable would be located
Copy link

Choose a reason for hiding this comment

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

This is about adding environment variables to the central pod - central container, sensor pod - sensor container, and collector pod - compliance container. I see there's already documentation on env vars here.

I am not sure what's the right way of presenting this to users. When I install manually using helm I use this:

--set customize.envVars.ROX_VIRTUAL_MACHINES=true

* The Sensor deployment on your secured clusters
* Compliance container in the collector daemonset
.. Edit the ***?yaml file?*** to contain the following information:
//Need the filenames or some additional information here about where the environment variable would be located
Copy link

Choose a reason for hiding this comment

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

By the way, I think when the original text mentions editing a file, it's the yaml manifest of an already running ACS (kubectl -n stackrox edit deployment central). I doubt that is what we need in this context.

Comment on lines +50 to +52
. Optional: On the cluster where Central is installed, you can configure the following environment variables:
* ROX_VIRTUAL_MACHINES_VSOCK_PORT: Port for vsock connections. The default value is 818.
* ROX_VIRTUAL_MACHINES_VSOCK_CONN_MAX_SIZE_KB: Maximum connection size in KB. The default value is 16384.
Copy link

Choose a reason for hiding this comment

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

These are low-level settings that would only come into play in rather exotic scenarios. I think they would be a good fit in an "advanced configuration" section or similar, if we have one.

In any case, a fix is needed: instead of central, these settings need to be applied to the collector pod (compliance container), in secured clusters, much like ROX_VIRTUAL_MACHINES=true

Comment on lines +31 to +32
$ kubectl patch hyperconverged kubevirt-hyperconverged -n openshift-cnv --type='merge' \
--patch='{"spec":{"configuration":{"developerConfiguration":{"featureGates":["VSOCK"]}}}}'
Copy link

@guzalv guzalv Feb 12, 2026

Choose a reason for hiding this comment

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

This command seems not to work according to this user report. I have always used this myself:

cat << EOF | kubectl apply -f -
apiVersion: hco.kubevirt.io/v1beta1
kind: HyperConverged
metadata:
  name: kubevirt-hyperconverged
  namespace: openshift-cnv
  annotations:
    kubevirt.kubevirt.io/jsonpatch: |-
      [
        {
          "op":"add",
          "path":"/spec/configuration/developerConfiguration/featureGates/-",
          "value":"VSOCK"
        }
      ]
spec: {}
EOF

I asked AI for a kubectl patch equivalent, and it replied with this (unverified yet I just tried it and it works):

kubectl patch hyperconverged kubevirt-hyperconverged -n openshift-cnv --type=merge -p '
  {
    "metadata": {
      "annotations": {
        "kubevirt.kubevirt.io/jsonpatch": "[{\"op\":\"add\",\"path\":\"/spec/configuration/developerConfiguration/featureGates/-\",\"value\":\"VSOCK\"}]"
      }
    }
  }'

$ kubectl patch hyperconverged kubevirt-hyperconverged -n openshift-cnv --type='merge' \
--patch='{"spec":{"configuration":{"developerConfiguration":{"featureGates":["VSOCK"]}}}}'
----
* Use the following annotation:
Copy link

Choose a reason for hiding this comment

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

Should we somehow highlight that this is an alternative to the previous step? If not using the provided kubectl patch command, the user can edit the hyperconverged CR by any means (e.g. in the openshift UI, via k9s) to add that annotation manually.

The key in this section, what actually triggers vsock being enabled, is the presence of the annotation. How it's added is only important to help the user get there. Perhaps we could first show how it's supposed to look (this part) and then one of the methods to achieve it (the kubectl patch command)

* Only {op-system-base} packages indexed by DNF with valid repository links can be scanned.
* Scanning requires sudo privileges for `roxagent` to scan package databases.
* Only packages managed by Red Hat Package Manager (RPM) and DNF are detected.
* Network connectivity is required for repository-to-CPE mapping downloads.
Copy link

Choose a reason for hiding this comment

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

@stehessel , @vikin91 , I was suggesting here to explain that we require internet connectivity, but I am not sure: do we serve this from sensor today, so that users can set --repo-cpe-url to a sensor endpoint and it will work?

Suggested change
* Network connectivity is required for repository-to-CPE mapping downloads.
* Internet connectivity is required for repository-to-CPE mapping downloads.

** Verify the feature flag is enabled on all components.
** Check Central logs for enrichment processing.
** Ensure the VM has a valid {op-system-base} subscription.
** Confirm repository-to-CPE mapping downloads are successful.
Copy link

Choose a reason for hiding this comment

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

Do we think customers will know what this refers to, and how to check its success? IIUC the most obvious reason why this would fail is lack of connectivity to internet, and it would be visible in the logs: error updating mapping file

Copy link

Choose a reason for hiding this comment

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

The URL from where this file his downloaded can be configured via the --repo-cpe-url argument to roxagent. Not sure if that is relevant here or elsewhere!

** Ensure the VM has a valid {op-system-base} subscription.
** Confirm repository-to-CPE mapping downloads are successful.
* If there is a network connectivity problem:
** Verify the VM has internet access or connectivity to Sensor.
Copy link

@guzalv guzalv Feb 12, 2026

Choose a reason for hiding this comment

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

I guess this is related to the previous repository-to-CPE download. Let's double check (I asked experts in this comment) that sensor actually serves this file, otherwise we should remove the Sensor part.

= Requirements for virtual machine scanning

[role="_abstract"]
To use {product-title} ({product-title-short}) to scan virtual machines (VMs), you must ensure that they meet specific requirements.
Copy link

Choose a reason for hiding this comment

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

Since we're listing both k8s and VM requirements, we could change this:

Suggested change
To use {product-title} ({product-title-short}) to scan virtual machines (VMs), you must ensure that they meet specific requirements.
To use {product-title} ({product-title-short}) to scan virtual machines (VMs), you must ensure that the following requirements are met.

* VMs must have network access to download repository-to-Common Platform Enumeration (CPE) mappings.
* DNF must be installed.

For optimal performance, host VMs on metal nodes.
Copy link

Choose a reason for hiding this comment

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

Hosting VMs on metal nodes increases the performance of the VM itself, but makes little difference in the context the ACS VM feature: roxagent will run faster, but the difference between metal and non-metal is in the order of tens of seconds, while the default scan interval is 4 hours.

At ACS level, performance naturally relates to the number of VMs that it can handle, and this is constrained by CPU resources of Scanner V4, not the VM itself. What matters is that index reports arrive eventually from each VM.

I think I would rather remove this since VM performance does not relate to ACS performance and it may lead to questions like "can I scan more VMs if they run in metal nodes?"

@vikin91 , @stehessel , @kylape views/objections?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

jira/valid-reference Indicates that this PR references a valid Jira ticket of any type. size/XL Denotes a PR that changes 500-999 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants