close HDF5 data only on root node