Ubuntu Server installation is pretty straightforward , then connect via ssh to server instance and install Gnome 45 desktop environment via command $ sudo apt install ubuntu-gnome-desktop. Reboot Ubuntu Server's instance and log into newly installed Gnome 45 environment. Now you are ready to proceed with KVM setup on Ubuntu 23.10
[boris@ServerFedora38 ~]$ ssh boris@192.168.0.53
boris@192.168.0.53's password:
Welcome to Ubuntu 23.10 (GNU/Linux 6.5.0-9-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
System information as of Sat Oct 14 10:03:45 AM UTC 2023
System load: 0.0 Processes: 315
Usage of /home: 20.3% of 12.00GB Users logged in: 1
Memory usage: 8% IPv4 address for br0: 192.168.0.53
Swap usage: 0%
* Strictly confined Kubernetes makes edge and IoT secure. Learn how MicroK8s
just raised the bar for easy, resilient and secure K8s cluster deployment.
https://ubuntu.com/engage/secure-kubernetes-at-the-edge
0 updates can be applied immediately.
Last login: Fri Oct 13 09:10:53 2023 from 192.168.0.18
boris@mantic-server2310:~$ uname -a
Linux mantic-server2310 6.5.0-9-generic #9-Ubuntu SMP PREEMPT_DYNAMIC Sat Oct 7 01:35:40 UTC 2023 x86_64 x86_64 x86_64 GNU/Linux
boris@mantic-server2310:~$ sudo apt -y install qemu-kvm libvirt-daemon-system libvirt-daemon virtinst bridge-utils libosinfo-bin virt-manager virt-viewer
Reading package lists... Done
Building dependency tree... Done
Reading state information... Done
Note, selecting 'qemu-system-x86' instead of 'qemu-kvm'
The following additional packages will be installed:
acl cpu-checker gir1.2-atk-1.0 gir1.2-ayatanaappindicator3-0.1 gir1.2-freedesktop
gir1.2-gdkpixbuf-2.0 gir1.2-gstreamer-1.0 gir1.2-gtk-3.0 gir1.2-gtk-vnc-2.0
gir1.2-gtksource-4 gir1.2-harfbuzz-0.0 gir1.2-libosinfo-1.0 gir1.2-libvirt-glib-1.0
gir1.2-pango-1.0 gir1.2-spiceclientglib-2.0 gir1.2-spiceclientgtk-3.0 gir1.2-vte-2.91
gstreamer1.0-plugins-good gstreamer1.0-x ibverbs-providers ipxe-qemu
. . . . . .
Processing triggers for shared-mime-info (2.2-1) ...
Processing triggers for install-info (7.0.3-2) ...
Processing triggers for hicolor-icon-theme (0.17-2) ...
Scanning processes...
Scanning linux images...
Running kernel seems to be up-to-date.
No services need to be restarted.
No containers need to be restarted.
No user sessions are running outdated binaries.
No VM guests are running outdated hypervisor (qemu) binaries on this host.
boris@mantic-server2310:~$ sudo systemctl start libvirtd
boris@mantic-server2310:~$ sudo systemctl status libvirtd
● libvirtd.service - Virtualization daemon
Loaded: loaded (/lib/systemd/system/libvirtd.service; enabled; preset: enabled)
Active: active (running) since Sat 2023-10-14 09:19:45 UTC; 36s ago
TriggeredBy: ● libvirtd-ro.socket
● libvirtd-admin.socket
● libvirtd.socket
Docs: man:libvirtd(8)
https://libvirt.org
Main PID: 5114 (libvirtd)
Tasks: 22 (limit: 32768)
Memory: 9.4M
CPU: 345ms
CGroup: /system.slice/libvirtd.service
├─5114 /usr/sbin/libvirtd --timeout 120
├─5220 /usr/sbin/dnsmasq --conf-file=/var/lib/libvirt/dnsmasq/default.conf --leasef>
└─5221 /usr/sbin/dnsmasq --conf-file=/var/lib/libvirt/dnsmasq/default.conf --leasef>
Oct 14 09:19:45 mantic-server2310 systemd[1]: Started libvirtd.service - Virtualization daemon.
Oct 14 09:19:46 mantic-server2310 dnsmasq[5220]: started, version 2.89 cachesize 150
Oct 14 09:19:46 mantic-server2310 dnsmasq[5220]: compile time options: IPv6 GNU-getopt DBus no-UBus>
Oct 14 09:19:46 mantic-server2310 dnsmasq-dhcp[5220]: DHCP, IP range 192.168.122.2 -- 192.168.122.2>
Oct 14 09:19:46 mantic-server2310 dnsmasq-dhcp[5220]: DHCP, sockets bound exclusively to interface >
Oct 14 09:19:46 mantic-server2310 dnsmasq[5220]: reading /etc/resolv.conf
Oct 14 09:19:46 mantic-server2310 dnsmasq[5220]: using nameserver 127.0.0.53#53
Oct 14 09:19:46 mantic-server2310 dnsmasq[5220]: read /etc/hosts - 8 names
Oct 14 09:19:46 mantic-server2310 dnsmasq[5220]: read /var/lib/libvirt/dnsmasq/default.addnhosts - >
Oct 14 09:19:46 mantic-server2310 dnsmasq-dhcp[5220]: read /var/lib/libvirt/dnsmasq/default.hostsfi>
boris@mantic-server2310:~$ sudo systemctl enable libvirtd
boris@mantic-server2310:~$ sudo usermod -aG kvm $USER
boris@mantic-server2310:~$ sudo usermod -aG libvirt $USER
Now create file /etc/netplan/01-netcfg.yaml
boris@mantic-server2310:~$ cat /etc/netplan/01-netcfg.yaml
network:
ethernets:
enp1s0:
dhcp4: false
dhcp6: false
# add configuration for bridge interface
bridges:
br0:
interfaces: [enp1s0]
dhcp4: false
addresses: [192.168.0.53/24]
macaddress: 52:54:00:cc:d9:c6
routes:
- to: default
via: 192.168.0.1
metric: 100
nameservers:
addresses: [8.8.8.8]
parameters:
stp: false
dhcp6: false
version: 2
When done issue command
boris@mantic-server2310:~$ sudo netplan apply
and make sure that bridge br0 has been configured
boris@mantic-server2310:~$ ip a
1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
inet 127.0.0.1/8 scope host lo
valid_lft forever preferred_lft forever
inet6 ::1/128 scope host
valid_lft forever preferred_lft forever
2: enp1s0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast master br0 state UP group default qlen 1000
link/ether 52:54:00:cc:d9:c6 brd ff:ff:ff:ff:ff:ff
3: virbr0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default qlen 1000
link/ether 52:54:00:3c:43:13 brd ff:ff:ff:ff:ff:ff
inet 192.168.122.1/24 brd 192.168.122.255 scope global virbr0
valid_lft forever preferred_lft forever
4: br0: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default qlen 1000
link/ether 52:54:00:cc:d9:c6 brd ff:ff:ff:ff:ff:ff
inet 192.168.0.53/24 brd 192.168.0.255 scope global br0
valid_lft forever preferred_lft forever
inet6 fe80::5054:ff:fecc:d9c6/64 scope link
valid_lft forever preferred_lft forever
No comments:
Post a Comment