Ubuntu 16.04 LTS as an ownCloud server

Secure Collaboration

Basic Setup

In the browser window, ownCloud prompts you to create an admin account and also lets you configure the desired database (Figure 2). The recommended admin username is admin . The password should be secure, of course, but it doesn't have to match the root user password in MySQL. To launch the MySQL configuration process, click MySQL/MariaDB under "Configure the database." The password is the password from the CREATE User command in Listing 3; owncloud is both the username and the database name, and localhost is fine as the host designation. Clicking Finish setup completes the installation. If everything worked, the ownCloud web interface should now appear for the first time (Figure 3). OwnCloud lets you know about the ownCloud clients for Android and iOS, but you can click to close the message without worrying about any negative consequences.

Figure 2: The initial configuration of ownCloud defines the username and the password of the admin user and lets you configure the database.
Figure 3: After the first login, ownCloud is empty and waiting for action. Now, the real work can start.

Additional Settings

Although ownCloud generally works well as it is, various tweaks can improve the functionality of the environment. Clicking on the name assigned to the admin user at top right and pressing Administrator brings up the ownCloud configuration panel. In the menu on the left, clicking Cron takes you to the configuration window for running recurring tasks. ownCloud offers several options. Out of the box, it runs tasks every time the site is loaded. Although this ensures that the maintenance tasks are performed reliably, it also restricts performance. It is better to leave this task in the competent hands of the Linux cron command. Entering

$ sudo crontab -u www-data -e
*/15 * * * * php -f /var/www/owncloud/cron.php

opens the crontab of user www-data and makes sure maintenance tasks take place regularly. In the ownCloud cron configuration window (Figure 4), switch from Ajax to Cron .

Figure 4: After creating a matching entry in cron, you can now configure ownCloud in the web interface to improve performance.

A few changes are also useful outside of the ownCloud web interface. In the /etc/php5/apache2/php.ini file, you need to assign sensible defaults. A value of 2G for upload_max_filesize and post_max_size and of 200 for max_file_ uploads make sense for modern servers. Your installation is now ready for operation.

Conclusions

Cloud-based collaboration is on everyone's lips, but many companies shy away from putting their data in the hands of providers. A locally installed ownCloud offers an alternative. Version 9 comes with some useful features, such as CalDAV and CardDAV support, as well as improved security. On an Ubuntu 16.04 LTS server, you can quickly set up the cloud environment. The Ubuntu operating system is supported by Canonical updates for five years, so you can look forward to a stable and future-proof environment.

Infos

  1. Generating SSH keys: https://confluence.atlassian.com/bitbucketserver/creating-ssh-keys-776639788.html
  2. "Getting a Free TLS Certificate from Let's Encrypt" by Hans-Cees Speel, ADMIN , issue 33, 2016, pg. 50: http://www.admin-magazine.com/Archive/2016/33/Getting-a-free-TLS-certificate-from-Let-s-Encrypt

The Author

Martin Gerhard Loschwitz works as a cloud architect at SysEleven. He works with OpenStack, distributed storage, and Puppet. He also maintains Pacemaker for Debian in his spare time.

Buy this article as PDF

Express-Checkout as PDF
Price $2.95
(incl. VAT)

Buy ADMIN Magazine

SINGLE ISSUES
 
SUBSCRIPTIONS
 
TABLET & SMARTPHONE APPS
Get it on Google Play

US / Canada

Get it on Google Play

UK / Australia

Related content

  • ownCloud

    ownCloud is an alternative to the many online storage services whose data protection promises could turn out to be as nebulous as their offerings.

  • Fast and scalable ownCloud Infinite Scale
    A complete rebuild of ownCloud delivers the speedy and scalable ownCloud Infinite Scale file platform.
  • Nine home clouds compared
    Dropbox was the first of a number of cloud service providers. However, only services that promise full control over your own data can give users a feeling of security. We provide an overview of nine cloud projects and two BitTorrent tools.
  • Spotlight on the Kubernetes package manager, Helm
    A Helm chart is a template of several parts that defines, deploys, and upgrades Kubernetes apps and can be considered the standard package manager in the Kubernetes world.
  • Novell Filr 1.0 tested
    External staff, home offices, individual smartphones, and cloud services like Dropbox can easily drive a security-conscious admin crazy. But, Novell's Filr file storage system is designed to solve most of these problems.
comments powered by Disqus