Optimistic locking method and system for committing transactions on a file system
First Claim
1. In a shared file system that is accessible by a group of servers, wherein the shared file system resides in a data storage unit having a logical storage space that is contiguous and maps to physical storage space of a shared storage array, a method for committing a transaction acting upon data stored in the logical storage space of said data storage unit, the method being carried out by a server in said group and comprising:
- reading a state of a set of locks relating to the data from the data storage unit, wherein the data and data fields of the locks relating to the data are stored in the logical storage space of the data storage unit;
constructing a completed transaction in memory of said server prior to acquiring the locks;
after said constructing, acquiring exclusive possession of the data storage unit, wherein said acquiring prevents other servers in the group from accessing the logical storage space of the data storage unit;
while having exclusive possession of the data storage unit, acquiring the locks if the state of the locks has not changed since said reading; and
committing the completed transaction,where said acquiring the locks includes writing a unique identifier associated with said server into one of the data fields of each of the locks.
2 Assignments
0 Petitions
Accused Products
Abstract
In a file system shared by multiple servers, reservation of a data storage unit such as a LUN of a disk array to acquire locks in order to commit a transaction acting on data stored in the data storage unit is deferred until the transaction is completed in RAM and the locks can be acquired in parallel during a single instance of reserving the data storage unit.
-
Citations
20 Claims
-
1. In a shared file system that is accessible by a group of servers, wherein the shared file system resides in a data storage unit having a logical storage space that is contiguous and maps to physical storage space of a shared storage array, a method for committing a transaction acting upon data stored in the logical storage space of said data storage unit, the method being carried out by a server in said group and comprising:
-
reading a state of a set of locks relating to the data from the data storage unit, wherein the data and data fields of the locks relating to the data are stored in the logical storage space of the data storage unit; constructing a completed transaction in memory of said server prior to acquiring the locks; after said constructing, acquiring exclusive possession of the data storage unit, wherein said acquiring prevents other servers in the group from accessing the logical storage space of the data storage unit; while having exclusive possession of the data storage unit, acquiring the locks if the state of the locks has not changed since said reading; and committing the completed transaction, where said acquiring the locks includes writing a unique identifier associated with said server into one of the data fields of each of the locks. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12)
-
-
13. A computer system with a shared file system accessed by a plurality of servers, the computer system comprising:
-
a plurality of servers, wherein each of the servers comprises a processor, a random access memory (RAM) and an operating system accessing the shared file system; and a shared storage array coupled to the plurality of servers, wherein the shared storage array comprises a controller that exposes to the servers a data storage unit in which the shared file system is stored, the data storage unit having a logical storage space that is contiguous and maps to physical storage space of the shared storage array, wherein each server'"'"'s processor is programmed to perform the following steps to commit a transaction for a process running on said server; reading a first state of a set of locks relating to data to be acted upon by the transaction from the data storage unit, wherein the data and data fields of the locks relating to the data are stored in the logical storage space of the data storage unit; constructing a completed version of the transaction in said server'"'"'s RAM prior to acquiring the locks; after said constructing, acquiring exclusive possession of the data storage unit, wherein said acquiring prevents other servers coupled to the shared storage array from accessing the logical storage space of the data storage unit; while having exclusive possession of the data storage unit, checking if the locks have changed state since the first state, and acquiring the locks if the state of the locks has not changed since the first state; and committing the completed transaction to a journal in the data storage unit, wherein said acquiring the locks includes writing a unique identifier associated with said server into one of the data fields of each of the locks. - View Dependent Claims (14, 15)
-
-
16. A non-transitory computer readable storage medium having stored therein a computer program for causing a server to commit a transaction acting upon data stored in a data storage unit having a logical storage space that is contiguous, maps to physical storage space of a shared storage array, and is accessible by said server and other servers, wherein said server executing the computer program carries out:
-
reading a state of a set of locks relating to the data from the data storage unit, wherein the data and data fields of the locks relating to the data are stored in the logical storage space of the data storage unit; constructing a completed transaction in memory prior to acquiring the locks; after said constructing, acquiring exclusive possession of the data storage unit, wherein said acquiring prevents the other servers from accessing the logical storage space of the data storage unit; while having exclusive possession of the data storage unit, acquiring the locks if the state of the locks has not changed since said reading; and committing the completed transaction, wherein said acquiring the locks includes writing a unique identifier associated with said server into one of the data fields of each of the locks. - View Dependent Claims (17, 18, 19, 20)
-
Specification