Remove a drive from a Cache pool

Recommended Posts

So I had 2 250Gb SSDs as my main cache. They were in RAID1.

I used this cache as a temp download for SAB. And as much as I download I didn't like all the extra writes to the drive.

I got another 120Gb SSD and want to use it as a scratch disk for mainly downloads, and didn't care for any protection on it.

I tried using Unassigned devices to mount it, but docker and SAB didn't play very nicely.


So I just ended up going to the cache tab and adding the 120Gb ssd to the 2 250Gb.

Now it created a pool of 310Gb. but I want to get the drive out. When I remove it, it freaks out.

When I connect to the share, it still says its only 250Gb.

I haven't balanced it the pool or anything.


I just want to know how to remove it before I screw it up more and lose the data.

I just want the drive back out of the "pool" and the orginal 2 250 back in RAID1.

Link to comment

-if there's important data on the cache pool backup in case something goes wrong.

-stop array

-unassign the SSD you want to remove

-clear it by typing on the console:


blkdiscard /dev/sdX

replace X with actual letter.


-start the array with the only two remaining cache devices, check that cache pool mounts and on the cache webpage "btrfs filesystem show" total devices are correct and it's not displaying "***some devices missing"


Link to comment
  • 2 weeks later...

I cannot find any documentation on balancing cache pools.


I go to the 1 cache drive, on that page it says this.

No balance found on '/mnt/cache'


I clicked balance and in the syslog it prints

Oct 29 11:49:48 MediaServer php: /usr/local/emhttp/plugins/dynamix/scripts/btrfs_balance 'start' '/mnt/cache' '-dconvert=raid1 -mconvert=raid1'


I don't know if that worked or not, if it's in the process of balancing or what.


Link to comment

Sorry for all the hassle.


When I execute the command

root@MediaServer:~# btrfs device remove /dev/sdi /mnt/cache


If the array is started I get

ERROR: error removing device '/dev/sdi': Device or resource busy


If the array is stopped I get

ERROR: cannot access '/mnt/cache': No such file or directory


Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.