How can i check how much space has been used please?

I am unable to know how much space has been used or how much space is remaining on my raspberry pi dietpi owncloud server can someone please help to find out, even if it’s command line only over ssh I am good with that, I was thinking if there is no way to do it within owncloud then there must be ways to list the external usb hdd and the internal sd partitions so you can calculate missing space?

Any help would be greatlt appreciated thanks in advance.


as far as I know you can’t see the whole used space from an admin account in the web interface. It would be a nice feature though.
On the command line side, you have to find first where is stored your ownCloud data. The data directory is by default /var/www/owncloud/data. You might want to check your own config.php.
Afterwards, you just have to do:

df -h <your_partition>

EDIT: moderators, could you move this thread to the server section please ?


What partition var/www/owncloud? I’m thinking no that is a folder not a partition?

It’s indeed a directory but it could also be a partition.
Nevermind, did you check where was your data directory ?
You can do a df on a directory, it will show you the used size of the partition then you can do a du to find out what’s using disk space.

1 Like

Sorry I am a total newbie don’t follow what a du is I set it up using the following guide all works mobile data connecting and home networking and I am in ssh on putty to control it via terminal to copy paste commands over.

I added my own usb hdd and can see it comes up using fdisk -l but shows sda1 and it’s size but not if files exist using the command to check that so in order to know and keep track of usage I would love to know how to get the current partition size for the cloud drive to know where I am with it all the time as it is a really small 80gb drive see. And it will be used for streaming mp3’s as I make music.

But I may want to put my dvd collection or part of on it so would really need to know the size for that all the time.

Also tried the command I think it’s supposed to be this you meant

root@DietPi:~# df -h var/www/owncloud
df: var/www/owncloud: No such file or directory

Says unknown

I said /var/www/owncloud/data not var/www/owncloud/data

Just do a df -h and post it there.

1 Like

root@DietPi:~# df -h
Filesystem Size Used Avail Use% Mounted on
/dev/root 29G 5.0G 23G 18% /
devtmpfs 484M 0 484M 0% /dev
tmpfs 488M 0 488M 0% /dev/shm
tmpfs 488M 13M 476M 3% /run
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 488M 0 488M 0% /sys/fs/cgroup
tmpfs 50M 84K 50M 1% /var/log
tmpfs 10M 1.4M 8.7M 14% /DietPi
tmpfs 1.0G 4.0K 1.0G 1% /tmp
/dev/mmcblk0p1 253M 54M 199M 22% /boot

I realise it is a old papta drive at 50gb now just to test it with for a while, but that doesn’t show up, the 32gb sd does and I am sure it said 25.xx GB size before uploading a 2.6gb file to test it so pretty sure it’s using the sd not the needed 50gb hdd???

Worse case senarion if I save those pennies is I go 128gb eventually on a sd and have done with caring but to be fair it works and the sd is small but could clone it over anything in win32diskimager/balena etcher or hdd raw copy tools.

But I would really like to get that 50gb going for now so I know I can by a caddy and go 1tb then.

If your ownCloud is correctly installed and working now, then I guess it’s using the SD Card.
Probably your HD is not mounted, it looks like it’s not an ownCloud related problem.
You might want to learn how to mound a HD on a PI (carreful to use a correct power supply) but it’s not really the place for that here.
Good luck.


Ok thanks I will look into it. Thank you kindly for all the assistance though appreciate it truly I do.


If you want to display the usage of a directory only (not a partition), I’d recommend the du utility:

 du -hs /var/www/owncloud/
1 Like