Инструменты пользователя

Инструменты сайта


virt-manager:virt-manager

Virtual Machine Manager

The virt-manager application is a desktop user interface for managing virtual machines through libvirt. It primarily targets KVM VMs, but also manages Xen and LXC (linux containers). It presents a summary view of running domains, their live performance & resource utilization statistics. Wizards enable the creation of new domains, and configuration & adjustment of a domain’s resource allocation & virtual hardware. An embedded VNC and SPICE client viewer presents a full graphical console to the guest domain.

https://virt-manager.org/

FIXME

  • virt-install — is a command line tool which provides an easy way to provision operating systems into virtual machines.
  • virt-viewer — is a lightweight UI interface for interacting with the graphical display of virtualized guest OS. It can display VNC or SPICE, and uses libvirt to lookup the graphical connection details.
  • virt-clone — is a command line tool for cloning existing inactive guests. It copies the disk images, and defines a config with new name, UUID and MAC address pointing to the copied disks.
  • virt-xml — is a command line tool for easily editing libvirt domain XML using virt-install’s command line options.
  • virt-convert — is a command line tool for converting OVF and VMX VM configurations to run with libvirt.
  • virt-bootstrap — is a command tool providing an easy way to setup the root file system for libvirt-based containers.

Установка

apt install virt-manager

Для авторизации по SSH нужно дополнительно поставить пакет ssh-askpass

apt install ssh-askpass

Если на компьютере не предполагаться запускать виртуальные машины (компьютер администратора), то лучше отключить libvirt-guests

systemctl disable libvirt-guests

Чтобы избежать ошибок типа:

USB redirection error
spice-client-error-quark: Could not redirect
Error setting USB device node ACL: 'Not authorized' (0)

Для перенаправления USB нужно вызывать программу так:

sudo -E virt-manager

Подробнее здесь.

Сборка

FIXME

Для сборки из исходных текстов могут понадобится следующие пакеты:

apt install intltool libxml2-dev libgtk-3-dev libspice-client-gtk-3.0-dev libgtk-vnc-2.0-dev

Настройка

Пользователя который будет использовать программу нужно добавить в группу libvirt:

usermod --append --groups libvirt ПОЛЬЗОВАТЕЛЬ

Для авторизации по TLS нужно выполнить настройку, а для работы по SPICE нужно указать в настройках гостевого домена (виртуальной машины) в разделе Дисплей SPICE

  • в поле Тип: выбрать Сервер SPICE
  • в поле Адрес нужно выбрать нужный адрес
  • в поле Порт установить ✔ Auto
  • в поле Порт TLS установить ✔ Auto

Подключение:

qemu+tls://ИМЯ_СЕРВЕРА/system

virt-viewer

Установка

apt install virt-viewer

Варианты подключения:

  • qemu+tls:

    virt-viewer --connect qemu+tls://server/system vm

    где:

    • server — имя(адрес) сервера
    • vm — имя виртуальной машины
  • SPICE:

    virt-viewer --connect qemu+tls://server/system vm

    где:

    • server — имя(адрес) сервера
    • port — ноомер порта виртуальной машины

Ссылки

virt-manager/virt-manager.txt · Последние изменения: 2022-11-07 11:38 — GreyWolf