External Hard disk

Hi all,

I already set my NextCloud and everything working fine, i can upload/download files from my server, and the server is reachable properly from others devices…
Now i want to setup an external hdd in order add more space to my personal cloud, the HDD was readed correctly by my OS and i installed the app External storage support v 1.5.0. But during the configuration, upon check the hdd path and paste into nextcloud configuration. a red alert icon appear asking to check the configuration.

Could you please help me to solve this issue?
Let me know if you will need more info


Nextcloud 14.0.0
Operating system Ubuntu Desktop 18.04
Apache V 2.4.37-1
php --version PHP 7.1.25-1+ubuntu18.10.1+deb.sury.org+1 (cli) (built: Dec 7 2018 08:16:25) ( NTS )

1 Like

Does the user that run nextcloud have permissions set on ubuntu for the external storage?

If you run sudo -u (your www user) mkdir /your/external/storage/test

Does it allow you to create a directory?

Also what is the HDD path?

Unfortunately i cannot do that… impossible to create the directory “your/external…” File or directory not exist…

tdk@servertdk:~$ sudo -u tdk mkdir /your/external/storage/test
mkdir: impossibile creare la directory “/your/external/storage/test”: File o directory non esistente

the HDD path is /media/tdk/My Passport

If i set the path in the command i have the result below

tdk@servertdk:~$ sudo -u tdk mkdir /media/tdk/My Passport
mkdir: impossibile creare la directory “/media/tdk/My”: Permesso negato

Permission denied

When using a space in terminal you will need to backslash.

Is “/media/tdk/My Passport” The mounted location for your drive?
If so command would be, if the user that runs nextcloud is “tdk”:

sudo -u tdk mkdir /media/tdk/My\ Passport/Test

Also type these two commands then post what the result is:
cd /media/tdk
ls -l

Below the results

totale 24
drwxrwxrwx 1 tdk tdk 24576 dic 9 16:45 ‘My Passport’

Hi, do you have any updates on it?

Are you kidding me?

And your webserver user is tdk? Per default in ubuntu it is www-data. Check your configuration in /etc/apache2, there should be a setting User in apache2.conf:

# These need to be set in /etc/apache2/envvars

and in /etc/apache2/envvars?

I tried to run these commands but still doesn’t work

Note that i have set as path in the Nextcloud configuration this one:

/media/tdk/My Passport
/media/tdk/My\ Passport
/media/tdk/My\ Passport/Test

and the results are the same…

Can you show
mount |grep media

tdk@servertdk:~$ mount |grep media
/dev/sdb1 on /media/tdk/My Passport type fuseblk (rw,nosuid,nodev,relatime,user_id=0,group_id=0,default_permissions,allow_other,blksize=4096,uhelper=udisks2)

if you want to use that drive ONLY for nc it might be easier to go this way:

  1. re-format it with a linux-filesystem (eg ext4; if you want/like some advanced caps like subvols/snapshots use btrfs)
  2. use a “better” fs-label; eg NC-DATA
  3. mount it reliably with an entry in /etc/fstab (usermounts under /media are not ideal for a server)
  4. create a directory that really “belongs” to your webserver-user
  5. disallow “normal” users to u/mount it and maybe to even “see” it as a drive so it cannot accidentally be removed



Unfortunately i would like connect this hdd also to others OS if necessary…i don’t understand why i can see properly the hdd and all data from OS and i cannot mount it on NextCloud

Hi Pete,

That’s exactly what I want to do. Have my NextCloud on the internal ubuntu server OS drive and the nextcloud data files (my stuff) completely stored on the eSata external drive (sda1 ext4 1.8T), so if my old nextcloud computer craps out or needs to be redone for any reason, I have all of my stuff on the external HDD. Or, I can just move it and its drive to a new / different nextcloud server if something goes wrong.

As I’m a total new guy to Linux & Nextcloud, can you write out exactly what to type in to set it up as you described in your post?


I’m having the same issues. I have an HDD that is mounted with no difficulty, with no spaces in its name, but it won’t work with nextcloud.
It’s possible that it is a permissions issue, but in the absence of any documentation saying what the permissions should be, and the absence of any help here or elsewhere, I’m beginning to think that Nextcloud is not fit for serious use.
The documentation and support is more important than the code. Developers seem to forget that.