36.9. A missing localhost entry causes virt-manager to fail

The virt-manager application may fail to launch and display an error such as “Unable to open a connection to the Xen hypervisor/daemon”. This is usually caused by a missing localhost entry in the /etc/hosts file. Verify that you indeed have a localhost entry and if it is missing from /etc/hosts and insert a new entry for localhost if it is not present. An incorrect /etc/hosts may resemble the following:
# Do not remove the following line, or various programs
# that require network functionality will fail.
localhost.localdomain localhost
The correct entry should look similar to the following:
# Do not remove the following line, or various programs
# that require network functionality will fail.
127.0.0.1               localhost.localdomain localhost
localhost.localdomain localhost
Red Hat logoGithubRedditYoutubeTwitter

Learn

Try, buy, & sell

Communities

About Red Hat Documentation

We help Red Hat users innovate and achieve their goals with our products and services with content they can trust.

Making open source more inclusive

Red Hat is committed to replacing problematic language in our code, documentation, and web properties. For more details, see the Red Hat Blog.

About Red Hat

We deliver hardened solutions that make it easier for enterprises to work across platforms and environments, from the core datacenter to the network edge.

© 2024 Red Hat, Inc.