Skip to main content

Posts

Showing posts with the label KVM

OLVM Backup and Restore

Oracle Linux Virtualization Manager (OLVM) is a powerful virtualization platform based on oVirt. Ensuring consistent backups of the OLVM environment is critical for disaster recovery and business continuity. The backup process primarily includes the engine database, configuration files, and optionally VM disk images (data domains).  Backup the OLVM Engine Database:  Use the engine-backup utility to back up the manager database and configuration. engine-backup --mode=backup \ --file=/backup/olvm_engine_backup.tar \ --log=/backup/olvm_backup.log \ --scope=all --scope=all ensures both the engine DB and configuration files are included.  Backup should be run on the OLVM manager node. Backup Data Domains (VM disks):  Use storage-level tools or snapshot methods to back up virtual machine disks.  For iSCSI/NFS domains:  Use storage-side snapshots or backup tools like rsync or tar. For GlusterFS:  Use Gluster snapshots or native backup solutions....

Oracle KVM Cluster Configuration using Command Line

Introduction to Oracle KVM Cluster Oracle KVM Cluster is an enterprise-grade virtualization solution that leverages the Kernel-based Virtual Machine (KVM) hypervisor, integrated within Oracle Linux. It enables the creation and management of clustered virtual environments, providing high availability, scalability, and centralized management for virtual machines across multiple physical hosts. By combining the performance and efficiency of KVM with Oracle's robust clustering and management tools—such as Oracle Linux Virtualization Manager (OLVM) and Oracle Clusterware—Oracle KVM Cluster supports mission-critical workloads with features like live migration, fault tolerance, and resource pooling. This makes it an ideal platform for consolidating workloads, optimizing resource utilization, and ensuring business continuity in modern data centers.   In this blogpost we will see how we can configure the KVM cluster using the command Line options: Creating an Oracle KVM cluster from...

Automate VLAN tagging on KVM using Ansible

 This blogpost will provide details and steps for  automating VLAN-tagged bridge setup on a KVM host using Ansible , and then optionally connect it to OLVM if needed. Use Ansible to: Create a VLAN sub-interface on a physical NIC. Create a Linux bridge attached to that VLAN interface. Ensure the bridge is ready to be used by VMs or OLVM. Prerequisites Ansible installed on a control node. SSH access to the KVM host(s). nmcli or network role availability (for Red Hat-based distros). Ansible Playbook Example Directory Structure: vlan-bridge-setup/ ├── inventory └── vlan_bridge.yml inventory: [kvmhosts] 192.168.125.100 ansible_user=root vlan_bridge.yml: - name: Configure VLAN tagged bridge on KVM host   hosts: kvmhosts   become: yes   tasks:     - name: Create VLAN interface eth0.100       nmcli:         conn_name: vlan100         ifname: eth0         type: vla...

KVM Virtual machines not starting on Exadata

 Exadata KVM virtual machines not starting   We have a customer where all KVM machines were not starting.  The machines is encountering the following error during startup:   [root@dbnode1 ~]# virsh start dbnode1 error: Failed to start domain dbnode1 error: internal error: process exited while connecting to monitor: 2024-04-27Tqemu-system-x86_64: -blockdev {"driver":"file","filename":"/EXAVMIMAGES/GuestImages/hostname.com/System.img","node-name":"libvirt-9-storage","cache":{"direct":false,"no-flush":false},"auto-read-only":true,"discard":"unmap"}: Could not open '/EXAVMIMAGES/GuestImages/hostname.com/System.img': Permission denied   Cause: Due to the installation of some third-party security components libvirtd package and its libraries were not functioning properly.   Solution: Rsinstall the libvirtd package Update file:  /etc/libvirt/q...

Oracle KVM on Linux 9 with Kernel Error

KVM Virtual machine errored with following Error. Issue: When we were trying to install the guest packages then the VM hosted with OEL9 KVM crashed with the following Error.   Wed Apr 17 16:03:45 GMT 2024 [ 5.310837] x86/mm: Checked W+X mappings:passed, no W+X pages found. Wed Apr 17 16:03:45 GMT 2024 [ 5.312259] Run /init as init process Wed Apr 17 16:03:45 GMT 2024 Fatal glibc error: CPU does not supportx86-64-v2 Wed Apr 17 16:03:45 GMT 2024 [ 5.314075] Kernel panic - not syncing:Attempted to kill init! exitcode=0x00007f00 Wed Apr 17 16:03:45 GMT 2024 [ 5.315686] CPU: 1 PID: 1 Comm: init Not tainted5.14.0-70.5.1.el9_0.x86_64 #1 Wed Apr 17 16:03:45 GMT 2024 [ 5.317214] Hardware name: QEMU Standard PC (Q35+ ICH9, 2009)   Cause: The installed glibc version of the operating system doesn’t set the CPU flags correctly in  the VM configuration.   Solution: As a workaround use the following commands:   #virsh edit vm-name   Then, add...

Oracle KVM qemu-kvm: unable to map backing store for guest RAM: Cannot allocate memory"

 Oracle KVM Service fails to start with following error: #virsh start db-node1 error: Failed to start domain 'db-node1' error: internal error: QEMU unexpectedly closed the monitor (vm='db-node1'): 2024-04-08Tqemu-kvm: unable to map backing store for guest RAM: Cannot allocate memory   This issue is happening due to the wrong version of the packages:   # rpm -qa | grep qemu qemu-img-8.0.0-16.el9_3.1.x86_64 libvirt-daemon-driver-qemu-9.5.0-7.0.1.el9_3.x86_64 qemu-kvm-tools-8.0.0-16.el9_3.1.x86_64 qemu-pr-helper-8.0.0-16.el9_3.1.x86_64 qemu-kvm-docs-8.0.0-16.el9_3.1.x86_64 ipxe-roms-qemu-20200823-9.git4bd064de.el9_0.noarch qemu-kvm-common-8.0.0-16.el9_3.1.x86_64 qemu-kvm-device-display-virtio-gpu-8.0.0-16.el9_3.1.x86_64 qemu-kvm-ui-opengl-8.0.0-16.el9_3.1.x86_64 qemu-kvm-ui-egl-headless-8.0.0-16.el9_3.1.x86_64 qemu-kvm-device-display-virtio-gpu-pci-8.0.0-16.el9_3.1.x86_64 qemu-kvm-block-blkio-8.0.0-16.el9_3.1.x86_64 qemu-kvm-block-rbd-8.0.0-16.el9_3.1.x86_64 qemu-kvm-devic...

Oracle Linux 9 Virtaul machine not bootable in KVM after Clone

In one of our customer Environments we cloned virtual machine using the disk and post clone completion virtual machine not booted up. The following Error occurred while booting up the VM. [ TIME ] Timed out waiting for device /dev/mapper/vg_rootdisk-volume. [DEPEND] Dependency failed for /filesystem [DEPEND] Dependency failed for D-Bus System Message Bus. Problem: File /etc/lvm/devices/system.devices configured with the disk_id of the OLVM disk image. If the VM is cloned the new VM will be on a new image with a different disk_id and that will prevent LVM from finding the logical volumes and hence its not able to boot the VM. Solution: Eidt /etc/lvm/devices/system.devices configuration file before creating the clone or copy. Change from IDTYPE=sys_serial and IDNAME= : # LVM uses devices listed in this file. # Created by LVM command lvmdevices pid 3503 at Jan 13 23:11:07 2024 VERSION=1.1.4 IDTYPE=sys_serial IDNAME=ad1a270f-10e9-41dc-a313-988d07e6b447 DEVNAME=/dev/sda2 PVID=...

OLVM: Find virtual disk path attached to VM

 This blogpost will guide you to find out the virtual disk path attached to a virtual machine. - Login to the admin console - Navigate to > Storage > Disk - Click on Disk to copy the ID of the disk. - Now Login to the Any KVM host from command line and use below command to know the exact physical location of the virtual disk. This will give you the details of the file location with storage domain. thanks for reading  :) regards, zaheer

OLVM : Error to uplaod iso image (ovirtsdk4.Error: Error while sending HTTP request:)

 In one of our customer environment we were trying to upload the iso image on KVM storage domain, but when we were trying to upload the image we encountered following error: [root@oraovm REST]# python upload_to_storagedomain.py -l oraovm -u admin@internal -c /etc/pki/ovirt-engine/ca.pem --sdd-name NFS-ISO-DATA -t ISO /home/os_files/SW_DVD9_Win_Server_CORE_2016_64Bit.iso Enter engine Login password:- Creating disk... Traceback (most recent call last): File "upload_to_storagedomain.py", line 179, in main() File "upload_to_storagedomain.py", line 117, in main disk = create_disk() File "upload_to_storagedomain.py", line 101, in create_disk name = arg.sdd_name File "/usr/lib64/python2.7/site-packages/ovirtsdk4/services.py", line 7074, in add return self._internal_add(disk, headers, query, wait) File "/usr/lib64/python2.7/site-packages/ovirtsdk4/service.py", line 223, in _internal_add context = self._connection...