Using a file for associating the file with a tree quota in a file server
First Claim
1. A method of maintaining quotas for storage resources used by a file server for storing files in selected directory trees of a file system, the method including:
- (a) the file server responding to a client request specifying a file in the file system by performing a search for the file in the file system, and upon finding that the file is in a directory tree having a quota of the storage resources, returning a file handle including a tree quota identifier identifying the quota of the directory tree;
(b) the file server responding to a client request for increasing storage resources used by the file, the client request for increasing storage resources used by the file including the file handle, the file server responding to the client request for increasing storage resources used by the file by inspecting the file handle and upon finding the tree quota identifier in the file handle, using the tree quota identifier to find the quota identified by the tree quota identifier, and checking whether the client request for increasing storage resources used by the file can be satisfied without exceeding the quota identified by the tree quota identifier.
9 Assignments
0 Petitions
Accused Products
Abstract
To avoid the need for storing a tree quota identifier attribute for every file in a quota tree, a tree quota identifier is included in the file handle returned by the file server to a client in response to a directory lookup request. The file server discovers that the file is in a quota tree when searching along a path specified by the file pathname and finding a directory having a tree quota identifier. The file server responds to a client request for changing the storage resources used by the file by inspecting the file handle and upon finding the tree quota identifier in the file handle, using the tree quota identifier to index a tree quota database to find usage and limits for the tree quota. The file server checks the limits against any increase in the storage resources for the file, and updates the usage.
104 Citations
28 Claims
-
1. A method of maintaining quotas for storage resources used by a file server for storing files in selected directory trees of a file system, the method including:
-
(a) the file server responding to a client request specifying a file in the file system by performing a search for the file in the file system, and upon finding that the file is in a directory tree having a quota of the storage resources, returning a file handle including a tree quota identifier identifying the quota of the directory tree;
(b) the file server responding to a client request for increasing storage resources used by the file, the client request for increasing storage resources used by the file including the file handle, the file server responding to the client request for increasing storage resources used by the file by inspecting the file handle and upon finding the tree quota identifier in the file handle, using the tree quota identifier to find the quota identified by the tree quota identifier, and checking whether the client request for increasing storage resources used by the file can be satisfied without exceeding the quota identified by the tree quota identifier. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13)
-
-
14. A method of maintaining quotas for storage resources used by a file server for storing files in selected directory trees of a file system, the file server having a tree quota database of usage values of the storage resources and limit values for the storage resources for the selected directory trees of the file system, the usage values and limit values being indexed by tree quota identifiers associated with root directories of the selected directory trees, the method including:
-
(a) the file server responding to a client request specifying a file in the file system by performing a search for the file in the file system, and upon finding that the file is in a directory tree having a quota of the storage resources, returning a file handle including a tree quota identifier identifying the quota of the storage resources;
(b) the file server responding to a client request for increasing storage resources used by the file, the client request for increasing storage resources used by the file including the file handle, the file server responding to the client request for increasing storage resources used by the file by inspecting the file handle and upon finding the tree quota identifier in the file handle, using the tree quota identifier to index the tree quota database to find the quota identified by the tree quota identifier, and checking whether the client request for increasing storage resources used by the file can be satisfied without exceeding the limit value of the quota identified by the tree quota identifier; and
when the client request for increasing storage resources used by the file can be satisfied without exceeding the limit value of the quota identified by the tree quota identifier, increasing the usage for the quota identified by the tree quota identifier, and satisfying the client request.
-
-
15. A file server comprising:
-
storage for storing a file system; and
a processor programmed for responding to client requests for access to the file system and for maintaining quotas for storage resources used for storing files in selected directory trees of the file system, wherein the processor is programmed for responding to a client request specifying a file in the file system by performing a search for the file in the file system, and upon finding that the file is in a directory tree having a quota of the storage resources, returning a file handle including a tree quota identifier identifying the quota of the storage resources; and
wherein the processor is programmed for responding to a client request for increasing storage resources used by the file, the client request for increasing storage resources used by the file including the file handle, and the processor is programmed for responding to the client request for increasing storage resources used by the file by inspecting the file handle and upon finding the tree quota identifier in the file handle, using the tree quota identifier to find the quota identified by the tree quota identifier, and checking whether the client request for increasing storage resources used by the file can be satisfied without exceeding the quota identified by the tree quota identifier. - View Dependent Claims (16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27)
-
-
28. A file server comprising:
-
storage for storing a file system; and
a processor programmed for responding to client requests for access to the file system and for maintaining quotas for storage resources used for storing files in selected directory trees of the file system, wherein the processor is programmed for maintaining a tree quota database of usage values of the storage resources and limit values for the storage resources for the selected directory trees of the file system, the usage values and limit values being indexed by tree quota identifiers associated with root directories of the selected directory trees;
wherein the processor is programmed for responding to a client request specifying a file in the file system by performing a search for the file in the file system, and upon finding that the file is in a directory tree having a quota of the storage resources, returning a file handle including a tree quota identifier identifying the quota of the storage resources; and
wherein the processor is programmed for responding to a client request for increasing storage resources used by the file, the client request for increasing storage resources used by the file including the file handle, and the processor is programmed for responding to the client request for increasing storage resources used by the file by inspecting the file handle and upon finding the tree quota identifier in the file handle, using the tree quota identifier to index the tree quota database to find the quota identified by the tree quota identifier, and checking whether the client request for increasing storage resources used by the file can be satisfied without exceeding the quota of storage resources for storing files in the directory tree identified by the tree quota identifier; and
when the client request for increasing storage resources used by the file can be satisfied without exceeding the limit value of the quota identified by the tree quota identifier, increasing the usage for the quota identified by the tree quota identifier, and satisfying the client request.
-
Specification