The invention discloses a quick file expansion method for an exFAT (Extensible
File Allocation Table)
file system. Relates to the technical field of rapid file expansion, in particular to the technical field of rapid file expansion of an exFAT
file system. The problem that the file expansion speed is low is effectively solved, and the compatibility and flexibility of the file expansion method are improved. The method comprises the following steps: S1, confirming whether a
file system has enough storage space or not, and marking the file
system as a dirty state; s2, traversing the cluster chain table of the to-be-extended file, and finding the last cluster of the to-be-extended file; s3, calculating the number of new clusters required by the to-be-expanded file, and distributing the new clusters; s4, linking the
tail cluster of the to-be-allocated file cluster chain table with the head cluster of the new cluster chain table to form a new complete cluster chain table; s5, updating the size of the file to be expanded; s6, setting file attributes, and updating
directory entries and
inode; and S7, aligning the expanded file. According to the method, the file
system does not need to cancel mounting, efficient file expansion can be achieved, and the method is suitable for large-capacity storage equipment with the
file size frequently expanded.