To motivate the need for dynamic management of data and metadata, it's useful to
look at the structure of a traditional
NFS server which is centralized. In a traditional
centralized NFS server what you have is
the data blocks are residing on the disks.
So in the memory of the server, the contents include the metadata for the files
like the iNote structures. And file cache which is
files that have been brought in from the disk
are stored in the memory in what is called
the file cache. So that future requests for the same
files can be served from the memory of the
server rather than going to the disk. And the server
also keeps the client caching directory. That is, who
on the local area network are currently accessing files that
is the propriety of this particular server. And
in a Unix file system the server is unconcerned
about the semantics of file sharing. In other
words, the assumption is that the server is caching
for each client completely independently. And therefore if
clients happened to share a file that is completely
the problem of the clients, and the server
is not concerned about that. So all of these
contents that I just described to you, metadata,
file cache, client caching directory. All of these are
in the memory of a particular server. And
if the server happens to be housing hot files
used by a lot of users that is
being served by this particular server. Then that's bad
news for the server in terms of scalability, because
it has to worry about the requests simultaneously coming
from lots of clients for these hot files. And
so it is constrained by the bandwidth that's available to
access the files from the disk. It is constrained
by the amount of memory space it's got, for caching
files, and the metadata of the files, and so
on. At the same time, there could be another server
that also has adequate bandwidth to the storage, and, and
memory space. But unfortunately it may be housing cold files.
And therefore, there are not many clients for
this server. So you can immediately see that
the sort of centralization of the traditional file
system results in hot spots. And that's the
thing that we're trying to avoid in a
distributed file system, and that's where dynamic management
comes into play. So in XFS, it provides
the same functionality as a centralized NFS Server,
but it is distributed and the metadata management
is dynamic. And that is, in a centralized
file server, the mapping between the manager node
for a file and the location of the
file is the same. Or in other words, if the file happens to reside on the disk
of this server, then this server is the guy that is going to handle the metadata
management for this file as well. On the
other hand, in XFS, metadata management is dynamically distributed.
So, let's say that you have F1, F2, and F3 are the hot files. In that case,
metadata management for files F2 and F3 can
be done by some other node, say S3. And
this server may have the cache for the
file. So, in other words, all the data structures
that we've talked about that has to reside in the memory of a particular server
like metadata, file cache, and the caching information
about who's having the files and so on.
All of that can be distributed with
dynamic management of data and metadata, which is
the idea in XFS. And I'll shortly explain
how exactly this dynamic management is facilitated by
the implementation of XFS. So, in any systems research,
there is always first the idea and then there's
implementation. So the idea in XFS is that we
want to manage the data and metadata management dynamically, and
we'll see how that is done. And also, what we want to do is we don't want the
cache for the files to be only at the
server. What we would like to be able to do
is, if a file is accessed by several different
nodes, then they're living in the client caches of
the different nodes. If a file is residing in
the cache of a peer node, then it makes
sense that if a new request comes from the
same file, then getting that file from a peer
cache may be much more efficient than getting it
from the disk. And that way we can also conserve
the total amount of memory that's available on the servers and use it
more frugally by exploiting the memories that
are available in the clients, so that
the caching of the files can be done cooperatively among the clients. And that's
the other nugget in the technical contribution
of XFS, is the cooperative client caching.