libvirtd — Libvirt Daemon (Legacy Central Virtualization Daemon)
Overview
libvirtd
is the system daemon for libvirt, responsible for managing virtualization hosts and hypervisors (e.g., QEMU/KVM, Xen, LXC). It exposes a high-level API and remote protocol to control and automate virtual machines, networks, storage, and more.
Deprecated: As of libvirt 9.0 (2023), libvirtd
is deprecated and has been split into modular daemons like:
virtqemud
virtlogd
virtproxyd
virtnetworkd
, etc.
But it’s still widely used in existing Linux distributions.
Responsibilities of libvirtd
libvirtd
Hypervisor Integration
Interacts with QEMU, KVM, LXC, Xen, etc. via driver plugins.
VM Lifecycle Management
Start, stop, pause, resume, reboot, and destroy virtual machines.
Storage Management
Create/delete volumes and pools, attach storage.
Network Management
Set up virtual NAT, bridges, and isolated networks.
Security
Applies SELinux, AppArmor, sVirt isolation rules.
Remote Access
Exposes TCP/TLS/SSH sockets for remote control (qemu+ssh
, etc.).
Authentication
Supports UNIX sockets, SASL, TLS certificates for secure access.
Service and Socket Management
Systemd Units
Also includes:
Configuration Files
/etc/libvirt/libvirtd.conf
Core daemon settings (logging, sockets, etc.)
/etc/sysconfig/libvirtd
(RPM)
Environment variables for daemon (old distros)
/etc/libvirt/qemu.conf
QEMU/KVM specific settings
Key libvirtd.conf
Options
libvirtd.conf
OptionsUse virt-manager
, virsh
, or custom clients to interact with libvirtd
.
Logging and Debugging
Enable debug mode:
Or increase verbosity in /etc/libvirt/libvirtd.conf
:
Then:
Replacement in Modern Setups
Old (libvirtd
)
New (modular daemons)
libvirtd
virtqemud
, virtlogd
, virtproxyd
, etc.
/var/run/libvirtd/
/run/libvirt/qemu/
, /run/libvirt/virtqemud/
You can switch to modular mode by stopping libvirtd
and enabling individual daemons:
Remote Access
Enable remote TCP/TLS connections:
In
/etc/libvirt/libvirtd.conf
:
In
/etc/default/libvirtd
or systemd override:
Then:
Connect using:
Summary
libvirtd
Main legacy libvirt daemon
Manages
VMs, networks, storage, hypervisor APIs
Interface
Sockets (UNIX/TCP), RPC protocol
Security
SELinux, TLS, SASL, UNIX auth
Status
Deprecated in favor of modular daemons
Let me know if you'd like a guide to migrating from libvirtd
to modular daemons, configuring remote access securely, or benchmarking libvirt vs. competitors like virt-manager
, cockpit
, xen-tools
, or VBoxManage
.
Last updated