owncloud

owncloud provides functionality similar to dropbox. There are a number of other websites similar to dropbox that provide file storage, syncing, and sharing functions. Why then spend any time setting up owncloud? For me, the answer is in taking control of our own data and the file storage space.

Of course, the disadvantage is that now I would be responsible for keeping the server up, backing up the data, and maintaining the system.

The owncloud architecture is such that a lot of the functionality is provided by plugins. There are plethora of features and options and configurations to consider. This post deals only with the basic functionality simply because so far that is what I am familiar with.

Installing owncloud

The changeLog at the owncloud website shows that the owncloud version 4.5.3 was released on Nov 27th 2012. It just so happened that I installed the same version (owncloud-4.5.3) on Nov. 27th on our server running Fedora Core 14. I accessed the owncloud from my desktop running also Fedora Core 14.

Installation was painless. I downloaded the release from http://download.owncloud.org/releases/owncloud-4.5.3.tar.bz2 and followed the instructions on owncloud/support/install. In my case apache was setup already such that I unpacked the package at /var/www/html and ran chown -R apache:apache owncloud. That was that! Warning: if you already have an owncloud installation, remember to save it first.

One thing I have to say about this project is that it is rough around the edges and the project is not well documented. Therefore sometimes even simple things can take a little bit of time to setup. Of course, it is a matter of time that most of these issues will be resolved. Maybe by the time you read this post!

Setting up owncloud

Fire up the firefox web browser on your desktop system and point it to http://hostname/owncloud (hostname is where owncloud is installed, 192.168.1.1 in my case). You will see a screen as shown in the picture below.



When you click on the Advanced, you will see two options. The Data folder is where all the uploaded data will end up. I kept the default. Configure the database gives two choices for a database. Although I have mysql already running on my system, I chose SQlite because it is simpler and faster.

Type in your password and click on Finish setup. You will end up with a screen that looks like this.



Settings

In the lower left corner, you will see a gear icon. Click on it and you will see several choices.

Click on Users. This screen allows you to create users and groups as shown in the picture above. While you are creating users, you can assign them to one or more groups and a default quota of hard drive space.

Adding more space after owncloud installation

Once the owncloud is installed on the server, it may be necessary to add more hard drive space to it. Lets say that we have a new partition mounted on /mnt/sdb2 with a lot of hard drive space. How do we make that space available to owncloud?

First stop the apache server by typing service httpd stop then type mv data /mnt/sdb2/data to move the data to the new partition and then create a symbolic link by typing ln -s /mnt/sdb2/data data. For this to work the apache configuration file /etc/httpd/conf/httpd.conf needs to have Options FollowSymLinks in it. Don’t forget to restart the apache server.

Upload, Download, and Sharing of files

Login to your owncloud account and click on Files icon in the upper left corner. Here you can create folders and navigate your file system.

Before you upload anything, first navigate to your target folder. Then click on the up arrow icon next to theNew button. A new window will open up to navigate your local file system to pick your file(s) to upload. Click on open to upload the file you picked.

When you hover your mouse over a file, you will see several options on the right hand side. If you click on the Download icon, a window will pop up with options to Save or Open that file. If you choose Save, that file will be downloaded into your Downloads folder (or any other folder you configured).

Another option on the same line is Share. If you click on this icon, a window will pop up. You can type the name of the user in the text box that displays Share With. This option allows you to share the file with another user or group of users.

If some other user shared a file with your account, a Shared folder will be created automagically in Files folder. Inside it you will find any shared files. Note that this folder will appear only if some other user shared any files with your account.

If you click on the check box labeled Share with link, you will see a URL displayed just under it. You can use this URL to share that file with anybody, even people without any owncloud account.

Setting up webdav

What is webdav and why bother with it? Webdav is an authoring standard that allows any user to edit files over the web and keep multiple versions of it on the server. Normally this would be irrelevant except for the fact that number of apps already have a built it support for it.

For example apache has a webdav plug-in, but we don’t need to enable it, because owncloud has a built-in support for webdav. Firefox web browser has a built-in webdav client. Also gnome file manager has a built-in webdav client support, and consequently ads drag-and-drop support to owncloud.

To access your files stored on your owncloud account via webdav protocol, fire up your firefox browser and navigate to http://hostname/owncloud/files/webdav.php. You will see a pop up window asking for a username and a password. Type in your owncloud username and password. You will see your filesystem in the firefox browser window and explore it.

To setup gnome file manager with webdav support, click on Places and then Connect to Server. A window will pop up asking for values. Fill them as shown here except that replace your own values.



When I do that I get an error message as shown in the picture below. I have a suspicion that the problem is with the gnome file manager, not the owncloud. Because owncloud webdav seems to work just fine with the firefox webdav client as mentioned earlier.



Mounting external filesystems

What if you have a large amount of media stored on an external drive or a partition and you want to access it from within the owncloud filesystem?

There is a plug-in to accomplish this, and it is called External storage support. To enable it, first click on the Apps button from admin account settings as shown in the picture below. Then click on External storage support and then click on Enable.



Now when you go back to the Admin page by clicking on it, External Storage section will appear. For each external file system you want to mount, define an entry here and then click on the Save button at the top. By the way, I think it would make a lot more sense if the Save button was at the end of the page.

First select the Backend. Based on which backend is selected, different options will appear. In my case I picked ‘Local’. Mount point is the name of the folder that will appear in the owncloud virtual filesystem. It should already exist, but if it doesn’t, I think it will be created for you. In Configuration put the path to the partition you want to mount. In Applicable you can pick users and groups which this entry should be applicable.

When I tried to use this feature, it seemed to work fine with a few folders and files. However, when I tried to configure in a larger set of files, the system seemed to hang during login. Maybe it was trying to cache the file entries, I don’t know. The only way out of this state was to restart the apache web server. Again, I think this feature is not quite usable yet.

Other features

One of the most important features of owncloud is its file sync’ing feature. I will be spending some time figuring out how to set that up and document it here.