diff options
Diffstat (limited to 'content/articles/instalar-un-gestor-de-maquinas-virtuales-en-hyperbola-gnulinux-libre.en.md')
-rw-r--r-- | content/articles/instalar-un-gestor-de-maquinas-virtuales-en-hyperbola-gnulinux-libre.en.md | 102 |
1 files changed, 53 insertions, 49 deletions
diff --git a/content/articles/instalar-un-gestor-de-maquinas-virtuales-en-hyperbola-gnulinux-libre.en.md b/content/articles/instalar-un-gestor-de-maquinas-virtuales-en-hyperbola-gnulinux-libre.en.md index ec43b41..28a6193 100644 --- a/content/articles/instalar-un-gestor-de-maquinas-virtuales-en-hyperbola-gnulinux-libre.en.md +++ b/content/articles/instalar-un-gestor-de-maquinas-virtuales-en-hyperbola-gnulinux-libre.en.md @@ -31,14 +31,9 @@ In totally free operating systems there is a program called `qemu` that allows us to virtualize. [Qemu][qemu]{:target="_blank" rel="noopener noreferrer"} -works through the command line, but there are -also GUIs. +works through the command line. -In this guide we explain how to install -[Virtual Machine Manager][vm]{:target="_blank" rel="noopener noreferrer"} -which is very complete when virtualizing operating systems. - -## Virtual Machine Manager installation +## Enable virtualization ### Check if your PC supports virtualization @@ -54,24 +49,15 @@ If your computer supports virtualization, you should see the output as `Virtualization: VT-x` or `Virtualization: AMD-V`, otherwise your computer is not capable of virtualizing. -### Virtual Machine Manager Installing +### Qemu Installing :::console # pacman -Sy - # pacman -S virt-manager qemu vde2 dnsmasq bridge-utils libvirt + # pacman -S qemu vde2 dnsmasq bridge-utils # gpasswd -a <your-user> kvm - # gpasswd -a <your-user> libvirt - -### Check kvm group - - :::console - # grep -E 'group="kvm"|group="78"' /etc/libvirt/qemu.conf - -Check if there is `group="kvm"` or `group="78"` - ### Enable kernel modules for virtualization - kvm_intel module (Intel processors) @@ -84,35 +70,6 @@ Check if there is `group="kvm"` or `group="78"` :::console # modprobe kvm_amd -### Verify that the virtual machine is configured correctly - - :::console - $ virt-host-validate - -### Services - -Virt-Manager relies on `libvirtd` services to function. - -Here we explain how to start these service: - -#### Start libvirtd - - :::console - # rc-service libvirtd start - -#### Add libvirtd for default - - :::console - # rc-update add libvirtd default - -#### Remove Service - -If you want to remove the service and start -only when you want, run: - - :::console - # rc-update del libvirtd default - ### Enable nested virtualization in KVM Nested virtualization allows you to run a virtual machine (VM) @@ -175,6 +132,55 @@ For example: ---------------------------------- options kvm_intel nested=1 +## Qemu usage + +Make virtual disk to use Virtual Machine. + + :::console + $ qemu-img create hyper.qcow2 10G + +### Simple usage + + :::bash + #!/bin/bash + qemu-system-x86_64 \ + -monitor stdio \ + --enable-kvm -m 512 \ + -cdrom $HOME/Descargas/hyperbola-milky-way-v0.4-dual.iso \ + -drive file=$HOME/Descargas/hyper.qcow2,if=virtio \ + -boot c -rtc base=localtime \ + -device virtio-keyboard-pci \ + -net nic -net user \ + -vga virtio + +`-net user` is important to have internet access within your new system. +`-m 512` is the set virtual RAM size (megabytes), default is 128 MB, +I chose 512 + +### Qemu + VNC as server + + :::bash + #!/bin/bash + qemu-system-x86_64 \ + -monitor stdio \ + --enable-kvm -m 512 \ + -cdrom /path/to/hyperbola-milky-way-v0.4-dual.iso \ + -drive file=/path/to/hyper.qcow2,if=virtio \ + -boot c -rtc base=localtime \ + -device virtio-keyboard-pci \ + -net nic -net user \ + -vga virtio \ + -display none \ + -vnc :0 + +One can add the -vnc :X option to have QEMU redirect the VGA display to +the VNC session. Substitute X for the number of the display (0 will +then listen on 5900, 1 on 5901, 2 on 5902, etc). + +>Warning: The default VNC server setup does not use any form of +>authentication. Any user can connect from any host. +> Maybe check: https://wiki.archlinux.org/title/QEMU#Basic_password_authentication + ### Virtual Machine Manager screenshots <figure> @@ -209,5 +215,3 @@ this module comes disabled. [trisquel]: https://trisquel.info [qemu]: https://wiki.qemu.org/Main_Page [spectre]: https://www.kernel.org/doc/html/latest/admin-guide/hw-vuln/l1tf.html -[vm]: https://virt-manager.org/ -*[GUI]: Graphical user interface |