Reclaiming storage from a file system in a file server
First Claim
1. A computer-implemented method of operating a file server, the file server including data storage and a data processor, the data storage storing a logical volume and a file system built on the logical volume, the file system including multiple cylinder groups, each of the cylinder groups including file system blocks, the file system blocks including allocated blocks of the data storage allocated to files in the file system, and free blocks of the data storage that are not allocated to the files in the file system, the logical volume including slices of the data storage, and each of the slices of the data storage storing a number of the cylinder groups, the method comprising the data processor executing computer instructions stored on a non-transitory computer-readable storage medium to perform the steps of:
- (a) selecting one of the slices of the data storage for evacuation; and
then(b) evacuating the selected one of the slices of the data storage by identifying allocated blocks of the data storage in the selected one the slices of the data storage, and for each of the identified allocated blocks of the data storage in the selected one the slices of the data storage, (1) reverse mapping said each of the identified allocated blocks to identify a file to which said each of the identified allocated blocks is allocated, (2) allocating a new block of the data storage in another one of the slices of the data storage in the logical volume upon which the file system is built, (3) copying data from said each of the identified allocated blocks to the allocated new block of the data storage in another one of the slices of the data storage in the logical volume upon which the file system is built, and (4) in the identified file to which said each of the identified allocated blocks is allocated, substituting the allocated new block of the data storage for said each of the identified allocated blocks.
2 Assignments
0 Petitions
Accused Products
Abstract
A file server provides access to a file system built on a logical volume of data storage. The file system includes multiple cylinder groups of file system blocks, and the logical volume includes slices of the cylinder groups. The file server has a storage reorganizer for identifying allocated file system blocks in a selected slice, and evacuating the identified allocated file system blocks from the selected slice. The selected slice is evacuated by reverse mapping each identified allocated block to identify a file to which the identified allocated block is allocated, allocating a new block in another slice, copying data from the identified allocated block to the new block, and substituting the new block for the identified allocated block in the file.
-
Citations
20 Claims
-
1. A computer-implemented method of operating a file server, the file server including data storage and a data processor, the data storage storing a logical volume and a file system built on the logical volume, the file system including multiple cylinder groups, each of the cylinder groups including file system blocks, the file system blocks including allocated blocks of the data storage allocated to files in the file system, and free blocks of the data storage that are not allocated to the files in the file system, the logical volume including slices of the data storage, and each of the slices of the data storage storing a number of the cylinder groups, the method comprising the data processor executing computer instructions stored on a non-transitory computer-readable storage medium to perform the steps of:
-
(a) selecting one of the slices of the data storage for evacuation; and
then(b) evacuating the selected one of the slices of the data storage by identifying allocated blocks of the data storage in the selected one the slices of the data storage, and for each of the identified allocated blocks of the data storage in the selected one the slices of the data storage, (1) reverse mapping said each of the identified allocated blocks to identify a file to which said each of the identified allocated blocks is allocated, (2) allocating a new block of the data storage in another one of the slices of the data storage in the logical volume upon which the file system is built, (3) copying data from said each of the identified allocated blocks to the allocated new block of the data storage in another one of the slices of the data storage in the logical volume upon which the file system is built, and (4) in the identified file to which said each of the identified allocated blocks is allocated, substituting the allocated new block of the data storage for said each of the identified allocated blocks. - View Dependent Claims (2, 3, 4, 5, 6, 7, 8, 9, 10)
-
-
11. A file server comprising:
-
data storage; and a data processor coupled to the data storage for accessing data stored in the data storage; the data storage storing a logical volume and a file system built on the logical volume, the file system including multiple cylinder groups, each of the cylinder groups including file system blocks, the file system blocks including allocated blocks of the data storage allocated to files in the file system, and free blocks of the data storage that are not allocated to the files in the file system, the logical volume including slices of the data storage, and each of the slices of the data storage storing a number of the cylinder groups; and the data processor having a non-transitory computer-readable storage medium storing computer instructions that, when executed by the data processor, perform the steps of; (a) selecting one of the slices of the data storage for evacuation; and
then(b) evacuating the selected one of the slices of the data storage by identifying allocated blocks of the data storage in the selected one the slices of the data storage, and for each of the identified allocated blocks of the data storage in the selected one the slices of the data storage;
(1) reverse mapping said each of the identified allocated blocks to identify a file to which said each of the identified allocated blocks is allocated, (2) allocating a new block of the data storage in another one of the slices of the data storage in the logical volume upon which the file system is built, (3) copying data from said each of the identified allocated blocks to the allocated new block of the data storage in another one of the slices of the data storage in the logical volume upon which the file system is built, and (4) in the identified file to which said each of the identified allocated blocks is allocated, substituting the allocated new block of the data storage for said each of the identified allocated blocks. - View Dependent Claims (12, 13, 14, 15, 16, 17, 18, 19, 20)
-
Specification