Re: [PATCH v2] daemon: Always advertise libvirtd service

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



于 2011年10月12日 20:34, Daniel P. Berrange 写道:
On Tue, Oct 11, 2011 at 09:24:26PM +0800, Osier Yang wrote:
This is a regression introduced by new RPC codes, previously
we advertise the service via ssh even if the daemon doesn't
listen on TLS port (TCP is not choosed). Now the service is
only advertised when it listens on TLS or TCP port. This breaks
upper layer apps which intends to discover the service, such
as virt-manager.
---
  daemon/libvirtd.c |    6 +++++-
  1 files changed, 5 insertions(+), 1 deletions(-)

diff --git a/daemon/libvirtd.c b/daemon/libvirtd.c
index d1bc3dd..2f0e1be 100644
--- a/daemon/libvirtd.c
+++ b/daemon/libvirtd.c
@@ -470,8 +470,12 @@ static int daemonSetupNetworking(virNetServerPtr srv,
                                               NULL)))
          goto error;

-    if (virNetServerAddService(srv, svc, NULL)<  0)
+    if (virNetServerAddService(srv, svc,
+                               config->mdns_adv&&  !ipsock ?
+                               "_libvirt._tcp" :
+                               NULL)<  0)
          goto error;
+
      if (svcRO&&
          virNetServerAddService(srv, svcRO, NULL)<  0)
          goto error;
ACK this is better.


Daniel

Thanks, pushed

Osier

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list



[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]