This page briefly describes the documentation available to those who use the file space management feature found in the HDF5 library.
The HDF5 library's file space management activities encompass both the allocation of file space and the management of free space. When an HDF5 object (group, dataset, etc.) is created and written, file space is allocated for storing its metadata and raw data. When an object is removed, the space associated with the object becomes free space.
The following are the sections on this page:
The HDF5 library uses three mechanisms to manage space in an HDF5 file. They are:
There are four file space-handling strategies available to users that use these mechanisms:
This strategy has always been available in HDF5 and is the default. The mechanisms used for this strategy are free-space managers, aggregators, and virtual file drivers.
The current HDF5 file space allocation accumulates small pieces of metadata and raw data in aggregator blocks. However, these blocks are not page aligned and vary widely in sizes. The paged aggregation feature provides efficient paged access of these small pieces of metadata and raw data. It accumulates metadata and raw data into well-aligned pages called file space pages. The library defines a default file space page size but a user can set the page size via a new public routine.
The mechanisms used for this strategy are free-space managers with embedded paged aggregation and virtual file drivers.
See the RFC on this feature for complete details.
With this strategy the library will request space from either the metadata or raw data aggregator depending on the file space type. If the request is not satisfied, the library will request space from the virtual file driver.
The mechanisms used for this strategy are aggregators and virtual file drivers. It does not use the free-space manager.
This strategy will request space from the virtual file driver. The only mechanism used is the virtual file driver. It does not use the free-space manager.
(This document is not yet available.)
The APIs listed below from the HDF5 Reference Manual provide a means for users to directly manage the file space management feature.
H5F_GET_FREE_SECTIONS | Retrieves free-space section information for a file |
H5F_GET_FREESPACE | Returns the amount of free space in a file |
H5F_GET_INFO2 | Returns global information for a file |
H5P_GET_FILE_SPACE_STRATEGY | Retrieves the File Space Strategy for a file creation property list |
H5P_SET_FILE_SPACE_STRATEGY | Sets the File Space Strategy for a file creation property list |
H5P_GET_FILE_SPACE_PAGE_SIZE | Retrieves the file space page size for paged aggregation |
H5P_SET_FILE_SPACE_PAGE_SIZE | Sets the file space page size for paged aggregation |
The tools listed below have been modified to preserve or modify file freepace information appropriately when processing files employing this feature.
h5dump | When printing the file creation property information for the superblock via the -B option, h5dump includes the block size obtained via H5Pget_file_space_page_size . |
h5stat | When printing the file space information via the -S option, h5stat includes the block size obtained via H5Pget_file_space_page_size . |
h5repack | The following options were added to h5repack :
|