Nextcloud snap has run out of space somehow and I'm stuck

nevermind. the whole VM is wrecked somehow. wont even boot after restarting. I’m about ready to just give up self hosting this service…

I used to run NC for a few years with standard install in Ubuntu VM but it stopped auto updating and I broke some things when I tried to do it manually. I ended up starting over and I switched to installing NC as a snap since I was sold on the installation process and auto updating being so easy…

It WAS really easy, and I got things set up in no time.

The problem I have now is something went wrong (not sure what yet) but my NC snap is not functional. The web UI wont load and I don’t know how to navigate the file system inside the snap to see what is taking up all the room…

I don’t know how to query nextcloud version with a snap and no web UI and I tried nextcloud.occ as per google results and it just hangs at Waiting for PHP...

my df -h is as follows:

Filesystem                 Size  Used Avail Use% Mounted on
udev                       1.9G     0  1.9G   0% /dev
tmpfs                      394M   12M  382M   3% /run
/dev/sda2                   32G   14G   17G  46% /
tmpfs                      2.0G     0  2.0G   0% /dev/shm
tmpfs                      5.0M     0  5.0M   0% /run/lock
tmpfs                      2.0G     0  2.0G   0% /sys/fs/cgroup
/dev/loop3                 309M  309M     0 100% /snap/nextcloud/28586
//<redacted>/Nextcloud   15T  9.2T  5.3T  64% /var/snap/nextcloud/28586/nextcloud/Nextcloud
/dev/loop8                  68M   68M     0 100% /snap/lxd/21835
/dev/loop9                  56M   56M     0 100% /snap/core18/2253
tmpfs                      394M     0  394M   0% /run/user/1000
/dev/loop11                 56M   56M     0 100% /snap/core18/2284
/dev/loop5                  44M   44M     0 100% /snap/snapd/14978
/dev/loop6                  62M   62M     0 100% /snap/core20/1361
/dev/loop12                 68M   68M     0 100% /snap/lxd/22526
/dev/loop1                  62M   62M     0 100% /snap/core20/1376

Can anyone point me in the right direction?



How big is your VM Virtual HDD size?

Snap or standard installation, if there are too many files and too little space, running out of space is inevitable.

I am running snap of NextCloud for my personal cloud backup server and it’s really easy to setup and working fine.

You can either try running a VM with default OS installation with Large Virtual HDD size or you can always create a separate Virtual Disk for NextCloud data storage and then attach it with said VM, mount it and change the snap nextcloud configuration file to push data there at that sperate Virtual Disk.

You can always use snap commands to change the actual data directory of NextCloud,

  1. sudo snap connect nextcloud:removable-media
  2. edit config file to change the DataDirectory line with new location (mount point of your 2nd virtual disk or even a network share) sudo nano /var/snap/nextcloud/current/nextcloud/config/config.php
  3. Move all existing files sudo mv /var/snap/nextcloud/common/nextcloud/data /your_new_Local/Mount_point/

For more information on these snap commands, Refer here → GitHub - nextcloud-snap/nextcloud-snap: ☁️📦 Nextcloud packaged as a snap


1 Like