3

I would like to advertise my NFS shares via Avahi so that I can just browse from multiple machines without having to set it all up, especially when guests come over and I want something automagic.

I am aware most clients will need extra packages (Like nfs-common) installed for it to work. The ideal solution will include instructions for clients as well (if any).

Jorge Castro
  • 73,717

2 Answers2

3

My answer to question 18933 actually included an answer for NFS shares (although the question did not explicitly mention NFS): Create a service description file (e.g. nfs.service) in /etc/avahi/services with the following content:

<service-group>
  <name replace-wildcards="yes">NFS share on %h</name>
  <service>
    <type>_nfs._tcp</type>
    <port>2049</port>
    <txt-record>path=/path/to/someshare</txt-record>
  </service>
</service-group>

The port 2049 requires you to use the insecure option in the /etc/exports file, though.

Then it should be possible to use your file manager, navigate to "Networks" and access your share. Unfortunately, The GNOME file manager does not provide support for NFS at the moment (Launchpad Bug #29263, thanks to João Pinto for pointing this out) and the NFS support in the KDE file manager is broken (KDE bug #184997 Now fixed) as well…

2

NFS advertised shares are not handled by gnome-vfs at this time, there is a bug report requesting it: https://bugs.launchpad.net/gnome-vfs/+bug/29263

João Pinto
  • 17,323