Using the InterMezzo Distributed Filesystem
Components of InterMezzo

Bill von Hagen
Monday, August 12, 2002 11:53:57 AM
On both clients and servers, InterMezzo uses an existing filesystem to
store its data, and tracks filesystem changes in "hidden" directories
in those filesystems. (These directories are hidden in the classic
Unix/Linux sense, meaning that their names begin with a period.)
InterMezzo data is typically stored in journaling filesystems, though
ext2s filesystems can also be used. Using a journaling filesystem as
the underpinnings of InterMezzo filesystems helps guarantee both that
changes to the files in the InterMezzo filesystem(s) won't be lost,
and that InterMezzo's log of file changes will always be as accurate
as possible, even after a spontaneous reboot.. Rather than providing
yet another journaling filesystem (YAJF), InterMezzo relies on a set
of wrapper functions that enable it to take advantage of existing
journaling filesystems such as ext3, JFS, and ReiserFS. Work on using
XFS with InterMezzo is still in progress.
Software-wise, InterMezzo basically consists of kernel components and
a server process known as InterSync that synchronizes files on
InterMezzo client and server systems. An instance of InterSync runs on
each InterMezzo client, keeping cached files on the client system
synchronized with the contents of the InterMezzo server's exported
filesystem. The InterMezzo server maintains a record of changes made
to any files in its experted filesystem(s) in a file known as a
"kernel modification log" that is stored in the exported InterMezzo
filesystem. Each client's InterSync process periodically polls the
server, retrieves this file, and scans it for records related to
cached files. If a record indicating a change to a cached file is
found, the InterSync server retrieves a fresh copy of the file from
the server. All communication between client and server in the latest
version of InterMezzo is done using the HTTP protocol.
Only synchronizing multiple clients with the contents of an InterMezzo
server and exported filesystem(s) is useful if you simply want to
propagate files and directories to client systems in an essentially
read-only fashion. However, in real life, it's most useful to
synchronize files in both directions. You can therefore also run an
InterSync server on the InterMezzo server in order to do active
synchronization. Active synchronization guarantees that changes to
files on the server are propagated to clients, but also guarantees
that changes to cached files on client systems are propagated back to
the server. Change to files on the server are then propagated out to
all other clients in the standard fashion.
Early releases of InterMezzo were notable because the synchronization
server that they used was written in Perl. Though
operating-system-level servers written in scripting languages such as
Perl are fairly rare, this rapid prototyping approach made it easy to
quickly explore a variety of synchronization mechanisms. Earlier
InterMezzo synchronization mechanisms relied on the standard
Unix/Linux rsync application and protocol rather than HTTP. Using HTTP
not only makes InterMezzo compatible with an existing, widely-used
protocol that is already available on many servers, but also enables
InterMezzo to take advantage of existing HTTP-oriented security
mechanisms such as SSL. Because HTTP is the foundation of the Web, it
is also likely that increasing amounts of security will be available
for HTTP communications, all of which InterMezzo can therefore get for
free.
The next few sections describe how to install and start
InterMezzo. All of the commands in these sections must be executed as
the root user. These sections do not discuss security issues, since
InterMezzo itself doesn't do anything special with security. The
InterMezzo client and server filesystems described in the next few
section are created as publicly writable filesystems for
experimentation purposes. You can impose and enforce security on them
using standard Linux security mechanisms that are outside the scope of
this article.
Next: Requirements for InterMezzo »