ConfigsApr 15, 2026·3 min read

KubeVirt — Run Virtual Machines on Kubernetes

KubeVirt extends Kubernetes with VM-native workloads. It lets you declare, schedule and manage traditional virtual machines as first-class Kubernetes objects alongside containers, sharing the same networking and storage.

TL;DR
KubeVirt lets you run traditional VMs alongside containers on the same Kubernetes cluster.
§01

What it is

KubeVirt is a Kubernetes extension that adds virtual machine workloads as first-class citizens to your cluster. Instead of choosing between containers and VMs, KubeVirt lets you run both side by side, sharing the same networking, storage, and scheduling infrastructure.

The project targets platform engineers managing hybrid workloads where some applications cannot be containerized yet. Legacy Windows apps, licensed software tied to specific OS images, and workloads requiring full kernel access are common use cases.

§02

How it saves time or tokens

Without KubeVirt, teams maintain separate infrastructure stacks for containers and VMs, doubling operational overhead. KubeVirt eliminates this split by letting you define VMs with the same kubectl commands and YAML manifests you already use for pods. One API, one control plane, one set of RBAC policies. Migration from standalone VMware or KVM setups becomes incremental rather than a big-bang rewrite.

§03

How to use

  1. Install the KubeVirt operator and custom resource on your cluster:
export VERSION=v1.3.0
kubectl apply -f https://github.com/kubevirt/kubevirt/releases/download/${VERSION}/kubevirt-operator.yaml
kubectl apply -f https://github.com/kubevirt/kubevirt/releases/download/${VERSION}/kubevirt-cr.yaml
  1. Create a VirtualMachine manifest and apply it:
apiVersion: kubevirt.io/v1
kind: VirtualMachine
metadata:
  name: demo
spec:
  running: true
  template:
    spec:
      domain:
        devices:
          disks:
            - name: disk0
              disk:
                bus: virtio
        resources:
          requests:
            memory: 512Mi
  1. Access the VM console with virtctl console demo.
§04

Example

# List running VMs
kubectl get vmi

# SSH into a VM via virtctl
virtctl ssh user@demo

# Live migrate a VM to another node
virtctl migrate demo

# Stop a VM
virtctl stop demo
§05

Related on TokRepo

§06

Common pitfalls

  • KubeVirt requires hardware virtualization support (Intel VT-x or AMD-V) on worker nodes; nested virtualization in cloud VMs adds latency
  • VM images stored as PVCs can be large; plan storage capacity and use CDI (Containerized Data Importer) for efficient image management
  • Network policies that work for pods may not cover VM traffic correctly; test VM-to-pod connectivity explicitly after setup

Frequently Asked Questions

Does KubeVirt replace VMware or KVM?+

KubeVirt does not replace the hypervisor layer. It uses libvirt and QEMU under the hood, running on top of KVM. What it replaces is the separate management plane. Instead of managing VMs through vCenter or virsh, you manage them through the Kubernetes API with kubectl and standard manifests.

Can I live-migrate VMs between nodes?+

Yes. KubeVirt supports live migration using the virtctl migrate command. The VM moves to another node without downtime, provided shared storage is configured and both nodes have compatible CPU features.

What storage backends work with KubeVirt?+

KubeVirt VMs use Kubernetes PersistentVolumeClaims for disk storage. Any CSI-compliant storage provider works, including Ceph, Longhorn, local-path, and cloud provider block storage. The Containerized Data Importer (CDI) handles importing disk images into PVCs.

How does networking work for KubeVirt VMs?+

By default, VMs connect to the same pod network as containers using a bridge or masquerade binding. For advanced use cases like SR-IOV passthrough or multiple NICs, Multus CNI can be configured to attach VMs to additional networks.

Is KubeVirt production-ready?+

KubeVirt is a CNCF incubating project used in production by organizations running hybrid container-VM workloads. Red Hat OpenShift Virtualization is built on KubeVirt, which provides commercial support and validation at scale.

Citations (3)

Discussion

Sign in to join the discussion.
No comments yet. Be the first to share your thoughts.

Related Assets