- 1 year ago
How do I start libvirtd in WSL2
Comment
1 / 1
To start libvirtd
in WSL2, you need to follow these steps:
- First, make sure that you have installed
libvirt
andqemu-kvm
packages in WSL2 by running the following command:
sqlsudo apt-get install libvirt-daemon-system qemu-kvm
- Next, start the
libvirtd
service by running the following command:
sqlsudo systemctl start libvirtd
- You can check the status of the
libvirtd
service by running the following command:
luasudo systemctl status libvirtd
If the service is running, you should see a message indicating that it is active.
- Finally, you may need to add your user account to the
libvirt
group to allow it to manage virtual machines. You can do this by running the following command:
phpsudo usermod -aG libvirt <username>
Replace <username>
with your actual username.
After following these steps, you should be able to use libvirt
and qemu-kvm
in WSL2 to manage virtual machines.