Caching both SSD and spinning disk
Posted: Wed Jul 13, 2016 6:11 pm
Hi,
I have an SSD and spinning disk. The OS is on first partition of the ssd. Currently I have following cache setup:
Cache Task 1: - caching of spinning disk
4GB L1 read cache
20 GB L2 (last partition of the SSD)
Cache task 2: caching of SSD
5GB L1 - read cache
No L2
L1 cache ratio - 98%
I rarely use the spinning disk so usually total read for a day is about 100-200 MB.
Read on OS partition (C:) however is 5 to 10 GB/day and it comes mostly from cache. If I reduce the cache of OS partition cache ratio gets a lot worse.
If I merge the two tasks the OS partition would benefit from better caching because of the more ram and I can reduce the total ram to (for example) 6GB. However I don't want parts of OS2 partition being stored on L2 because it's actually quite a lot of writing 3 to 6 GB/day. But if I remove L2 cache then the spinning disk will have poor ratio because it's mostly benefiting from L2 cache (almost always when I use it it's after restart).
What I need is currently not existing (correct me if I'm wrong). There are few features that if added to primocache would solve my problem:
1. option ti disable writing to L2 cache data of it's own hard disk. Actually it may not be an option, but hardcoded. Who will want to L2 cache it's own contents.
2. Being able to mark hard disk as ssd and disable L2 caching for SSDs
3. Similar to creating L2 cache partitions L1 can be set to partitions outside of cache tasks. At each cache task instead of selecting L1 memory size, an L1 "partition" will be selected. This will allow to share L1 memory between tasks.
Because I don't know how hard it is to implement these options I leave it up to you. Also you can come up with different solution.
I have an SSD and spinning disk. The OS is on first partition of the ssd. Currently I have following cache setup:
Cache Task 1: - caching of spinning disk
4GB L1 read cache
20 GB L2 (last partition of the SSD)
Cache task 2: caching of SSD
5GB L1 - read cache
No L2
L1 cache ratio - 98%
I rarely use the spinning disk so usually total read for a day is about 100-200 MB.
Read on OS partition (C:) however is 5 to 10 GB/day and it comes mostly from cache. If I reduce the cache of OS partition cache ratio gets a lot worse.
If I merge the two tasks the OS partition would benefit from better caching because of the more ram and I can reduce the total ram to (for example) 6GB. However I don't want parts of OS2 partition being stored on L2 because it's actually quite a lot of writing 3 to 6 GB/day. But if I remove L2 cache then the spinning disk will have poor ratio because it's mostly benefiting from L2 cache (almost always when I use it it's after restart).
What I need is currently not existing (correct me if I'm wrong). There are few features that if added to primocache would solve my problem:
1. option ti disable writing to L2 cache data of it's own hard disk. Actually it may not be an option, but hardcoded. Who will want to L2 cache it's own contents.
2. Being able to mark hard disk as ssd and disable L2 caching for SSDs
3. Similar to creating L2 cache partitions L1 can be set to partitions outside of cache tasks. At each cache task instead of selecting L1 memory size, an L1 "partition" will be selected. This will allow to share L1 memory between tasks.
Because I don't know how hard it is to implement these options I leave it up to you. Also you can come up with different solution.