Home MoxiDrive Files & Synchronization Article
MoxiDrive fully supports the WebDAV protocol, and you can connect and synchronize with your MoxiDrive files over WebDAV. In this chapter, you will learn how to connect Linux, macOS, Windows, and mobile devices to your MoxiDrive server via WebDAV. Before we get into configuring WebDAV, let’s take a quick look at the recommended way of connecting client devices to your MoxiDrive servers.
Note
In the following examples, you should replace example.com/MoxiDrive with the URL of your MoxiDrive server (omit the directory part if the installation is in the root of your domain), and “USERNAME” with the username of the connecting user.
Nextcloud Desktop and mobile clients
The recommended way to synchronize a desktop PC with the MoxiDrive server is by using Nextcloud sync clients. You can configure the client to save files in any local directory and you can choose which directories on the MoxiDrive server to sync with. The client displays the current connection status and logs all activity, so you always know which remote files have been downloaded to your PC and you can verify that files created and updated on your local PC are properly synchronized with the server.
The recommended way to synchronize MoxiDrive server with Android and Apple iOS devices is by using the mobile apps.
To connect your mobile app to a MoxiDrive server use the base URL:
https://cloud.moxidrive.com
In addition to the mobile apps provided by Nextcloud, you can use other apps to connect to MoxiDrive from your mobile device using WebDAV. WebDAV Navigator is a good (proprietary) app for Android devices and iPhones. The URL to use on these is: cloud.moxidrive.com/remote.php/dav/files/USERNAME/
WebDAV configuration
If you prefer, you may also connect your desktop PC to your MoxiDrive server by using the WebDAV protocol rather than using a special client application. Web Distributed Authoring and Versioning (WebDAV) is a Hypertext Transfer Protocol (HTTP) extension that makes it easy to create, read, and edit files on Web servers. With WebDAV you can access your MoxiDrive shares on Linux, macOS and Windows in the same way as any remote network share, and stay synchronized.
Accessing files using Linux
You can access files in Linux operating systems using the following methods.
Nautilus file manager
When you configure your MoxiDrive account in the GNOME Control Center, your files will automatically be mounted by Nautilus as a WebDAV share, unless you deselect file access.
You can also mount your MoxiDrive files manually. Use the davs:// protocol to connect the Nautilus file manager to your MoxiDriveshare:
davs://cloud.moxidrive.com/remote.php/dav/files/USERNAME/
Note:
If your server connection is not HTTPS-secured, use dav:// instead of davs:
Note: The same method works for other file managers that use GVfs, such as MATE’s Caja and Cinnamon’s Nepomuk.
Accessing files with KDE and Dolphin file manager
To access your MoxiDrive files using the Dolphin file manager in KDE, use the webdav:// protocol:
You can create a permanent link to your MoxiDrive server:
Open Dolphin and click “Network” in the left hand “Places” column.
Click on the icon labeled Add a Network Folder. The resulting dialog should appear with WebDAV already selected.
If WebDAV is not selected, select it.
Click Next.
Enter the following settings:
Name: The name you want to see in the Places bookmark, for example MoxiDrive.
User: The MoxiDrive username you used to log in, for example admin.
Server: The MoxiDrive domain name, for example example.com (without http:// before or directories afterwards).
Folder – Enter the path Moxidrive/remote.php/dav/files/USERNAME/.
(Optional) Check the “Create icon” checkbox for a bookmark to appear in the Places column.
(Optional) Provide any special settings or an SSL certificate in the “Port & Encrypted” checkbox.
Creating WebDAV mounts on the Linux command line
You can create WebDAV mounts from the Linux command line. This is useful if you prefer to access Nextcloud the same way as any other remote filesystem mount. The following example shows how to create a personal mount and have it mounted automatically every time you log in to your Linux computer.
Install the davfs2 WebDAV filesystem driver, which allows you to mount WebDAV shares just like any other remote filesystem. Use this command to install it on Debian/Ubuntu:
apt-get install davfs2
Use this command to install it on CentOS, Fedora, and openSUSE:
yum install davfs2
Add yourself to the davfs2 group:
usermod -aG davfs2
Then create a MoxiDrive directory in your home directory for the mountpoint, and .davfs2/ for your personal configuration file:
mkdir ~/moxidrive
mkdir ~/.davfs2
Copy /etc/davfs2/secrets to ~/.davfs2:
cp /etc/davfs2/secrets ~/.davfs2/secrets
Set yourself as the owner and make the permissions read-write owner only:
chown : ~/.davfs2/secrets
chmod 600 ~/.davfs2/secrets
Add your MoxiDrive login credentials to the end of the secrets file, using your MoxiDrive server URL and your MoxiDrive username and password:
https://cloud.moxidrive.com/remote.php/dav/files/USERNAME/
or
$PathToMountPoint $USERNAME $PASSWORD
for example
/home/user/moxidrive john 1234
Add the mount information to /etc/fstab:
https://cloud.moxidrive.com/remote.php/dav/files/USERNAME/ /home//nextcloud
davfs user,rw,auto 0 0
Then test that it mounts and authenticates by running the following command. If you set it up correctly you won’t need root permissions:
mount ~/moxidrive
You should also be able to unmount it:
umount ~/moxidrive
Now every time you login to your Linux system your MoxiDrive share should automatically mount via WebDAV in your ~/moxidrive directory. If you prefer to mount it manually, change auto to noauto in /etc/fstab.
Known issues
Problem
Resource temporarily unavailable
Solution
If you experience trouble when you create a file in the directory, edit /etc/davfs2/davfs2.conf and add:
use_locks 0
Problem
Certificate warnings
Solution
If you use a self-signed certificate, you will get a warning. To change this, you need to configure davfs2 to recognize your certificate. Copy mycertificate.pem to /etc/davfs2/certs/. Then edit /etc/davfs2/davfs2.conf and uncomment the line servercert. Now add the path of your certificate as in this example:
servercert /etc/davfs2/certs/mycertificate.pem
Accessing files using macOS
Note:
The macOS Finder suffers from a series of implementation problems and should only be used if the MoxiDrive server runs on Apache and mod_php, or Nginx 1.3.8+. Alternative macOS-compatible clients capable of accessing WebDAV shares include open source apps like Cyberduck (see instructions here) and Filezilla. Commercial clients include Mountain Duck, Forklift, Transmit, and Commander One.
To access files through the macOS Finder:
From the Finder’s top menu bar, choose Go > Connect to Server…:
2. When the Connect to Server… window opens, enter your MoxiDrive server’s WebDAV address in the Server Address: field, i.e.:
https://cloud.moxidrive.com/remote.php/dav/files/USERNAME/
3. Click Connect. Your WebDAV server should appear on the Desktop as a shared disk drive.
Accessing files using Microsoft Windows
If you use the native Windows implementation of WebDAV, you can map MoxiDrive to a new drive using Windows Explorer. Mapping to a drive enables you to browse files stored on the MoxiDrive server the way you would files stored in a mapped network drive.
Using this feature requires network connectivity. If you want to store your files offline, use the Desktop Client to sync all files on your MoxiDrive to one or more directories of your local hard drive.
Note:
Windows 10 now defaults to allow Basic Authentication if HTTPS is enabled prior to mapping your drive. On older versions of Windows, you must permit the use of Basic Authentication in the Windows Registry: launch regedit and navigate to HKEY_LOCAL_MACHINESYSTEMCurrentControlSetServicesWebClientParameters. Create or edit the DWORD value BasicAuthLevel (Windows Vista, 7 and 8) or UseBasicAuth (Windows XP and Windows Server 2003) and set its value data to 1 for SSL connections. Value 0 means that Basic Authentication is disabled, a value of 2 allows both SSL and non-SSL connections (not recommended). Then exit Registry Editor, and restart the computer.
Mapping drives with the command line
The following example shows how to map a drive using the command line. To map the drive:
Open a command prompt in Windows.
Enter the following line in the command prompt to map to the computer Z drive:
net use Z: https:///remote.php/dav/files/USERNAME/ /user:youruser
yourpassword
where is the URL to your MoxiDrive server.
For example: net use Z: https://cloud.moxidrive.com/remote.php/dav/files/USERNAME/ /user:youruser yourpassword
The computer maps the files of your Nextcloud account to the drive letter Z.
Note:
Though not recommended, you can also mount the MoxiDrive server using HTTP, leaving the connection unencrypted. If you plan to use HTTP connections on devices while in a public place, we strongly recommend using a VPN tunnel to provide the necessary security.
An alternative command syntax is:
net use Z: example.com@sslmoxidriveremote.phpdav /user:youruser
yourpassword
Mapping drives with Windows Explorer
To map a drive using the Microsoft Windows Explorer:
Open Windows Explorer on your MS Windows computer.
Right-click on Computer entry and select Map network drive… from the drop-down menu.
Choose a local network drive to which you want to map MoxiDrive.
Specify the address to your MoxiDrive instance, followed by /remote.php/dav/files/USERNAME/.
For example:
https://cloud.moxidrive.com/remote.php/dav/files/USERNAME/
Note:
For SSL protected servers, check Reconnect at sign-in to ensure that the mapping is persistent upon subsequent reboots. If you want to connect to the MoxiDrive server as a different user, check Connect using different credentials.
5. Click the Finish button.
Windows Explorer maps the network drive, making your MoxiDrive instance available.
Accessing public shares over WebDAV
MoxiDrive provides the possibility to access public shares over WebDAV.
To access the public share, open:
https://cloud.moxidrive.com/public.php/webdav
in a WebDAV client, use the share token as username and the (optional) share password as password.
Note:
Settings → Administration → Sharing → Allow users on this server to send shares to other servers. This option also allows WebDAV access to public shares needs to be enabled in order to make this feature work.
[ 0 Out of 0 Found Helpful ]
Submit a ticket and we’ll get back to you as soon as possible.