I have a problem with the space left on my turris. Since yesterday all the disk space is consumed but I am unable to track down the specific location.
Here’s some related info
Could you check what exactly takes 500 MB in /usr? This is really big.
This snapshots are a feature of the btrfs file system. They work a bit like Shadow Copy in Windows. If you delete a big file that is already in a snapshot it won’t give you any free space. If you copy it again on your turris it will take new space. This is something you should take into account.
They won’t help you with rollback using the reset button if you have them on an external storage.
If the config in the repo is the same as on the device then you may end with up to 16 automatic snapshots. This means they have to be under 500 MB in average.
The 500mb file in usr is my snapraid content file, which is there on purpose. I’m using 2 parity so I have to keep 3 different content files on 3 physically different devices (one internal, one on the disk array, one on an sshfs mount).
Yes I though that having them on an external device wont work very well together with the reset button. Is it possible to exclude the internal lxc folder (srv/lxc) from the snapshots?
Yes but this is nothing simple. Snapraid images are kinda bad for this. I would use an usb stick for this. Maybe the no-cow flag helps on this file. chattr +C snapraidimage But i would have to read some docs to give an answer.
From my understanding, this could be possible if you made that folder as a subvolume of the very root of the Btrfs filesystem, not the subvolume of current TurrisOS root:
The last command have to be repeated after every reboot. I haven’t figured out yet, how to automate mounting of subvolumes properly, since the native OpenWRT block mounter refuses to mount the same device more than once. I guess you can always put it into rc.local, there may be, however, some race conditions with containers starting up earlier.
Just a clarification: Btrfs does not support recursive snapshots. So even creating a subvolume nested under a regular volume does solve this issue. It should be therefore sufficient to create a subvolume for LXC containers like this: