Few Zeroconf Service Types Work in Dolphin

Bug #311258 reported by David Taylor
26
This bug affects 4 people
Affects Status Importance Assigned to Milestone
KDE Network
Fix Released
Medium
dolphin (Ubuntu)
Invalid
Undecided
Unassigned
kdenetwork (Ubuntu)
Confirmed
Medium
Unassigned

Bug Description

When I add a service file to my /etc/avahi/services/ folder dolphin does not display them with the zeroconf:/ kio.
I automatically thought that I had done something wrong even though the service files worked in the last release fine so I tested them against the avahi-browse application and they worked fine there so this must be a fault in Dolphin and not the Avahi Zeroconf implementation. This gets a little bit more distorted when I add the ssh service file (a duplicate of the example file from the docs folder) and it displays as a fish service and connects as a fish service but shows up fine in the avahi-browse app mentioned earlier.

Example ssh.service file (That shows as a fish service in Dolphin):
<service-group>

   <name replace-wildcards="yes">Remote Terminal on %h</name>

   <service>
     <type>_ssh._tcp</type>
     <port>22</port>
   </service>

Example smb.service file (That does bugger all in Dolphin):
<service-group>

  <name replace-wildcards="yes">%h</name>

  <service>
    <type>_smb._tcp</type>
    <port>445</port>
  </service>

Please can this be investigated please as it appears to have been borked between 8.04 and 8.10

1) The release of Ubuntu you are using: 8.10
2) The version of the package you are using: 4:4.1.3-0ubuntu1~intrepid1
3) What you expected to happen: All possible service types to work.
4) What happened instead: Bugger All.

Revision history for this message
David Taylor (me-davidandrewtaylor) wrote :
Revision history for this message
Donatas Glodenis (dgvirtual) wrote :

This bug affects me too. I have three services declared in /etc/avahi/services/ in three computers on my local network and I get only the ssh services through the konqueror/dolphin zeroconf:/ kioslave.

Here is the output of mdns-scan:

sim@bala:~$ mdns-scan
+ Remote Terminal on bala._ssh._tcp.local
+ Samba shares on bala._smb._tcp.local
+ fish:/ prisijungimas į bala._fish._tcp.local
+ bala [00:13:02:9b:26:e4]._workstation._tcp.local
+ Remote Terminal on pieva._ssh._tcp.local
+ Samba shares on pieva._smb._tcp.local
+ fish:/ prisijungimas į pieva._fish._tcp.local
+ pieva [00:50:8d:50:0a:37]._workstation._tcp.local
+ Remote Terminal on meldas._ssh._tcp.local
+ Samba shares on meldas._smb._tcp.local
+ fish:/ prisijungimas į meldas._fish._tcp.local
+ meldas [00:15:af:a7:52:62]._workstation._tcp.local
Browsing ... \

When I enter plain zeroconf:/ into the browser, I get a folder
"Nutolęs diskas (fish)" (which means "Remote disk (fish)"

when I open it, I see a list of three entries "remote terminal on Hostname" - weird, I expected remote disks here !

and the browser address bar changes to:
zeroconf:/_ssh._tcp

But when I click on one of tose icons, I can get connected to a remote server through the fish protocol. So the zeroconf does not display most of the service types, and in part reports wrongly those it does detect.

I am using kde 4.1.3 on Kubuntu Intrepid.

There is a thread about this problem on forums.kde.org:
http://forum.kde.org/kde4-networking-zeroconf-t-17141.html

Revision history for this message
David Taylor (me-davidandrewtaylor) wrote :

I have tested this on KDE 4.2 as I figured the binaries would have less chance to have been altered to cause this problem but nope it fails as described.

I also tried this on the project Neon Binaries for 4.2 and the same thing occurred.

Revision history for this message
Harald Sitter (apachelogger) wrote :

Good afternoon Gentlemen,

I have some difficulties reproducing the issue. Actually I don't seem to quite understand it.

Could one of please provide a detailed list of things to do, in order to reproduce this issue, and if possible also add a set of information what you expect to happen (comparing to what actually does happen).

Thank you very much in advance :-)

Changed in dolphin:
status: New → Invalid
Changed in kde4libs:
status: New → Incomplete
Revision history for this message
David Taylor (me-davidandrewtaylor) wrote :

Hi Harald,

Test 1
---------
1. Download the smb.service file that is attached above.
2. Add this file to the the path /etc/avahi/services/ respecting the permissions
3. install and run the avahi-browse tool.
4. Compare the difference between the zeroconf:/ ioslave output and the avahi-browse output.

You will see that the service you have just added shows in avahi-browse but not in the zeroconf:/ ioslave.

Test 2
---------
1. Use the text:

<service-group>

   <name replace-wildcards="yes">Remote Terminal on %h</name>

   <service>
     <type>_ssh._tcp</type>
     <port>22</port>
   </service>

to create a file called ssh.service.
2. Add this file to the the path /etc/avahi/services/ respecting the permissions.
3. Install and run the avahi-browse tool.
4. Compare the difference between the Zeroconf:/ ioslave output and the avahi-browse output.

The file you have just added will show in the zeroconf:/ ioslave as a fish service and not an ssh service. When we look at the out-put from the avahi-browse tool it shows it correctly as a ssh service.

What I expect
--------------------
The zeroconf:/ ioslave
1. To display all the services that are on offer.
2. To show services as they are identified in the service file and not something else.

Further Information
---------------------------
I have tried this in the KDE 4.1 release, the KDE 4.2 beta release, the KDE RC1 with the Kubuntu packages and the Neon nightly releases and it doesn't work properly. I can send screen shots if you are still having difficulty reproducing the fault.

Thank you Harald I am pleased this is getting some attention.

Changed in kde4libs:
status: Incomplete → New
Revision history for this message
David Taylor (me-davidandrewtaylor) wrote :

Hi guys I have tested this again in the 9.04 release and there has been no improvement. An ssh service file displays as a fish service file and none of the others work apart from when using the avahi-browse or mdns-scan (as Donatas pointed out) tools.

I know the zeroconf service has only been broken in Kubuntu KDE for six months but is there any further way I could assist in getting this resolved?

Revision history for this message
In , James (james-ellis-gmail) wrote :
Download full text (4.0 KiB)

Version: (using KDE 4.2.3)
OS: Linux
Installed from: Ubuntu Packages

Hi

I tried using zeroconf:/ to browse & discover devices and services that are advertising on the local domain. I get no errors but then also no results in Dolphin or Konquerer. Unfortunately I can't find a way to debug this easily.

I've reported this on Launchpad for Kubuntu but thought there may be more interest here.

Any ideas on what may be the cause?

Here's a copy of the bug report:

https://bugs.launchpad.net/ubuntu/+source/kdenetwork/+bug/380288
======
I've been tinkering with this for a while and have hit a brick wall. Not matter what I do, the zeroconf:/ stubbonly refuses to work in both konq and dolphin.

System : Kubuntu 9.04 with 4.2.3 packages installed and up to date.

System has avahi installed and running. avahi-discover, avahi-browse and mdns-scan all report services broadcasting. Typing zeroconf:/ into the url bar does not bring up any errors and is available in remote:/ as "network services"

Packages installed:
$ aptitude search avahi | grep "^i"
i avahi-autoipd - Avahi IPv4LL network address configuration
i avahi-daemon - Avahi mDNS/DNS-SD daemon
i avahi-discover - Service discover user interface for avahi
i avahi-dnsconfd - Avahi DNS configuration tool
i avahi-utils - Avahi browsing, publishing and discovery u
i bzr-avahi - mDNS plugin for Bazaar
i libavahi-client3 - Avahi client library
i libavahi-common-data - Avahi common data files
i libavahi-common3 - Avahi common library
i libavahi-compat-libdnssd1 - Avahi Apple Bonjour compatibility library
i libavahi-core5 - Avahi's embeddable mDNS/DNS-SD library
i A libavahi-glib1 - Avahi glib integration library
i libavahi-qt3-1 - Avahi Qt 3 integration library
i libavahi-qt4-1 - Avahi Qt 4 integration library
i python-avahi - Python utility package for Avahi

$ sudo aptitude search mdns
i libnss-mdns - NSS module for Multicast DNS name resolution
i mdns-scan - Scan for mDNS/DNS-SD services published on the local network

kde-zeroconf is installed as well.

avahi-discover:
Browsing domain 'local' on -1.-1 ...
Browsing for services of type '_http._tcp' in domain 'local' on 2.0 ...
Browsing for services of type '_rsp._tcp' in domain 'local' on 2.0 ...
Browsing for services of type '_daap._tcp' in domain 'local' on 2.0 ...
Browsing for services of type '_afpovertcp._tcp' in domain 'local' on 2.0 ...
Browsing for services of type '_raop._tcp' in domain 'local' on 2.0 ...
Browsing for services of type '_sleep-proxy._udp' in domain 'local' on 2.0 ...
Browsing for services of type '_workstation._tcp' in domain 'local' on 2.0 ...
Browsing for services of type '_airport._tcp' in domain 'local' on 2.0 ...
Found service 'tomato on tomato' of type '_http._tcp' in domain 'local' on 2.0.
Found service 'tomato on tomato' of type '_rsp._tcp' in domain 'local' on 2.0.
Found service 'tomato on tomato' of type '_daap._tcp' in domain 'local' on 2.0.
Found service 'tomato (AFP)' of type '_afpovertcp._tcp' in domain 'local' on 2.0.
Found service 'pinky' of type '_airport._tcp' in domain 'local' on 2.0.

mdns-scan

$ mdns-scan
+ tomato (AFP)._afpovertcp._tcp.local
+ tomato on tomato._http._tcp.loc...

Read more...

Revision history for this message
James (james-ellis-gmail) wrote :

Be great if this could be fixed... could do some interesting stuff like discovering and streaming music to an Airport Express from Amarok if zeroconfig worked.

On another note, I'm not sure why a configuration file is needed to configure zeroconf.. isn't the point of zeroconf that the client simply discovers broadcasting devices on the network and then tells the requesting application where it is on the network ?

See my duplicate bug :
https://bugs.launchpad.net/ubuntu/+source/kdenetwork/+bug/380288

for a comparison of avahi output vs zeroconf:/ output (none).

Revision history for this message
James (james-ellis-gmail) wrote :

In KDE 4.3 accessing the network:/ ioslave in konq and dolphin shows up all the broadcasting devices on the network without any avahi config. The zeroconf:/ location still does nothing.

I'm not sure if this is a fix or a workaround.

Revision history for this message
Robin Perkins (robin-perkins) wrote :
Download full text (3.9 KiB)

Hopefully I can explain things a little bit. First off the /etc/avahi/services file is what is used by the Avahi daemon to *advertise* what services you have available on your local host. It is not the recommended way to advertise services, the recommended way is to have zeroconf support build into the service itself - eg have Apache talk to Avahi directly to say what web servers it has available rather than have a /etc/avahi/services/http.service file; this way additions, edits and removal of services (http in this case) can be thrown out to the network immediately. As far as I remember you need manually tell Avahi to parse its services files to pick up changes.

Unfortunately for us opensshd doesn't support zeroconf/avahi yet (Is there a wishlist bug for this yet ? ) and so we have to resort to using a services file.

In KDE 4.3's Dolphin's Network folder we see three zones
1) "Network" which is a kio_network kpart; this is an experimental kio that will conglomerate multiple methods to provide information on what is out there on the network (I think something similar to what Vista/Win 7 does). At the moment it only uses zeroconf but will use others such as UPnP in the future. It shows up many services, more than the zeroconf kioslave does, however a lot of these KDE doesn't know what to do with them yet. For example it shows Apple File Protocol shares [_afpovertcp._tcp] (as used on OS X and by netatalk) however there isn't an afp kioslave yet. Another example is [_presence._tcp] which is an IM user - I'm not sure how this service information is going to be used/useful from a Dolphin point of view. (See http://websvn.kde.org/trunk/KDE/kdebase/runtime/kioslave/network/ioslave/mimetypes.cpp for all the services it looks for).
2) "Network Services" which is a kio_zeroconf ioslave thing. (See http://websvn.kde.org/trunk/KDE/kdenetwork/kdnssd/ioslave/). The problem with this at the moment is that the services it browses for are fixed within the module (This may or may not be a bad thing depending on what the purpose of it is). At the moment these services are ftp, webdav, sftp, ssh and nfs. At a guess the intention was for this module to show not so much 'Network services' but 'Network file systems'. For example ssh is at the moment presented as a file system (fish) but it is just as appropriate to open a terminal with a ssh session to that service ( which is what kio_network does with it) . The two obvious services that are missing from that list are afp (but as I said above we will need to write a whole new kio for that) and the other one is smb, which is a bit of another story given:
3) "Samba Shares" which uses the smb kioslave. As far as I can tell this uses only the NetBIOS method for searching for SMB 1 services on the network. Nowadays however there are at few other ways to find samba/cifs shares: zeroconf and (I think) a new method in Vista (I'm not completely sure - I get a bit lost in Mircosoft's naming of network services and what exactly they are all meant to do...something about WINS servers or using Dynamic DNS servers or Active Directory ...and does PNRPv2 fit in somehow ?). Read more at http://en.wikipedia.org/wiki/Server_Messa...

Read more...

Revision history for this message
Robin Perkins (robin-perkins) wrote :
Revision history for this message
In , Robin Perkins (robin-perkins) wrote :
Revision history for this message
James (james-ellis-gmail) wrote :

Hi Robin

Really good to see some information about this. My thoughts on this at the moment are that zeroconf:/ should be a subset of network:/ - on my machine zeroconf:/ does absolutely nothing anyway (may just be my machine, who knows ?). Additionally it seems confusing/duplication to have both "Network" and "Network Services", rather than just "Network".

I'm not sure why zeroconf:/ is limited in KDE to the mentioned services, it seems at-odds with the intention of any zeroconf enabled appliance to broadcast where it is on the network and what they do. For instance, I'd expect my TV could say over zeroconf 'Hi I'm a TV, I'm at this IP address and this is what I can do". It's then up to KDE to stream digital video to it.

From a client (Dolphin / Konq) point of view, any broadcasting services that it discovers and lists should be linked to the various applications that know how to handle that service. This would be in the same vein as a mimetype being linked to an application e.g text/plain being linked to Kate. Activating a found service would either prompt for a handler application or if one is already set, open that application. Dolphin then just hands off to the application and it deals with action.

For instance, my Airport Express broadcasts a ".airport" a ".raop" and a ".sleep_proxy". I have no idea what the latter is but the former could tell Amarok, for instance, that there is a broadcasting AP on the network and that it can accept music streamed using RAOP, much like iTunes streams music to an AP (there are various alternate clients around that can do this). Amarok already finds DAAP services via kdnssd so this kind of thing can be done.

Similarly, a ".ssh" service would open Konsole with a prompt to log in at the IP supplied, an http service would launch the default browser, and so-on.

Hope that helps as a use case/example.

Changed in kdenetwork (Ubuntu):
status: New → Confirmed
importance: Undecided → Medium
Changed in kdenetwork:
status: Unknown → New
Changed in kdenetwork:
importance: Unknown → Medium
Revision history for this message
In , James (james-ellis-gmail) wrote :

seems to be working in 4.9

Changed in kdenetwork:
status: New → Fix Released
Revision history for this message
In , RussianNeuroMancer (russianneuromancer) wrote :

Issue still reproducible for me in KDE 4.10.3. I need to fill another ticket or maybe it's possible to reopen this one?

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Duplicates of this bug

Other bug subscribers

Bug attachments

Remote bug watches

Bug watches keep track of this bug in other bug trackers.