spantaleev / matrix-docker-ansible-deploy

🐳 Matrix (An open network for secure, decentralized communication) server setup using Ansible and Docker
GNU Affero General Public License v3.0
4.83k stars 1.04k forks source link

Move and Change all Media directory #3644

Open ToddCrimson opened 5 days ago

ToddCrimson commented 5 days ago

Small, private, family only server, but slowly growing over 2 years.

Matrix Server:

Ansible: If your problem appears to be with Ansible, tell us:

Problem description:

Running out of hard disk space on my VSP. So I keep cleaning old Media files. But now I have purchased and attached 40 gigs of block storage for super cheap to my Debian. It's available and running.

I'd like a method to move all my media to that block storage, and make that the default location for storage. I have full root access ofcourse. Could someone please help me?

Also, after I make the change, I'd like to make sure future upgrades, respect that.

Client (please complete the following information):

Additional context Thank you in advance

joolsr commented 2 days ago

Hi I don't think this is really the right place for this as its something you can do yourself in Linux rather than being added to the script. What i would do is to add a new /media/new mount point to point to your new storage,, then something like add a symlink to existing main media dir. Or you coudl move all your data to new media dir and symlink this from the old one.

Otherwise if you have LVM you could do something with LVM volumes instead.

There's probably a few other ways you can do this to, depending on file system. For example if you're using btrfs you could add a disk in a similar fashion as you might expand with LVM.

Hope this gives a few ideas for you to Google on ..