Question about ZFS arc cache and page cache

Andriy Gapon avg at FreeBSD.org
Thu Feb 20 09:00:59 UTC 2014


on 20/02/2014 03:29 George Kola said the following:
> I have a question about what happens when a file on a ZFS filesystem is mmaped into memory. I traced it on illumos and found that the file pages made it into the ARC cache and then I got a copy of it in page cache which was then mapped to my address space. Another process mapping the same file got the same page from the page cache. (I used mdb and converting virtual address to physical address to see if the pages were the same) .
> I was wondering if FreeBSD does the same copy or if the physical pages in ARC can be used for mmap without requiring a copy.  The reason for this question is that we are currently on illumos and are considering moving to FreeBSD and are evaluating the pros and cons.

On FreeBSD the behavior is exactly the same in this respect.

-- 
Andriy Gapon


More information about the freebsd-hackers mailing list