public inbox for linux-bcache@vger.kernel.org
 help / color / mirror / Atom feed
* can't use ramdisk as cache device. Receive "Can't attach [UUID]: cache set not found" error
@ 2016-02-16  2:40 Scott McGillivray
  2016-02-24  7:37 ` Eric Wheeler
  0 siblings, 1 reply; 9+ messages in thread
From: Scott McGillivray @ 2016-02-16  2:40 UTC (permalink / raw)
  To: linux-bcache

Hello

I am using Ubuntu 15.10 with latest nightly 4.5 kernel. Ubuntu creates
16 RAM drives as /dev/ram0 - ram16 by default and i am trying to test
bcache and use one of these as a cache device.

wipefs /dev/sdd
wipefs /dev/sdd -a
wipefs /dev/ram0
wipefs /dev/ram0 -a
make-bcache -B /dev/sdd -C /dev/ram0

At this point there were no errors output but there is also no UUID
entry in /sys/fs/bcache/. Only register and register_quiet.

bache-super-show correctly prints info about both block and cache
devices when queried but when i try to manually attach the cache
device with echo cset.uuid > /sys/block/bcache0/bcache/attach i get no
error but in dmesg i see

bcache: __cached_dev_store() Can't attach
3f2521a6-2103-4e2e-a47d-cc56558e8f7d: cache set not found

If i repeat this example but use another sd block device as cache then
it works OK.

Can anyone confirm if it should be possible to use the ramdisk based
block device as a caching device with bcache ?

I also tried to use a loop device as cache and that didn't work
either.. i got "kernel bug" in dmesg for
drivers/md/bcache/super.c:1812. RIP []
cache_alloc.isra.21+0x646/0x670[bcache]

Does bcache need the cache device to be a certain block type i.e sd 8
? Should i be able to use any block device from /proc/devices as a
cache device ?

The kernel options used for ramdisk are:

CONFIG_BLK_DEV_RAM=y
CONFIG_BLK_DEV_RAM_COUNT=16
CONFIG_BLK_DEV_RAM_SIZE=65536
CONFIG_BLK_DEV_RAM_DAX=y

Thank you.
Scott

^ permalink raw reply	[flat|nested] 9+ messages in thread

end of thread, other threads:[~2016-02-25  8:15 UTC | newest]

Thread overview: 9+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-02-16  2:40 can't use ramdisk as cache device. Receive "Can't attach [UUID]: cache set not found" error Scott McGillivray
2016-02-24  7:37 ` Eric Wheeler
2016-02-25  5:55   ` Scott McGillivray
2016-02-25  6:44     ` Eric Wheeler
2016-02-25  7:06       ` Scott McGillivray
2016-02-25  7:26         ` Eric Wheeler
2016-02-25  7:39           ` Eric Wheeler
2016-02-25  8:09             ` Scott McGillivray
2016-02-25  8:15               ` Eric Wheeler

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox