Skip to contentSkip to conversation

cache for partition based VBD?

DISCUSSION Tim Freeman 3 participants 3 messages Nov 29, 2005 – Nov 30, 2005

lore
Share & tools
lore
#0 lore raw

For partition backed VBDs, is there still an effective cache in dom0? The Linux buffer cache will affect file based VBDs, but does the partition backed VBD get around it?

I think that the Linux architecture puts the buffer cache in front of all block device access, not at the VFS layer. So does that answer the question? The dom0 disk backend driver sits "above" the buffer cache? (sorry for my crude understanding)

Thanks,
Tim

#1 lore raw
Quoted 3 lines

For partition backed VBDs, is there still an effective cache in dom0? The Linux buffer cache will affect file based VBDs, but does the partition backed VBD get around it?

Filesystem caching shouldn't happen in dom0 for the domU's and I doubt you'd want it to. Caching *will* happen at the domU level and that's where you want it -- close to your applications.

Besides, if you can run a dom0 in like 128MB of memory to devote as much as possible to your domU's, how much caching could you do?

John

Signature · 4 lines
John Madden
UNIX Systems Engineer
Ivy Tech Community College of Indiana
[email protected]
#2 lore raw
In reply to Tim Freeman
Quoted 3 lines

For partition backed VBDs, is there still an effective cache in dom0? The Linux buffer cache will affect file based VBDs, but does the partition backed VBD get around it?

AFAIK the blkback driver uses uncached interfaces to storage. Caching only happens if you're using loop devices in dom0, because that indirects through the filesystem, which will being use the page cache.

You don't want caching in dom0, really: the domU will manage its own caches (and do so more effectively than dom0 could!) anyhow, so there's no point duplicating the effort.

Quoted 4 lines

I think that the Linux architecture puts the buffer cache in front of all block device access, not at the VFS layer. So does that answer the question? The dom0 disk backend driver sits "above" the buffer cache? (sorry for my crude understanding)

AFAIK, it sits *alongside* the page cache layer, as another client of the block system proper.

Cheers,
Mark