Re: KVM Testbed setup bring up

14 views
Skip to first unread message

krishna bansal

unread,
May 21, 2024, 3:04:21 AMMay 21
to sonicproject
Hi Team,

I am using ubuntu 20.04
:~/veos-vm/images$ lsb_release -a
 No LSB modules are available.
Distributor ID: Ubuntu
Description: Ubuntu 20.04.6 LTS
Release: 20.04 Codename: focal

I am trying to create a T0 toplogy: https://github.com/sonic-net/sonic-mgmt/blob/master/docs/testbed/README.testbed.VsSetup.md#setup-vms-on-the-server using this link.

Facing issue while running the Setup VMs on the server.

below errors:

TASK [vm_set : Define vm VM0100] *********************************************************************************************
Tuesday 21 May 2024  06:32:28 +0000 (0:00:14.681)       0:01:20.155 ***********
An exception occurred during task execution. To see the full traceback, use -vvv. The error was: AttributeError: 'libvirtError' object has no attribute 'message'
<172.17.0.1> Failed to connect to the host via ssh: libvirt: QEMU Driver error : unsupported configuration: Emulator '/usr/bin/qemu-system-x86_64' does not support virt type 'kvm' <stdin>:18: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses The full traceback is: Traceback (most recent call last): File "/tmp/ansible_virt_payload_8g451wqh/__main__.py", line 542, in core domain = v.define(xml) File "/tmp/ansible_virt_payload_8g451wqh/__main__.py", line 455, in define return self.conn.define_from_xml(xml) File "/tmp/ansible_virt_payload_8g451wqh/__main__.py", line 284, in define_from_xml return self.conn.defineXML(xml) File "/usr/lib/python3/dist-packages/libvirt.py", line 4047, in defineXML if ret is None:raise libvirtError('virDomainDefineXML() failed', conn=self) libvirt.libvirtError: unsupported configuration: Emulator '/usr/bin/qemu-system-x86_64' does not support virt type 'kvm'``` During handling of the above exception, another exception occurred: ```Traceback (most recent call last): File "/tmp/ansible_virt_payload_8g451wqh/__main__.py", line 593, in main rc, result = core(module) File "/tmp/ansible_virt_payload_8g451wqh/__main__.py", line 551, in core module.fail_json(msg='libvirtError: %s' % e.message) AttributeError: 'libvirtError' object has no attribute 'message'```   
[WARNING]: 'xml' is given - ignoring 'name'

fatal: [STR-ACS-VSERV-01]: FAILED! => {"changed": false, "msg": "'libvirtError' object has no attribute 'message'"}

PLAY RECAP *******************************************************************************************************************
STR-ACS-VSERV-01           : ok=61   changed=4    unreachable=0    failed=1    skipped=45   rescued=0    ignored=0

Tuesday 21 May 2024  06:32:30 +0000 (0:00:02.599)       0:01:22.755 ***********
===============================================================================
vm_set : Copy veos disk image for VM0100 ----------------------------------------------------------------------------- 14.68s
vm_set : Run the "apt-get update" as a separate and retryable step --------------------------------------------------- 13.06s
vm_set : Install python packages -------------------------------------------------------------------------------------- 6.70s
vm_set : remove old python packages ----------------------------------------------------------------------------------- 3.03s
vm_set : Create VMs network ------------------------------------------------------------------------------------------- 2.97s
vm_set : Install necessary packages ----------------------------------------------------------------------------------- 2.83s
vm_set : Add docker official GPG key ---------------------------------------------------------------------------------- 2.80s
vm_set : Define vm VM0100 --------------------------------------------------------------------------------------------- 2.60s
vm_set : Check hdd image ---------------------------------------------------------------------------------------------- 2.52s
vm_set : remove old python packages ----------------------------------------------------------------------------------- 2.19s
vm_set : Install necessary packages ----------------------------------------------------------------------------------- 1.98s
vm_set : Install docker-ce -------------------------------------------------------------------------------------------- 1.89s
vm_set : Install necessary packages ----------------------------------------------------------------------------------- 1.88s
vm_set : Set sysctl bridge parameters for testbed --------------------------------------------------------------------- 1.85s
vm_set : get host distribution ---------------------------------------------------------------------------------------- 1.62s
vm_set : Copy vm_resumer.py to the /home/krishna/veos-vm -------------------------------------------------------------- 1.57s
vm_set : Install cleanup script --------------------------------------------------------------------------------------- 1.45s
vm_set : Retrieve a list of the defined VMs --------------------------------------------------------------------------- 1.17s
vm_set : Create directory for vm images and vm disks ------------------------------------------------------------------ 1.00s
vm_set : Check docker repository -------------------------------------------------------------------------------------- 0.93s

Kindly let me know how i can able to fix this.

Regards,

Reply all
Reply to author
Forward
0 new messages