Bug 2151053 - The scripts tab of Windows VM cannot be saved
Summary: The scripts tab of Windows VM cannot be saved
Keywords:
Status: CLOSED ERRATA
Alias: None
Product: Container Native Virtualization (CNV)
Classification: Red Hat
Component: User Experience
Version: 4.12.0
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: ---
: 4.13.0
Assignee: Ugo Palatucci
QA Contact: Guohua Ouyang
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2022-12-06 01:10 UTC by Guohua Ouyang
Modified: 2023-05-18 02:56 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2023-05-18 02:56:16 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)
cloud-init cannot be saved (196.43 KB, image/png)
2022-12-06 01:10 UTC, Guohua Ouyang
no flags Details


Links
System ID Private Priority Status Summary Last Updated
Github kubevirt-ui kubevirt-plugin pull 1091 0 None open Bug 2151053: Cloud init fix 2023-03-01 14:14:40 UTC
Red Hat Issue Tracker CNV-23144 0 None None None 2022-12-06 01:14:03 UTC
Red Hat Product Errata RHSA-2023:3205 0 None None None 2023-05-18 02:56:27 UTC

Description Guohua Ouyang 2022-12-06 01:10:03 UTC
Created attachment 1930316 [details]
cloud-init cannot be saved

Description of problem:
The scripts tab of Windows VM cannot be saved, the error for cloud-init is:
Error "spec.template.spec.volumes[2] must have exactly one source type set" for field "spec.template.spec.volumes[2]". 

The error for Authorized SSH Key is:
Error "spec.template.spec.accessCredentials[0] requires a configDrive volume to exist when the configDrive propagationMethod is in use." for field "spec.template.spec.accessCredentials[0].sshPublicKey.propagationMethod".

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
1. edit clout-init and ssh-key of a windows VM
2.
3.

Actual results:
the page cannot be save

Expected results:
it can save

Additional info:
The issue does not happen for sysprep

Comment 2 Ugo Palatucci 2023-03-01 14:11:50 UTC
Authorized SSH Key is probably already solved.
Not reproducible.

Fixing only for cloud-init

@gouyang

Comment 3 Guohua Ouyang 2023-03-02 01:55:17 UTC
I could still see the ssh error while adding a new secret or attaching existing secret to a windows VM.

Comment 4 Guohua Ouyang 2023-03-02 23:21:58 UTC
Hi Ugo, 
Could you check the Authorized SSH Key issue on windows VM again?

Comment 5 Ugo Palatucci 2023-03-03 13:37:15 UTC
Yes. I don't know what happened before. Now I'm able to reproduce the error

Comment 6 Ugo Palatucci 2023-03-03 13:44:44 UTC
Okay, now I understand the issue. 
On windows, we don't have cloud-init info by default, but to add the Auth SSH Key we need some kind of cloudInitConfigDrive information.

Does it make sense to do this? In another bug[1] we are adding labels for 'Linux only' and 'Windows only'
Probably i can resolve this bug by disabling the configuration of Auth SSH key for windows. 
WDYT? 

1. https://bugzilla.redhat.com/show_bug.cgi?id=2155403

@gouyang

Comment 7 Guohua Ouyang 2023-03-06 00:39:39 UTC
(In reply to Ugo Palatucci from comment #6)
> Okay, now I understand the issue. 
> On windows, we don't have cloud-init info by default, but to add the Auth
> SSH Key we need some kind of cloudInitConfigDrive information.
> 
> Does it make sense to do this? In another bug[1] we are adding labels for
> 'Linux only' and 'Windows only'
> Probably i can resolve this bug by disabling the configuration of Auth SSH
> key for windows. 
> WDYT? 
> 
> 1. https://bugzilla.redhat.com/show_bug.cgi?id=2155403
> 
> @gouyang


I'd love to see Syspre is only enabled for windows and SSH Key only enabled for Linux.

Comment 8 Guohua Ouyang 2023-03-06 01:59:18 UTC
Move the bug to verified and track the windows ssh key issue in #2155403

Comment 11 errata-xmlrpc 2023-05-18 02:56:16 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: OpenShift Virtualization 4.13.0 Images security, bug fix, and enhancement update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2023:3205


Note You need to log in before you can comment on or make changes to this bug.