How reliable is ownCloud

Owncloud as a Dropbox alternative: This is how the Mac becomes a server

Christian Rentrop

A new ECJ ruling calls into question the data protection of transatlantic cloud solutions. Fortunately, there is an alternative: Your own cloud on your own Mac. We'll show you how to set this up.

EnlargeWith Owncloud you can set up your own personal cloud on the Mac or any other web server.
©, Natalia Merzlyakova

According to a new ECJ ruling, the EU-US Privacy Shield is invalid: the agreement originally ensured that cloud services were also allowed to transmit data to the USA. This is no longer legal: If companies fall under US surveillance laws - and that includes all major American IT companies alongside Apple - automatic data transfer to the United States is no longer permitted. Anyone who wants to host important data in the cloud should be aware of the fact that they will always be stored on a third-party computer. That doesn't have to be the case: With Owncloud you can conveniently store your data at home or in your company - and still access it from anywhere, just like with known cloud services. All you need is a Mac and a little software. "

Every Mac with macOS is a powerful Unix computer - and therefore basically also suitable as a web server. With the necessary tools, an Apache web server including PHP and MySQL database can be set up under OS X in just a few simple steps. This web server can then work as a private cloud at home, all you need is the Owncloud software, which can of course also be set up on any other web server with Apache, MySQL and PHP, for example on a web space. In the following we would like to describe the way to turn a Mac into an owncloud server - and to store data really safe in your own living room in front of the NSA and Co.

Sure: Many NAS systems offer similar functions, Synology systems even allow Owncloud installation - but why buy an additional device when an existing Mac can take over the task? In particular, if the Mac is installed anyway, connected via Ethernet cable and used continuously, because it is a media server Mac Mini or a living room Mac, Owncloud can provide practical services as a small additional function at any time.

What Owncloud can do

Owncloud is a comprehensive open source cloud that runs on all systems on which a web server is installed. In addition to the NAS already mentioned, these are also smaller computers, even the good, inexpensive Raspberry Pi can be set up as a cloud computer with a little manual work. Owncloud supports all conceivable cloud functions: from pure file exchange to the synchronization of entire folders like with Dropbox to your own picture gallery in the network, the synchronization of contacts and calendars, collaborative work, the playback of music and films. The advantage over services such as iCloud, Dropbox, Google and Co. lies primarily in the security of the data when you host the cloud at home: While typical cloud services based in the USA seldom encrypt the data on the computer offer, but on the other hand are forced by the Patriot Act to disclose data that they can access, important data should only be stored here in encrypted form, if at all. Even then, however, you cannot be sure whether there are any back doors or attempts at decryption. You are only safe if you host the cloud yourself; This is exactly what Owncloud does when you install the software on your own computer in your own four walls - of course only if the passwords are secure and the data is regularly backed up and the Mac ideally with a Kensington lock or another security system Is anchored in the home or office.

Install owncloud in MAMP

First set up the MAMP server, which you can download from, under OS X. (Read here: Setting up your old Mac as a server). The system is very simple because it has all the necessary functions directly on board. Although OS X itself also has an Apache server, which can be easily equipped with PHP and MySQL, the MAMP solution makes things much easier and, on top of that, higher performance because it is the latest version of the server environment. How you do it is of course up to you - you can rely on both MAMP and the internal Mac Apache. Once everything has been set up, your web server can first be reached locally at http: // localhost: 8888. Websites must be set up in the htdocs directory, which is located in the MAMP folder in the programs directory. You should therefore download the owncloud installer from the owncloud website; the “owncloud server” should be loaded here as a web installer, as this is the simplest method of setting up an owncloud server in MAMP. The setup-owncloud.php is then simply placed in the MAMP folder "htdocs". From there you can start the installation of the owncloud software on the Apache server in the browser at the address http: // localhost: 8888 / setup-owncloud.php.

EnlargeOwncloud can be downloaded free of charge from the Owncloud website.

Run through the installation routine

Since the MAMP server package is preset, you now only have to run the installation: After calling the installer, start the installation with "Next".

EnlargeOwncloud installation is child's play with the setup wizard.

Then you only have to specify whether you want to install Owncloud directly in htdocs or in a subdirectory. The preselection, the “owncloud” directory, makes sense and should be used. The actual installation then takes a few minutes, depending on the speed of the internet connection - the installer loads the Owncloud files from the network.

EnlargeThe setup routine will now download all files, which can take a while.

That's it: As soon as the installation is complete, Owncloud is installed. Conveniently, the software uses the SQLite database by itself, which means that no further setup steps with MySQL are initially necessary. However, the use of the more solid MySQL database is recommended as soon as you start somewhat more extensive projects with Owncloud. The basic version is of course sufficient for a test run on the Mac - but if you have more plans, you should switch directly to the MySQL database. How to do this is explained below.

EnlargeSuccess! Owncloud has been installed on the Mac!

Create an administrator account

In the next step, Owncloud warns that it is not properly supported by OS X - an error message that you can ignore. Owncloud requires the creation of an administrator account for further use. Enter a username and a secure (!) Password, after all, Owncloud may soon contain your important data. Sufficient length and complexity - don't forget special characters like "#" and "$" - ensure that attackers have little chance of cracking the password.

EnlargeYou can safely ignore the warning message. If you don't want to use MySQL, you can use Owncloud now.

Optional: Change the database system to MySQL

If you want to have a solid database connection right from the start, you can switch to a MySQL database here by clicking on "Storage & Database", which is recommended. To do this, call up the MAMP start page again in a new browser window (http: // localhost: 8888 / MAMP /? Language = German) and select phpMyAdmin (http: // localhost: 8888 / MAMP / index.php? page = phpmyadmin & language = German): You will be redirected to the MySQL environment. In the "User" tab, create a new user named "owncloud" on localhost and assign a password for him. Check "Create a database with the same name ..." and "Grant all rights to databases ..." as well as "Select all" under global rights. Then confirm with "OK".

During this process, a new SQL database called "owncloud" is automatically created - you can now use it for Owncloud. Simply switch back to the browser tab with the Owncloud setup and click on "Storage & Database". Enter the MySQL user name that you created above, together with the database of the same name and the user's password.

EnlargeSetting up a MySQL database for Owncloud, even if it seems complex, is quite simple.

Complete installation

But regardless of whether you rely on the simpler solution with the SQLite database or prefer to put your entire Owncloud system on a solid footing from the outset with your own MySQL database: To complete the installation, you now have to click on “Complete installation “Click.

EnlargeSetting up the MySQL database is not mandatory, but it ensures stable operation and saves the laborious rebuilding of the Owncloud system later.

The installation of the Owncloud system on the Mac is now complete: If no error message occurs, but you see the Owncloud start page with a reference to the Owncloud apps for OS X, iOS and Android, your Owncloud server is now set up and ready for use - All you have to do now is ensure that it can also be reached from outside and that it works as reliably as possible. You will learn how to do this in the next few steps.

EnlargeThe setup via localhost worked - now the cloud only has to find its way out.

Make Owncloud accessible from the outside

Now it's time to get down to business: Your Owncloud server is active, but currently only accessible in your network. You now have to ensure that you can also access it from outside, which you can do most easily via port sharing on your router. We are going through this step at this point using a Fritz! Box as an example, but of course this also works with better routers from other manufacturers. First open the router administration in a new browser window, log in and select the "Port sharing" tab under "Internet -> Approvals". Here you have to enable ports 8888 and 8889 for MAMP and MySQL on the computer on which the MAMP system is running. In addition, you can set up a dynamic DNS service such as in the router under “Internet -> Approvals” in order to avoid problems with changing IP addresses. To do this, you need to create a free user account with the Dyn-DNS service and then enter the data in the "Dynamic DNS" tab.

EnlargeIn order for the server to be able to communicate with the outside world at all, it must be forwarded to the Internet via port sharing.

Now you can already from the outside at the address http: // (your-external-IP-address): 8888 / owncloud / Access your Owncloud installation via LTE from your iPhone / smartphone to test whether the connection is basically working. However, this only works halfway for now: an Owncloud page opens with a warning, but every click leads to nirvana. Owncloud's security setting is to blame: the domain name or IP address must first be entered as trustworthy domains. This is for the security of Owncloud, as it cannot be accidentally reached with wrong domain names. This is not so important in home networks, but this setting is essential on servers that host multiple websites.

EnlargeOwncloud's trusted domains function initially prevents external access.

To bypass this lock, you have to edit the "config.php" file in the Config directory of the Owncloud folder (located under (/ htdocs / in the MAMP folder), for example with the free and excellent text editor Tincta. Set up both the current external IP address and any DynDNS forwarding here by clicking in the line

Enter the domain names in brackets after “array”, for example the domain and the IP address under which your owncloud server can be reached from outside, for example “” or “”. The line must then look like this, paying attention to the single quotation marks:

EnlargeThe lines of code for Owncloud can be typed in with the Tincta text program.

You can then save and close the config.php. The domain names under which Owncloud can be reached are now entered in the configuration file. If you now call up your IP address or the DynDNS address via LTE with your smartphone, the Owncloud login screen appears: Congratulations, your personal cloud is now accessible from the Internet and ready for use. If that doesn't work, you may have to specify the port number, for example: or similar, based on your individual configuration. Owncloud works on the Mac and is accessible from the outside.

EnlargeIf the domain is entered correctly, external access to the Owncloud server will also work. If a login window appears, everything went as planned.

Set Wake-on-LAN on the router

A few small setup steps are now required on the Mac in order to prepare the Owncloud server for continuous operation: You have to ensure that the Mac does not fall asleep and, if it does, is woken up again when you connect to the cloud from the outside connect.Therefore, make sure that you have activated the option “Wake on LAN” in the “Home network” setting of the Fritz router on the Owncloud computer. In this way, the router - provided it is connected to the Mac via an Ethernet cable - wakes up the computer as soon as you access it from outside. Wake-on-LAN does not work via WLAN, unless you are using an Apple airport router. Basically, however, connecting a server via WLAN does not make sense, so the cable connection between the server Mac and router is mandatory.

EnlargeWith the router's Wake-on-LAN function, you can automatically wake up a computer connected via an Ethernet cable as soon as it is accessed from the network.

Set energy saving options on the Mac

In addition, you should set the Mac so that it does not go to sleep in the first place. To do this, open the system settings on the computer and then the entry "Save energy". Here you have to check the box next to “End sleep mode when network access” to ensure that the router is also allowed to wake up the Mac.