NFS caching on Ubuntu
- by stream
We run a bunch of ubuntu servers (mostly 8.04 LTS) which all mount an nfs share at /nfs. We use the nfs primarily for two purposes:
symlinking config files (such as apache vhosts)
reading & writing uploaded files
This all works great except it makes us fully dependent on the central NFS server (which is a DRBD cluster with heartbeat failover from primary to secondary, but we've still seen issues).
What we'd like is if we could mount the NFS through some local caching layer which would make any file which had previously been read remain available even if /nfs isn't. Writes could be disabled for this period.
Searching around it looks like cachefilesd may be an option. Unfortunately, it's only packaged for ubuntu 9.10 & 10.04 it looks like.
I was also looking for a FUSE-based solution which might fit the bill, but hadn't found anything yet.
Any suggestions would be greatly appreciated!