Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 532328 - app-emulation/virt-manager-1.1.0 - /usr/share/virt-manager/virtManager/connect.py", line 273, in start_browse: GError: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.Avahi was not provided by any .service files
Summary: app-emulation/virt-manager-1.1.0 - /usr/share/virt-manager/virtManager/connec...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Virtualization Team
URL:
Whiteboard:
Keywords:
: 537436 (view as bug list)
Depends on:
Blocks:
 
Reported: 2014-12-11 22:28 UTC by Joakim Tjernlund
Modified: 2015-04-05 14:39 UTC (History)
2 users (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Joakim Tjernlund 2014-12-11 22:28:24 UTC
File->Add Connection gives me:

Error launching connect dialogue: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.Avahi was not provided by any .service files

Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/engine.py", line 714, in _do_show_connect
    self._get_connect_dialog().show(src.topwin, reset_state)
  File "/usr/share/virt-manager/virtManager/connect.py", line 143, in show
    self.start_browse()
  File "/usr/share/virt-manager/virtManager/connect.py", line 273, in start_browse
    service, domain, flags)
  File "/usr/lib64/python2.7/site-packages/gi/overrides/Gio.py", line 171, in __call__
    None)
GError: GDBus.Error:org.freedesktop.DBus.Error.ServiceUnknown: The name org.freedesktop.Avahi was not provided by any .service files

You only get this if no avahi installed and have dev-libs/dbus-glib installed

This quick patch fixes it:
--- virtManager/connect.py.org	2014-12-11 22:22:24.738608689 +0100
+++ virtManager/connect.py	2014-12-11 22:10:51.617237749 +0100
@@ -95,7 +95,10 @@
             self.avahiserver = Gio.DBusProxy.new_sync(self.dbus, 0, None,
                                     "org.freedesktop.Avahi", "/",
                                     "org.freedesktop.Avahi.Server", None)
+            self.avahiserver.GetVersionString()
+            logging.debug("self.avahiserver=%s", self.avahiserver)
         except Exception, e:
+            self.avahiserver = None
             logging.debug("Couldn't contact avahi: %s", str(e))
 
         self.reset_state()
Comment 1 Greg Turner 2015-01-01 06:58:14 UTC
I've seen this error, and have dbus-glib w/o avahi like Joakim says.  Haven't had the chance to test the patch yet.
Comment 2 Matthias Maier gentoo-dev 2015-01-01 10:38:48 UTC
The patch looks good. Can you attach it next time and the "PATCH" keyword?

Fortunately, except for the annoying error message, functionality remains intact, so I've just applied the patch to 1.1.0-r1 and 9999.


*virt-manager-1.1.0-r1 (01 Jan 2015)

  01 Jan 2015; Matthias Maier <tamiko@gentoo.org>
  +files/virt-manager-1.1.0-optional_avahi.patch, +virt-manager-1.1.0-r1.ebuild,
  virt-manager-1.1.0.ebuild, virt-manager-9999.ebuild:
  supress an error message in case avahi is not installed, bug #532328
Comment 3 Matthias Maier gentoo-dev 2015-04-05 14:39:09 UTC
*** Bug 537436 has been marked as a duplicate of this bug. ***