Installing and configuring owncloud

Todd and I spent a morning installing and configuring owncloud on the team server. Things worked fairly well - with essentially only one glitch that I'll discuss at the end.

owncloud was installed on a new virtual machine with Ubuntu server 12.04.3 as the initial install. Immediately after the install from an ISO image, the server was updated with the latest updates.

A web search suggested that there are only install packages for OpenSuse. Later on (more by accident) we found out that Ubuntu has an owncloud package, but we didn't use that.

The instructions we followed were these:
We did put the whole owncloud content directly into /var/www. That worked for us, because the server is dedicated to the owncloud service.

Also - make sure that ssl is running.

At that point we were able to get to the opencloud server from within the local network via Firefox.

Getting to the opencloud from the Internet was done by re-directing port 8081 from to the firewall behind which all AzLoco servers sit. The firewall then does forward the request to the https port of the owncloud server.

We encountered two glitches:
Glitch1: The admin page had a line indicating that the WebDAV configuration was broken. After some investigation it was clear that the problem was introduced by our ssl certificate. Owncloud tries to check the WebDAV functionality with Curl. Curl finds it problematic that the server's certificate's DN does not match the URL under which the owncloud server is accessed.
This problem got fixed by editing the file /var/www/3rdparty/Sabre/DAV/Client.php. These two lines had to be added to the initialization of the array $curlSettings in function request:


after login, the owncloud server was directing to its IP address on the local network, rather than to The fix for this was to edit the file /var/www/config/config.php. This line had to be added to the initialization of the array $CONFIG

'overwritehost' => '',

We didn't attempt to get CA endorsed certificates, because the intent of this owncloud use is for team members, so overriding the certificate trust on the browser is acceptable. To make the Chrome browser work correctly the DN of the certificate had to be