
Code: Select all
$ mkdir ~/webdavCode: Select all
$ sudo chmod 4711 /usr/sbin/mount.davfsCode: Select all
https://www.wenzi.com/nextcloud/remote.php/webdav/ /home/wenzi/webdav/ davfs _netdev,noauto,user,uid=wenzi,gid=wenzi 0 0Code: Select all
$ grep -v "^#\|^$" ~/.davfs2/secrets
/home/wenzi/webdav usernameCode: Select all
$ chmod 600 ~/.davfs2/secretsit works ,but have a problem ,when I open the ~/webdav ,it very slow ,I think it may download the whole file in the network.Fitzcarraldo wrote:Try the following:
1. Install davfs2
2. Create mountpoint in home directory:
3. Allow non-root users to mount WedDAV resources:Code: Select all
$ mkdir ~/webdav
4. Add a line to /etc/fstab (adjust URL, username and group as required):Code: Select all
$ sudo chmod 4711 /usr/sbin/mount.davfs
5. Configure ~/.davf2s/secretsCode: Select all
https://www.wenzi.com/nextcloud/remote.php/webdav/ /home/wenzi/webdav/ davfs _netdev,noauto,user,uid=wenzi,gid=wenzi 0 0
where 'username' is the username on the server.Code: Select all
$ grep -v "^#\|^$" ~/.davfs2/secrets /home/wenzi/webdav username
Add a bookmark in the file manager:Code: Select all
$ chmod 600 ~/.davfs2/secrets
davs://192.168.1.165/nextcloud/remote.php/webdav
(or whatever the IP address of the server is)

I install gentoo in the vbox ,use xfce4 ,it works ,but I don't know why my system can not work ,finally I reinstall the system ,and everyting get work. BUT ,there is a funny things if I use gdm or sddm ,nautilus or thunar connect the webdav the connectting is very slow ,maybe 1 min ,get me the dialoge ,and I input the username and password ,will wait 1 min .but if I use lightdm , immediately!! I don't know whyFitzcarraldo wrote:I don't have GNOME installed in Gentoo, but I have KDE installed in Gentoo. Without davfs2, the Dolphin file manager does the same as you say Nautilus does in GNOME, i.e. it copies the complete video to the local machine before playing it. I don't know if the behaviour can be changed. I also tried the PCManFM file manager in Lubuntu 18.04 (LXDE) with and without davfs2, and the behaviour of PCManFM without davfs2 looks to be the same as you observe with Nautilus in GNOME, i.e. it downloads the complete video first.
When I use davfs2 in Lubuntu 18.04, though, it does cache the video. I can see it is doing that because the video stops and starts as it plays. But it is still very slow, with too many interruptions. The cache size and other parameters in davfs2 can be adjusted in the file ~/.davfs2/davfs2.conf or /etc/davfs2/davfs2.conf (see man davfs2.conf for details). It doesn't look easy to configure, though. In my case davfs2 performs much better in Lubuntu 18.04 than it does in Gentoo KDE Plasma 5. I still find it too slow to use in Lubuntu 18.04, but I find davfs2 completely unusable in Gentoo KDE. The KDE Plasma Network Monitor widget indicates a very high download rate all the time, even when all I am trying to do is open a shared folder via WebDAV, which takes minutes to open. So I don't think I can be of more help. Actually, if someone knows how to make WebDAV browsing faster, I would also be interested. WebDAV works a lot faster on my phone running Android 9 than in either Gentoo or Lubuntu.
P.S. I also tried with Ubuntu 20.04 in a VM, and performance is also poor in that.