Facebook and the kernel
Facebook and the kernel
Posted Mar 27, 2014 16:53 UTC (Thu) by zblaxell (subscriber, #26385)In reply to: Facebook and the kernel by pushersk
Parent article: Facebook and the kernel
For rsync and backups I use a cgroup RAM limit, so the rsync gets a small amount of cache for itself but won't flood the entire RAM with its reading. cgroup charges cache memory to the process that read the page, so rsync can read pages from other cgroups' caches but won't remove their cache pages as rsync reads other data. I can also freeze and thaw the backup cgroup when I want it to temporarily stop executing (e.g. because I'm working on the machine).
cgroups aren't enough, though. I can't do a global POSIX_FADV_RANDOM or mlockall(MCL_FUTURE) through a cgroup.
