NOTICE: This version of the NSF Unidata web site (archive.unidata.ucar.edu) is no longer being updated.
Current content can be found at unidata.ucar.edu.
To learn about what's going on, see About the Archive Site.
NOTE: The netcdf-hdf
mailing list is no longer active. The list archives are made available for historical reasons.
Hi Ed, > One problem that I often have is that my code forgets to close a HDF5 > resource, like a typeid. This isn't detected when I close the file, > but when I try to recreate a file with the same name, I get an error > on the create, which looks like this: > > HDF5-DIAG: Error detected in HDF5 (1.7.46) thread 0: > #000: H5F.c line 2097 in H5Fcreate(): unable to create file > major: File accessability > minor: Unable to open file > #001: H5F.c line 1771 in H5F_open(): unable to truncate a file which is > already open > major: File accessability > minor: Unable to open file > > Unfortunately, this gives no clue whatsoever as to which resource was > left open. > > Is there any way to get more information about which resource is left > open? Yes, you can use the H5Fget_obj_count() and H5Fget_obj_ids() routines to manage this. > Also, is there a way to have HDF5 detect this when I H5Fclose the > file, instead of when I try and overwrite it with a new file? Yes, you can use the H5Pset_fclose_degree() routine to control this also. Quincey
netcdf-hdf
archives: