The GNOME UI indicates that sharing the ~/Public directory is as easy as going to Settings => Sharing and enabling File Sharing but I just cannot seem to get it to work on local host or from another machine on my network.
I have tried using the hostname and the IP. E.g., “dav://” and “dav://” from nautilus but it always fails to connect.
I thought maybe this was a firewall issue so I enabled port 80 using
firewall-cmd it simply doesn’t work.
Out of desperation I tried restarting as well.
Is this a common problem and how do you fix it?
Maybe my plain-old-user account lacks permissions to open up port 80.
The only way I’ve made File Sharing work is via SSH with a utility like WinSCP for Windows. If you use Windows you can try it and it should work.
Gnome file sharing doesn’t use port 80 and the firewall definitely is not configured to allow it.
$ sudo firewall-cmd --list-services
dhcpv6-client mdns samba-client ssh
$ ps -ef | grep httpd
bill 578620 1000 0 20:40 ? 00:00:00 /usr/sbin/httpd -f /usr/share/gnome-user-share/dav_user_2.4.conf -C Listen 46383
From the above output you can see that the port is 46383 on my machine.
Also, if you list all the available firewall services with
firewall-cmd --get-services you can see that the firewall does not have a service that can be enabled to allow it.
Someone at Fedora should be able to answer this question.
The port number is assigned dynamically. It is in a range that the firewall should already allow. I was able to successfully test a file transfer like this from another machine:
$ curl http://servername.local:46383/filename
You have to determine the port number with
ps -ef | grep httpd
The problem I ran into was that avahi on the server fails to resolve the servername.local sometimes. I often have trouble with avahi on Fedora. Sometimes I have to restart it to get it to work. This may be the problem you’re running into because avahi is involved in the gnome-user-share process.
$ sudo systemctl restart avahi-daemon.service