all messages for Guix-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* Cannot run virt-manager as my user
@ 2023-05-29  2:35 Robby Zambito
  2023-05-29  4:40 ` Ruijie Yu via
  0 siblings, 1 reply; 5+ messages in thread
From: Robby Zambito @ 2023-05-29  2:35 UTC (permalink / raw)
  To: help-guix

Hi,

I am trying to set up virt-manager on my system in order to set up some
virtual machines. I added the libvirtd service to my system by adding
the following service to my system configuration:

```
(service libvirt-service-type)
```

and I've added myself to the libvirt group.

I can see the service running when I do:

```
robby@lambda ~$ sudo herd status libvirtd
Status of libvirtd:
  It is running since 10:34:29 PM (5 minutes ago).
  Running value is 256.
  It is enabled.
  Provides (libvirtd).
  Requires ().
  Will be respawned.
```

I can see the libvirt-sock file that I should be able to use:

```
robby@lambda ~$ groups
users libvirt netdev audio video dialout wheel
robby@lambda ~$ ll /var/run/libvirt/libvirt-sock
srwxrwx--- 1 root libvirt 0 May 28 22:34 /var/run/libvirt/libvirt-sock
```

But I cannot use virt-manager or virsh as my user. I see the following
behavior using virsh:

```
robby@lambda ~$ virsh -c qemu:///system
error: failed to connect to the hypervisor
error: internal error: Unable to get system bus connection: Could not connect: No such file or directory
robby@lambda ~$ sudo virsh -c qemu:///system
Welcome to virsh, the virtualization interactive terminal.

Type:  'help' for help with commands
       'quit' to quit

virsh #
```

So I can use virsh while running as root - but I should also be able to
use it when running as my user...

When I try to connect using virt-manager, I see the following similar error:

```
Unable to connect to libvirt qemu:///system.

internal error: Unable to get system bus connection: Could not connect: No such file or directory

Libvirt URI is: qemu:///system

Traceback (most recent call last):
  File "/gnu/store/sa4wwfmvlrry69gyilhb961gpbbamayf-virt-manager-4.1.0/share/virt-manager/virtManager/connection.py", line 923, in _do_open
    self._backend.open(cb, data)
  File "/gnu/store/sa4wwfmvlrry69gyilhb961gpbbamayf-virt-manager-4.1.0/share/virt-manager/virtinst/connection.py", line 171, in open
    conn = libvirt.openAuth(self._open_uri,
  File "/gnu/store/nb6yaafwa44jqfg9s5fbr5nbsa46panm-python-libvirt-8.6.0/lib/python3.10/site-packages/libvirt.py", line 147, in openAuth
    raise libvirtError('virConnectOpenAuth() failed')
libvirt.libvirtError: internal error: Unable to get system bus
  connection: Could not connect: No such file or directory
```

Since this seems to be an issue relating to dbus, here are the following
services I have running related to that:

At a system level:
```
(service dbus-root-service-type)
(service elogind-service-type)
```

As my user:
```
(service home-dbus-service-type)
```

Maybe there is some conflict between running dbus as my user and as
root?

Any advice for getting virt-manager working would be greatly
appreciated!

Thanks,
Robby


^ permalink raw reply	[flat|nested] 5+ messages in thread

end of thread, other threads:[~2023-05-29 20:06 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-29  2:35 Cannot run virt-manager as my user Robby Zambito
2023-05-29  4:40 ` Ruijie Yu via
2023-05-29 13:14   ` Robby Zambito
2023-05-29 15:01     ` David Conner
2023-05-29 17:06       ` Robby Zambito

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/guix.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.