2. INTRODUCTION
A shared file may be simultaneously accessed by multiple users. In such
a situation, an important design issue for any system is to clearly define
when modifications of file data made by a user are observable by other
users. This is defined by the type of file sharing semantics adopted by a
file system.
4. 1. UNIX SEMANTICS
This semantic enforces an absolute time
ordering on all operations and ensures that every
read operation on a file sees the effects of all
previous write operations performed on that file.
The UNIX semantic is implemented in file system for
single CPU system because it is the most desirable
semantic and because it is easy to serialize all
read/write request.
5. How ever implementing UNIX semantics in a distributed file
system is not an easy task. Though it can be achieved by
disallowing files to be cached at client node and allowing
shared file to be manage by only one file server that
process all read and write request strictly in the order they
are received. But due to network delays, client requests
from different nodes may arrive and get processed at the
server node in an order different from the actual order in
which the request were made. This result in poor
performance, poor scalability and poor reliability of the
distributed file system.
6. 2. IMMUTABLE SHARED-FILE SEMANTICS
This semantics is based on the use of the
immutable file model. We can see that immutable file
cannot be modified once it has been created.
According to this semantics, once the creator of a file
declares it to be shared, the file is treated as
immutable so that it cannot be modified anymore.
Changes on the file are handled by creating a new
update version of the file.
7. 3. TRANSACTION-LIKE SEMANTICS
This semantics is based on the transaction
mechanism, which is a high-level mechanism for controlling
concurrent access to shared, mutable data. The transaction
mechanism ensures that the partial modification made to
the shared data by a transaction will not be visible to other
concurrently executing transaction until the transaction
ends. Therefore, in multiple concurrent transactions
operating on a file, the final content will be the same as if all
the transactions were run in some sequential order.
8. 4. SESSION SEMANTICS
Session is when a client performs a read/write
operations on a file.
In session semantics, all changes made to a file during
a session are initially visible only to the client process
(those processes that are on the client node) that open
the session and are invisible to other remote processes
who have the same file open simultaneously. Once the
session is closed, the changes made to the files are
made visible processes only in later starting session.