I have a btrfs file system on my media server. It was my first time setting up a system with btrfs and I thought it would be a good idea to separate different types of media into different subvolumes, so that I could create snapshots for them separately. There are two sub volumes:
A program I'm running (sonarr to be excact) automatically downloads movies and tries to create a hard copy between
/media/movie once completed. Turns out hard links between btrfs subvolumes are not possible, so sonarr falls back to copying. This unnecessarily creates two copies of a file which hogs up the disk space.
I've tried solving this by using out-of-band deduplication, as in-band dedupliocation is not yet supported as far as I'm aware. Using
duperemove I get around 2GB/hour of data that's freed, but it's too slow for me.
I've decided it would be a good idea to dump the subvolume setup I had before and use a single btrfs volume for everything. Looking at the man page of
btrfs subvolume it looks like all the data in subvolume is lost when it is deleted. Is there a way to "transfer" data ownership from a subvolume to the parent volume before deleting the subvolume so that I could keep the data?