Creating my own cloud server with Raspberry Pi 3

Last modified date

Comments: 23

Because sometimes you’ve just got to really nerd out!

The Basics

With this, the absolute minimum additional hardware you’re going to need is as follows:

  • A Raspberry Pi (I used Pi 3 B+)
  • A USB Keyboard (you’re going to be entering a load of commands into the terminal)
  • A USB Mouse
  • A micro SD Card (16 or 32GB)
  • A PC monitor (HDMI connection)
  • Ability to login as Admin to your internet router (we’ll be doing some port forwarding later in the guide & it can be helpful to reserve the IP address for the Raspberry Pi)
  • An Internet connection – you can use WiFi or Ethernet with the newer Raspberry Pi models

 

The rest will come down to what hardware you have to hand and your personal preferences for pre-installed cards, bundles and so on. Anything major I’ll note it for each part.

 

For the SD card, you can actually save yourself a little bit of step 1 below, as there’s a number of bundles you can buy off Amazon which have NOOBS pre-installed on a 16GB or 32GB SD card for you.

Also it’s very worth remembering that the Raspberry Pi by itself doesn’t come with a mains, its own case and so on, so if you’re buying everything at once, consider getting yourself a Starter Kit!

 

Additionally, if you’re like me and you’re going to be sending video files back and forth, you might want to get yourself an external HDD to mount to the storage (I’ll walk you through that too!). They’re cheap enough (£40-60) for a 1-2TB storage on Amazon.

 

What steps are covered

Although I’m not a big one for a million screenshots, I will walk you through what things to do from a completely Raspberry Pi novice perspective. I’ll assume a little bit of general IT knowledge (how to go to websites, downloading zip files, extracting etc) with the general aim being you can take your shiny Raspberry Pi out of the box, follow each of these steps and at the end of it you’ll have your own cloud storage.

This includes:

  1. Downloading and installing NOOBS and Raspbian – the easiest part
  2. Installing a LAMP server (LAMP –  Our Linux OS will be Raspbian above, Apache as the Web server, MySQL as the database management system and PHP as the scripting language) – this takes a while and is the start of a pile of terminal commands!
  3. Getting Ready to Install OwnCloud (we have to do this so that it all works when we do the next step!)
  4. Installing OwnCloud 10
  5. Mounting an external HDD for additional capacity
  6. Enabling SSL for external access

 

Although following the instructions is (relatively) straight forwards, troubleshooting issues that can appear can be user specific, especially if you miss something out of the list of commands given below. Be patient with it, don’t try to skip ahead. You need to do all of the steps above in order to get to a successful installation at the end of everything.

So with that being said, let’s get to it!

1. Downloading and Installing NOOBS and Raspbian

Now when I said you can’t really skip a step, if you have bought a pre-mounted 16GB or 32GB SD card with NOOBS, at the least you can jump to the installation part of this step. Otherwise read on!

bonus first step) You might need to format your SD card – most are now pre-formatted cards from the manufacturer but just in case, the SD Association have SD Memory Card Formatter software. This just gives the SD card a standard format which we can then use.

a) Downloading NOOBS

 

NOOBS is great for anyone from complete beginner to more advanced users as it provides you with a simple framework to get things up and running on your Raspberry Pi, so that you can then do things like build your own cloud storage, for example!

This part of the guide is the only part where you’ll need another PC as you’ll be downloading files and then transferring them to the micro SD card. Depending on what hardware you have here, you might need a micro SD card adapter to plug into a full size SD card slot, or a USB adapter which accepts micro SD cards.

Go with the full version as although it’s a slightly larger download, it comes pre-bundled with Raspbian, saving us downloading this during the main install itself.

This will download as a zip file, so you will need to extract this once downloaded onto the micro SD card.

 

b) Your First Power On and Installing Raspbian

It’s like watching a baby being born… OK, that’s a little too tech nerdy. Now when you set everything up on a Raspberry Pi, it’s important to remember that as soon as you plug in the power, it’ll just start going.

First Setup Order: plug in the PC monitor (via HDMI), the USB keyboard and mouse, Ethernet cable (if you’re not going to use WiFi – recommended). Then place the micro SD card into the slot on the underside of the board and once you’re ready to go, plug in the power!

Note: you don’t need to plug in the external USB HDD (if using for additional capacity) at this stage and can confuse you when going through the Raspbian install, so keep it to the side for now.

With it being a first boot, it’s going to go through a few checks which you’ll see whizzing by the screen and your Raspberry Pi might even reboot. Don’t panic, this is to be expected and just be patient with it.

You should eventually be greeted to a screen which looks something like this:

 

Now you want the full desktop version, not the Lite as it does save us a few steps! If you’ve connected to WiFi at this point by clicking on the WiFi icon, you’ll end up with a load of different pieces of software like what is shown here, otherwise you’ll have just the full version of Raspbian pre-loaded onto the SD card when you downloaded above (or bought a pre-made NOOBS card).

When you tick the little box on the left matching this, then click on the install icon.

If you want extra bonus points here, connect to WiFi/Ethernet before clicking install. It’ll allow the OS install to automatically run updates and setup things like local time etc.

Either way, your install will now begin and end with a full boot into the OS and you’ll be treated to the desktop:

If you’ve somehow become stuck at this point, have a look at the official documentation available for this step here.

At this point we’re about to switch into the gritty code bit, so go grab a cup of coffee!

 

2. Installing a LAMP server

I lied! We’re not installing this stuff. We’re going to run a few commands first, just to ensure that the Raspberry Pi is all up to date and ready to go with installing the LAMP server.

The biggest time going forward is going to be spent in the terminal. You can open this from the desktop by clicking the black icon on the top bar with the white  >_  symbol inside

 

Note: the good thing with the terminal is you can copy and paste the commands. When you’re in the terminal, right click and you’ll get a small menu pop-up and you can hit paste.

 

a) Configuring

So, within the terminal, enter the following command:

sudo raspi-config

Hit Enter on your keyboard to confirm

You should see a new menu appear:

 

So for these steps, they depend on what you’re going to be using and they need to match up to suit your purpose:

i. Expand the root filesystem to have enough space for the cloud
Select “Advanced Options” –> “Expand Filesystem”

This is only really needed if you’re going to be using just the SD card for your cloud. If you’re aiming to mount an external HDD, you can skip this.

ii. Change user password
For Security when accessing from the WAN

This is important at this point that you don’t set this to anything that you’re planning on using for user passwords for anything else further down the line, as this gives full access to your Raspberry Pi. Keep it secret, keep it safe.

iii. Change locale to…
Select “Localisation Options” –> “Change Locale”

Only really needed if you didn’t get the option to set your locale as part of the initial Raspbian setup. For me in the UK, this should be: en_GB.UTF8 for the USA it’ll be en_US.UTF8 and so on.

iv. Memory split, allocate 16M to video graphics
Select “Advanced Options” –> “Memory Split”

As we’re not really going to need much in the way of graphics performance, we can afford to give the Raspberry Pi a little more memory to use for other operations. So we’re going to go ahead and change this to 16 from 64 (default). It’s just a text change, so delete the 64 and type 16.

When you go back to the main config screen and hit Finish, you’ll reboot so these changes take effect.

 

b) Installing Updates for Raspberry Pi

Now for the most part, if you’re buying one off a major reseller, your Pi will be mostly up-to-date, so this won’t take time. In the terminal type:

sudo su

then

apt update && apt upgrade

If you need to run a LOT of updates, you might get prompted that you’re going to have xMB of additional install space needed and you’ll need to press Y on your keyboard and Enter to continue. Otherwise, it’ll install a few things and you’re ready for the next part.

 

c) Installing your LAMP server

Now with this we’re installing an Apache server and we’re going to want to make sure that this loads up and is enabled every time your Raspberry Pi boots up. So firstly we install with:

apt install apache2 -y

Our next step is to ensure that load and enabled at boot of your Pi:

systemctl start apache2

and

systemctl enable apache2

 

At this point, our server is in a ready state to mess around with. However, the majority of the configuration is done once we’ve got OwnCloud going.

Optional: Testing the initial install

For now, if you want to make sure it is at least working for your own sanity, open up the Chromium web browser on Raspbian (the blue globe symbol in the top bar on the left). If you enter the IP address of your Raspberry Pi in the address bar, you should be greeted by Apache2 Debian Default Page.

If you don’t know your Raspberry Pi IP address, you can open the WiFi/Ethernet connection details by clicking on it in the top right of the main Raspbian screen or you can use the command: sudo ifconfig  Next to the wlan0 entry you will see inet addr: 192.168.xx.xx which is the IP address of the Raspberry Pi.

 

3. Getting Ready to Install OwnCloud

Progress! So this is just one big command line and with it your Raspberry Pi will install all the extras we need before being able to install OwnCloud itself. So in the terminal type/paste:

 

apt install -y apache2 mariadb-server libapache2-mod-php7.0 \
php7.0-gd php7.0-json php7.0-mysql php7.0-curl \
php7.0-intl php7.0-mcrypt php-imagick \
php7.0-zip php7.0-xml php7.0-mbstring

 

This is the other part of a LAMP server really, namely the database server we’re going to be using, as well as some php scripts. Again, this will take a little while as there’s a certain amount of downloading, extracting and installing going on here, so let it do it’s thing. As it’s a lot of things going on, you’ll get an overall progress bar at the bottom of the terminal to allow you to keep track.

 

4. Installing OwnCloud 10

Now there’s a few different services out there. OwnCloud is a personal preference as it’s easy to setup, has a great GUI and is available for mobile devices as well as both web and desktop clients. As it’s an open piece of software too, there’s a lot of additional addons available for it from its web marketplace (which are free) to allow further customisation. As I’m someone who deals with a lot of media files for example, I have an image gallery view mode, built-in audio/video player and Office web editor. All to help make it easier for me to use while I study.

a) Initial Install Steps

In the terminal:

cd /tmp

This switches us to the tmp folder, as we’re only going to want to have these files for the setup of the cloud! Then:

wget https://download.owncloud.org/community/owncloud-10.0.10.tar.bz2

Once this is completed, we need to tell the terminal to extract the files:

tar -xvf owncloud-10.0.10.tar.bz2

and change the permissions:

chown -R www-data:www-data owncloud

This ends up creating a directory called owncloud, which we need to move to the html directory (it is a web service after all…)

mv owncloud /var/www/html/

Once this has finished, we exit the tmp directory:

cd

 

b) Configuring the Apache Web Server

Remember that point above where I said we’d come back to this? Well, now that the initial install for OwnCloud has been completed above, we can now go about creating some settings for Apache so it plays nice with this.

Firstly, type this into the terminal:

sudo nano /etc/apache2/sites-available/owncloud.conf

We’ll be treated to a new screen which is an edit page for this configuration file. In the space, paste in the following:

Alias /owncloud "/var/www/html/owncloud/"

<Directory /var/www/html/owncloud/>
Options +FollowSymlinks
AllowOverride All

<IfModule mod_dav.c>
Dav off
</IfModule>

SetEnv HOME /var/www/html/owncloud
SetEnv HTTP_HOME /var/www/html/owncloud

</Directory>

 

Then you Exit by pressing “Control” and the letter “X” on your keyboard, followed by Y and hitting Enter.  If you’re prompted to confirm the change, just press Enter again.

You’ll then be back in the normal terminal screen again.

Last little part for this is to create a Symbolic Link by first typing in:

sudo su

Followed by:

ln -s /etc/apache2/sites-available/owncloud.conf /etc/apache2/sites-enabled/owncloud.conf

Now for the most part your Apache server is up and running. However, we’re going to check that various modules for it are enabled. After each of these commands, you might also be prompted by the terminal to restart Apache with a command to have changes take effect, yet you can leave this until you’ve entered each of the following commands.

Firstly,

a2enmod headers

Then,

a2enmod env

Followed by,

a2enmod dir

Finally,

a2enmod mime

To restart Apache:

systemctl restart apache2

 

Now onto the database!

 

c) Creating a MySQL Database and a User

For those keeping track at home, this is the M of LAMP, which implies that we’re on the home stretch… ah to be innocent of the horrors to come. As ever, keep track of where you’re up to and it’s no harder than what we’ve done up to this point!

In the terminal, use the following command:

mysql -u root -p

Remember right back at the start of this I made you make a new password? It’s going to ask for it now. The cursor won’t move (security!) but so long as you type it out correctly, hit enter and you’ll be greeted by the MariaDB Monitor. This works within the terminal and allows us to set things up.

 

Firstly, creating the database name:

create database owncloud;

Note: the syntax is a little different here to the terminal commands, each line does end with a semi-colon!

 

Next, creating a username and password.

create user USERNAME@localhost identified by 'PASSWORD';

You can make the USERNAME and PASSWORD whatever you want (within reason), just don’t make them the same as the Raspberry Pi username and password please. Oh and don’t be that person who leaves them as just username and password please!

 

Now we need to make sure that the user has the right access. You need to remember to use the same USERNAME and PASSWORD as what was just created above:

grant all privileges on owncloud.* to USERNAME@localhost identified by 'PASSWORD';

 

Now we’re going to just flush the preferences so they’re valid by typing:

flush privileges;

 

And finally, exit back to the main terminal by typing:

exit;

 

d) Final Configuration via Web Browser (if not using external HDD and/or wanting to access off just your personal network)

IMPORTANT: Only complete this step if you’re not planning on wanting to access your cloud storage outside of your personal home/work network and if you don’t want to mount an external HDD.

 

So if you’re not doing that, enter the following address into the Chromium web browser on your Raspberry Pi:

http://192.168.1.10/owncloud

The IP (the bit in blue) you’re using here is that of your Pi, so if you remember from before you can open the WiFi/Ethernet connection details by clicking on it in the top right of the main Raspbian screen or you can use the terminal command: sudo ifconfig Next to the wlan0 entry you will see inet addr: 192.168.xx.xx which is the IP address of the Raspberry Pi.

Once there, you’re going to start pulling together a lot of information that we’ve made in previous steps. Firstly, you need to create an admin account. This is what you’ll use to login to OwnCloud in the future from your preferred device.

Reminder: don’t use the same username and password for anything you’ve used already in this setup!

The data folder location will already be filled in to point towards the space allocated on the SD card (which is why this will end up changing for those of you wanting to mount a HDD)

The MySQL database details are what you made above too:

Username: USERNAME
Password: PASSWORD
Database: owncloud
Server: localhost

 

FINAL WARNING: Do not click to finish setup here if you need to mount a HDD and/or want this to be accessible off your internal network.

Once you click “Finish Setup”, there will be a pause while the setup is completed by the software, then you’ll be able to login with your admin account details and use your storage how you want on your own home/office network!

 

5. Mounting an external HDD for additional capacity

So you’ve paid attention to the warnings above and now you just want to get your external HDD mounted and running.

This is a good time to plug in your external HDD to a USB port. Don’t worry if Raspbian says it can’t read the drive, we’re getting to that!

We’re going to make an assumption that if it’s a standard drive it’ll be using NTFS but if it’s FAT32 it’ll be recognised (which is why it’s useful to plug in now) so you can skip this very first command.

 

First, we’re going to install a NTFS package by typing the following into the terminal:

sudo apt-get install ntfs-3g -y

 

Next, we’re going to create a directory which we can mount to (start here if FAT32/exFAT drive):

sudo mkdir /media/ownclouddrive

 

As this is for the OwnCloud which was installed in www, we need to create and add a user to the www-group.

Firstly:

sudo groupadd www-data

Then:

sudo usermod -a -G www-data www-data

 

Now we need to make sure that this user has ownership of the directory and has sufficient permissions of it (otherwise our lovely cloud server won’t be able to read, write and execute files).

Firstly enter:

sudo chown -R www-data:www-data /media/ownclouddrive

Followed by:

sudo chmod -R 775 /media/ownclouddrive

 

Now similar to how we needed to check IP addresses and make sure Apache was always running earlier, we now need to make sure that the Raspberry Pi knows that the external HDD is the one that is used for this mounted drive, even if the USB port is changed after a restart for whatever reason. For this we need to get the gid, uid and the uuid. The gid and uid are usually simple numbers, yet the uuid is a touch more complex. These will be shown in the terminal with the following commands (might be an idea to make note of these!)

For the gid:

id -g www-data

For the uid:

id -u www-data

For the uuid:

ls -l /dev/disk/by-uuid

The UUID for the drive in this case is shown by the blue/green sequence followed by ../../sda1

Like other things in the terminal, you can highlight and copy this if you don’t want to make any mistakes!

 

Next we need to add the external drive to the fstab so that it’ll boot with the proper permissions with the following command:

sudo nano /etc/fstab

 

Now we’re back in the text editor and what you need to do is add in the following line at the bottom of the file (make sure to scroll down!) with the numbers from our HDD we found above:

UUID=F6941E59941E1D25 /media/ownclouddrive auto nofail,uid=33,gid=33,umask=0027,dmask=0027,noatime 0 0

Then you Exit by pressing “Control” and the letter “X” on your keyboard, followed by Y and hitting Enter. If you’re prompted to confirm the change, just press Enter again.

 

Next you need to reboot the Raspberry Pi, which you can do either from the drop-down menu by clicking the raspberry at the very top left or by typing in the following command to the terminal:

sudo reboot

 

You’re done with mounting the external HDD!

 

Final Configuration via Web Browser

Enter the following address into the Chromium web browser on your Raspberry Pi:

http://192.168.1.10/owncloud

The IP (the bit in blue) you’re using here is that of your Pi, so if you remember from before you can open the WiFi/Ethernet connection details by clicking on it in the top right of the main Raspbian screen or you can use the terminal command: sudo ifconfig Next to the wlan0 entry you will see inet addr: 192.168.xx.xx which is the IP address of the Raspberry Pi.

Once there, you’re going to start pulling together a lot of information that we’ve made in previous steps. Firstly, you need to create an admin account. This is what you’ll use to login to OwnCloud in the future from your preferred device.

Reminder: don’t use the same username and password for anything you’ve used already in this setup!

The data folder location will need to be replaced with  /media/ownclouddrive

The MySQL database details are what you made above too:

Username: USERNAME
Password: PASSWORD
Database: owncloud
Server: localhost

Once you click “Finish Setup”, there will be a pause while the setup is completed by the software, then you’ll be able to login with your admin account details and use your storage how you want on your own home/office network!

 

6. Enabling SSL for external access

This last step is specifically for those of you who want to use your install like a dropbox, google drive etc. Essentially a true cloud storage which you can access from anywhere with an internet connection.

For this we’re back to the terminal commands!

 

Firstly, we need to enable SSL with the following command:

sudo a2enmod ssl

 

Then create a new directory for the certificate:

sudo mkdir /etc/apache2/ssl

 

The next part is creating the key and certificate and placing them into that directory:

sudo openssl req -x509 -nodes -days 825 -newkey rsa:2048 -keyout /etc/apache2/ssl/owncloud.key -out /etc/apache2/ssl/owncloud.crt

It’s answer the questions time! The terminal will throw questions at you and for the majority of them you can leave them blank or fill them in with whatever you feel like. However, when it comes up with the "Common Name (eg server FQDN or YOUR name) []:"  question, fill this in with the local IP address of the Raspberry Pi that you found earlier!

 

Now it’s important to note that the 825 days is the duration this will be valid for and for me this was more than long enough for me to have finished university hopefully! If you’re wanting to do this properly, all new SSL certificates issued officially should be valid for a period no greater than 825 days. Most are 1 year (365 days) but as we’re self signing this for the sake of your own access, we don’t strictly speaking have to have a properly certified certificate, as it’s more useful for if you were going to give others access (which isn’t something I’m covering in this guide).

 

Moving on! We now need to go into the config file and add in what is needed for our server, so enter the command:

sudo nano /etc/apache2/sites-available/default-ssl.conf

What we’re doing here is adding in the server IP address (this is the local network IP for the Pi that we found earlier!) and port of 443, making sure the SSL Engine is On and changing the addresses to the key and certificate based on the locations we created just above.

 

As I have been using the 192.168.1.10 as my example local IP, adding :443 at the end instructs this to use port 443. If this line isn’t there, this is just like editing a standard text file, just add the line in.

The SSLEngine on can also be edited just by deleting off if there and typing in on.

The changed locations for the key and certificate are noted at the bottom of the screenshot to match what we made above.

Then you Exit by pressing “Control” and the letter “X” on your keyboard, followed by Y and hitting Enter.  If you’re prompted to confirm the change, just press Enter again.

 

Next we need to activate the virtual host with the following command:

sudo a2ensite default-ssl

 

And finally restart Apache:

sudo service apache2 restart

 

WAN IP and Port Forwarding

The last part is also the hardest for me to show, as a lot of it depends on your router.

First, we need to find out what your actual public IP address is (or you WAN IP). Quickest way is just by searching in google “what is my IP address” and it’ll tell you. This will be different to the local network IP address for the Raspberry Pi as this is how the rest of the world “sees” your active connection (as most users will have a single line connection).

What we’re going to do is to go in and edit your OwnCloud config file to reflect this WAN IP, which will give it access to the outside world! Enter the following command into the terminal to open up the editor for the config file:

sudo nano /var/www/html/owncloud/config/config.php

First, below where you’ll see your local IP address, create a new line and add in your WAN IP.

Then, on the ‘overwrite.cli.url’ line, change the address from your local IP to your WAN IP leaving the /owncloud at the end  (making sure it starts with https:// also!)

 

Then you Exit by pressing “Control” and the letter “X” on your keyboard, followed by Y and hitting Enter.  If you’re prompted to confirm the change, just press Enter again.

 

This is the part where it depends on your router!

What you need to do is to login to your router as an admin. Usually this address is http://192.168.0.1 but check with your manufacturer or internet service provider.

Once logged in, you’ll need to find the section in its settings for port forwarding. It might ask you to add new rule, create exception… again, check with the router provider!

Once in port forwarding, you’ll need to make sure that the router allows traffic through port 443 (which we setup before) from your raspberry pi. It might let you click the device from the list or it might ask you to enter the device IP, which is when you enter that local IP for the Pi one more time!


 

THE END

Believe it or not, you’re all done!

If you’ve followed every step, you’ll now have your own cloud service, complete with a large external storage for all of your things, accessible by going to https://Your WAN IP/owncloud

Chris

Share

23 Responses

  1. Very well written! I printed these out and followed them to the letter. I have a Raspberry Pi 3 and used a 64GB SD card and a 2TB USB external drive. There were only two items I noticed. First, regarding mounting the USB drive, instead of allocating my whole drive to owncloud I only wanted to partition a subdirectory. When starting the web page I was getting errors “Please change the permissions to 0770…”. After some searching I found that in my /etc/fstab I had to use the following options: quiet,defaults,permissions,local=en_US.utf8. I changed these and it worked like a charm. Secondly, page 8 (Creating a MySQL database, you mention setting a password for the root account. I must have missed this somewhere I can’t find where this was set!

    • So there’s a few things here! You can partition your SD card if you want, yet you have to be sure you’re writing permissions for it correctly which is where you came a little unstuck. Locale is a small but vital part of the initial setup of the LAMP server (section 2) so although I had mine for UK, I’m assuming you’re in the US if that’s what fixed your issues there? That’s also the same section for setting a new user password.

      A lot of folks skip over these if they’re using existing hardware versus a new out the box Pi as they’ve already set the password and locale to something other than default! So don’t feel bad for missing it as they’re only small steps in what is a loooooong guide!

  2. How to make trusted certificate?
    Get this message: This CA Root certificate is not trusted because it is not in the Trusted Root Certification Authorities store.

    • So the last step is how to manually create your own certificate, yet as you’re not storing/creating this with an official certification host, that’s why you get that message. If you want to do this “properly” so it shows as a valid security for a https site (which you don’t really need as you should know what’s on your own setup!) then you can use services like this to go through and create a free certificate yourself: https://letsencrypt.org/getting-started/

  3. Hello Chris,

    I have a Rasperry pi 3 b+ and your instructions helped a lot. However, when it came to the last part, adding the wan ip I got stuck. So I went to google and type in my wan ip from my raspberry pi. After I entered my wan ip and finished editing that nano file.

    I typed in :
    https://my_wan_ip/owncloud (I entered my actual wan ip that google gave me into the url).

    When I typed this in, it took me to duckduckgo suggestions instead of my owncloud. In addition, when I types in my_local_ip_address/owncloud I was not able to access it all. I get errors regarding exception.

    I am very confused on what I need to do to fix this problem.

        • So as long as your Pi localisation is set to US, then it should be fine. The reason for setting the localisation is so the Pi knows how to communicate correctly with your router. So if you’ve just followed my stuff to the letter and not adjusted it (as I live in the UK) then you’ll get this error.

    • It’s not a port thing. This step usually goes wrong if you’re not selecting the correct region to match your location (see section 2 of this guide!)

  4. Hi Chris! I’ve been follow this tutorial step by step, but at time to “finish setup” in owncloud through the navigator, owncloud show me a message telling that data directory is not valid, and i’ve got to verificate if the file .ocdata is in the root directory.
    What can i do with that issue?
    Thanks in advance!

  5. Hello, I’m here again. I would like know if it’s possible to change mounted external hdd for another external hdd, and how it would be. Thanks you in advance!

  6. Chris – this really is a first rate tutorial. Thanks for the effort you have put in. All worked well for me until i tried to go SSL. I have a dynamic external IP so I use duckdns to keep it in check. I entered xxxx.duckdns.org and https://xxx.duckdns.org/owncloud in the owncloud config.php. When I used that URL in the browser I got the usual warning about unsafe certificates. When I proceeded anyway I got “404 not found”. The LAN address works fine. Any thoughts?? Much appreciated and again, great tutorial.

    • Sorry about the late reply, I’ve been traveling with work this week!

      So there’s a few things at work here!

      First, the LAN address will always work mainly as your home router will set the address for your Pi and excluding some serious issues, will remain the same. So that’s why that’ll work regardless of external output.

      Secondly, for external IP, the reason it needs a fixed address is essentially so the internet at large knows where to go when you type in the address. There’s no getting around that as such. If you’re using a dynamic IP from a provider, you would have to contact them about providing you with a fixed IP address or using another 3rd party.

  7. Hi Chris,
    thanks for your nice and easy tutorial. Everytheing worked until step 5. After I finished the setup on the Owncloud site I could not access my cloud. It said: “Please change the permissions to 0770 so that the directory cannot be listed by other users.” Did I do anything wrong? Do you have a suggestion?
    Many thanks
    Luke

    • When you’re installing OwnCloud and you’re checking the user permissions, did you change anything outside of the guide or skipped bits? OwnCloud defaults to 0770 for internal network storage purposes, so normally when you’re setting up for external use, that’s where this is changed.

      If you see section 5 of the guide, the NTFS package install (onto whatever you have installed OwnCloud onto) will resolve this as one of the steps is: sudo chmod -R 775 /media/ownclouddrive

      That is specifically changing the user permissions to 775 from 770.

  1. Pingback: Raspberry Pi/OPi/BPi - MicroPi

Leave a Reply

Your email address will not be published. Required fields are marked *

Post comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.