Next Back Summary First page Last page

Cache manager (venus)


Suppose a program running on my machine tries to open a file in the Coda file system. The program calls the function open(), which contacts the kernel's virtual file system layer. This notices that the file is in the Coda file system, and passes the request to the kernel's Coda module. This contacts the venus process through a character device in /dev.

The venus process is responsible for getting the requested data into the cache, and for making sure it is up-to-date. It may contact the file server to do this, and it may need to flush older data out of the cache to make room for the file. If it already has a copy of the file locally, it may ask the file server whether this is current, to avoid having to recopy it. Files can persist in the cache even across reboots, and of course the cache manager doesn't contact the server during disconnected operation.

Incidentally, if you have read or written a file, and you want to be sure it isn't in the cache for security reasons, you can force the cache manager to get rid of it; but the data in the file will probably remain on disk.

When the cache manager has a current copy of the file in the cache, it returns this information to the kernel, which then opens it like any other file.