Bug 1983424 - [cnv 2.6.6] vm-import-controller pod CrashLoops indefinitely because of wrong API version for VirtualMachine
Summary: [cnv 2.6.6] vm-import-controller pod CrashLoops indefinitely because of wrong...
Keywords:
Status: CLOSED DUPLICATE of bug 1982760
Alias: None
Product: Container Native Virtualization (CNV)
Classification: Red Hat
Component: V2V
Version: 2.6.6
Hardware: Unspecified
OS: Unspecified
unspecified
urgent
Target Milestone: ---
: ---
Assignee: Fabien Dupont
QA Contact: Daniel Gur
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2021-07-18 12:51 UTC by Oren Cohen
Modified: 2021-09-08 10:39 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2021-07-19 11:48:26 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Oren Cohen 2021-07-18 12:51:51 UTC
Description of problem:
Upon Installation of CNV 2.6.6-43, or upgrade to that version, all pods are Running and Ready, except the vm-import-controller pod, which is failing and restarted in a loop.

Here is the relevant log of the pod:
{"level":"error","ts":1626611871.6030169,"logger":"controller-runtime.source","msg":"if kind is a CRD, it should be installed before calling Start","kind":"VirtualMachine.kubevirt.io","error":"no matches for kind \"VirtualMachine\" in version \"kubevirt.io/v1\"","stacktrace":"github.com/go-logr/zapr.(*zapLogger).Error\n\t/remote-source/app/vendor/github.com/go-logr/zapr/zapr.go:128\nsigs.k8s.io/controller-runtime/pkg/source.(*Kind).Start\n\t/remote-source/app/vendor/sigs.k8s.io/controller-runtime/pkg/source/source.go:117\nsigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start.func1\n\t/remote-source/app/vendor/sigs.k8s.io/controller-runtime/pkg/internal/controller/controller.go:140\nsigs.k8s.io/controller-runtime/pkg/internal/controller.(*Controller).Start\n\t/remote-source/app/vendor/sigs.k8s.io/controller-runtime/pkg/internal/controller/controller.go:175\nsigs.k8s.io/controller-runtime/pkg/manager.(*controllerManager).startRunnable.func1\n\t/remote-source/app/vendor/sigs.k8s.io/contro...
{"level":"error","ts":1626611871.603378,"logger":"cmd","msg":"Manager exited non-zero","error":"no matches for kind \"VirtualMachine\" in version \"kubevirt.io/v1\"","stacktrace":"github.com/go-logr/zapr.(*zapLogger).Error\n\t/remote-source/app/vendor/github.com/go-logr/zapr/zapr.go:128\nmain.main\n\t/remote-source/app/cmd/manager/main.go:159\nruntime.main\n\t/usr/lib/golang/src/runtime/proc.go:204"}


Version-Release number of selected component (if applicable):
CNV Bundle v2.6.6-43
vm-import-controller v2.6.6-3
IIB index image: registry-proxy.engineering.redhat.com/rh-osbs/iib:91026
Brew build info: https://brewweb.engineering.redhat.com/brew/buildinfo?buildID=1663446

How reproducible:
100%

Steps to Reproduce:
1. Deploy CNV of the mentioned version, or upgrade to it from a previous version (e.g. 2.6.5).
2. 
3.

Actual results:
virt-import-controller pod crashes because it watches the wrong API version of the resource "VirtualMachine". It looks for kubevirt.io/v1, while in 2.6, it is actually kubevirt.io/v1alpha3

Expected results:
This pod is not crashing, and the installation of CNV completed successfully.

Additional info:
Note:
You will not be able to reproduce this bug if CRDs from CNV 4.8 are deployed in the cluster beforehand. You should deploy it on a fresh cluster without any CRDs of kubevirt.io.

Comment 3 Daniel Gur 2021-07-19 11:48:26 UTC

*** This bug has been marked as a duplicate of bug 1982760 ***


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