Open-Xchange is an all-in-one Groupware solution, providing not only email, but also a CalDAV calendar, tasks, file- or InfoStore and an online document editor. All shareable with other users. The InfoStore is used to save documents online, in the cloud. This article is about accessing and mounting your Open-Xchange remote WebDAV InfoStore file share, on Linux with
mount.davfs or Dolphin GUI file manager.
OX Drive is enabled for all users that have the capability com.openexchange.capability.drive. Please note that users need to have the infostorepermission set to use drive. So the users that have drive enabled must be a subset of those users with infostore permission. Since 7.6.0 we enforce this via the default configuration.Enabling OX Drive for Users
Mounting and accessing Open-Xchange WebDAV InfoStore on Linux
Mounting and accessing your Open-Xchange InfoStore or OX Drive is not different from other WebDAV resources and is quite easy:
- create a mount point:
$ sudo mkdir /media/ox
mount.davfsto mount a WebDAV share:
$ sudo mount.davfs https://open-xchange.example.com/servlet/webdav.infostore /media/ox [sudo] password for user: Please enter the username to authenticate with server https://open-xchange.example.com/servlet/webdav.infostore or hit enter for none. Username: firstname.lastname@example.org Please enter the password to authenticate user email@example.com with server https://open-xchange.example.com/servlet/webdav.infostore or hit enter for none. Password: ...
Your Open-Xchange InfoStore is now available on
Automatically mount your InfoStore/OXDrive folder with WebDAV
In order to access an Open-Xchange InfoStore WebDAV share as a filesystem, you’ll need to install the
davfs2 package. It’s in the repositories by default. Then, add a line to your
/etc/fstab file to make mounting easier. Note we are specifying noauto here, we will perform the automatic mounting step later.
/etc/fstab is often run before network initialisation, and therefore an automatic mount here will fail.
https://open-xchange.example.com/servlet/webdav.infostore /media/ox davfs noauto,user 0 0
Add your user to the correct group:
usermod -a -G davfs2 your-username
And now you should be able to mount your share and work with your files. You’ll be prompted for your username and password:
mount /media/ox umount /media/ox
Saving OX InfoStore mount credentials
You might find it’s inconvenient to have to type in your username and password every time you want to mount your OX Drive. It’s a hurdle which needs to be overcome if you want to be able to automatically have your WebDAV share mounted.
davfs2 makes use of the
/home/your-username/.davfs2/secrets file for storing your logon credentials. You simply need to create this with the correct permissions and then provide the host, username and password details.
touch /home/your-username/.dav2fs/secrets chmod 0600 /home/your-username/.dav2fs/secrets echo "https://open-xchange.example.com/servlet/webdav.infostore <username> <password>" > /home/your-username/.dav2fs/secrets
After this step, you will be able to mount your share without providing a username and password.
Because you can’t mount an InfoStore WebDAV share until after the network connection has been established, you can’t use the auto option in your
/etc/fstab file. Instead, you can use one simple command to take care of this, to mount your Open-Xchange InfoStore (OX Drive) share automatically.
/etc/rc.local file is executed after boot, and so is an excellent place to provide the functionality we are looking for, add:
mount -a # make sure this command is above the exit 0 command
rc.local is still an option, even with systemd. Just create the file if it’s not there.
GUI file manager, like Dolphin
In a GUI file manager like Dolphin, you may enter the URI
webdav://open-xchange.example.com/servlet/webdav.infostore and authenticate with your Open-Xchange account credentials (email address and password) to access your InfoStore.
In Gnome Nautilus, use
davs:// as protocol schema.