Linux Based OS
Install Qemu Guest Agent
CentOS
yum install -y qemu-guest-agent
Ubuntu
apt install -y qemu-guest-agent
Debian
apt install -y qemu-guest-agent
AlmaLinux 8
dnf install -y qemu-guest-agent
RockyLinux 8
dnf install -y qemu-guest-agent
Then, start and ensure the service is persistent
systemctl enable –now qemu-guest-agent
Windows OS
Download these 2 installers in your Windows VM, and install
https://spice-space.org/download/windows/spice-guest-tools/spice-guest-tools-latest.exe
https://fedorapeople.org/groups/virt/virtio-win/direct-downloads/archive-qemu-ga/qemu-ga-win-102.10.0-0.el8_5/qemu-ga-x86_64.msi
the program will start automatically after installation