Thread (11 messages) 11 messages, 2 authors, 2021-03-02

Re: Large latency with bcache for Ceph OSD

flat view

From: Coly Li <hidden>
Date: 2021-02-26 09:57:10
Also in: linux-bcache

On 2/26/21 4:57 PM, Norman.Kern wrote:
[snipped]
quoted
You may try to trigger a gc by writing to
sys/fs/bcache/<cache-set-uuid>/internal/trigger_gc
When all cache had written back, I triggered gc, it recalled.

root@WXS0106:~# cat /sys/block/bcache0/bcache/cache/cache_available_percent
30

root@WXS0106:~# echo 1 > /sys/block/bcache0/bcache/cache/internal/trigger_gc
root@WXS0106:~# cat /sys/block/bcache0/bcache/cache/cache_available_percent
97

Why must I trigger gc manually? Is not a default action of bcache-gc thread? And I found it can only work when all dirty data written back.
1, GC is automatically triggered after some mount of data consumed. I
guess it is just not about time in your situation.

2, Because the gc will shrink all cached clean data, which is very
unfriendly for read-intend workload. Therefore gc_after_writeback is
defaulted as 0, when this sysfs file content set to 1, a gc will trigger
after the writeback accomplished.

Coly Li



Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help