Patent ID: 7185029

Claim:
A computer-implemented method for expanding usable space for an application data file, comprising: maintaining in a control file first and second control structures and first and second pointers to the first and second control structures, respectively, for the data file, wherein the first structure includes a plurality of pointers that respectively reference a plurality of bit maps that indicate available and allocated records of respective portions of usable space in the data file, and the second structure contains respective values that indicate quantities of available space in the respective portions of the data file; limiting access to the first and second control structures to only a process that is expanding the data file while the process is expanding the data file; allocating space for new versions of the first and second control structures in the control file; copying contents of the first and second control structures to space for the new versions of the first and second control structures; updating the first and second pointers to reference the new versions of the first and second control structures; determining whether the first structure is large enough to accommodate expansion of the data file by a requested amount; and performing the steps of allocating, copying, and updating only if the first structure is not large enough to accommodate expansion of the data file by the requested amount; maintaining in-memory copies of the first and second pointers while the application data file is available for access; and updating the in-memory copies of the first and second pointers to reference the new versions of the first and second control structures.