# Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src

**URL:** <https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831>\
**Category:** Hdf-forum archives\
**Created:** [July 26, 2016, 5:34am UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831 "2016-07-26T05:34:58Z")\
**Posts on this page:** 11\
**Page:** 1

<div class="post-metadata">

**Author:** ![1114](https://forum.hdfgroup.org/letter_avatar_proxy/v4/letter/1/77aa72/32.png) [@1114](https://forum.hdfgroup.org/u/1114)\
**Post date:** [July 26, 2016, 5:34am UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831/1 "2016-07-26T05:34:58Z")

</div>

Hi,  
I have met an obscure failure, and not find a good solution for two days. Could you help me? Thanks!  
(Using: hdf5-1.10.0-patch1-linux-centos6-x86\_64-gcc447-shared.tar.gz)  
(Environment: redhat6.4-Intel-X64-g++4.4.7)

The error information:  
HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:  
&nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 491 in H5Fcreate(): unable to create file  
&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
&nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file  
&nbsp;&nbsp;#001: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5Fint.c line 1168 in H5F\_open(): unable to lock the file or initialize file structure  
&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
&nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file  
&nbsp;&nbsp;#002: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FD.c line 1821 in H5FD\_lock(): driver lock request failed  
&nbsp;&nbsp;&nbsp;&nbsp;major: Virtual File Layer  
&nbsp;&nbsp;&nbsp;&nbsp;minor: Can't update object  
&nbsp;&nbsp;#003: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FDsec2.c line 939 in H5FD\_sec2\_lock(): unable to flock file, errno = 38, error message = 'Function not implemented'  
&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
&nbsp;&nbsp;&nbsp;&nbsp;minor: Bad file ID accessed  
HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:  
&nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 749 in H5Fclose(): not a file ID  
&nbsp;&nbsp;&nbsp;&nbsp;major: Invalid arguments to routine  
&nbsp;&nbsp;&nbsp;&nbsp;minor: Inappropriate type

compile no error: g++ -c packageHdf5.cpp -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp  
link no error: g++ -o packageHdf5Run packageHdf5.o -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp  
run error: ./packageHdf5Run (error information as above)

My code:

#include \<stdio.h\>  
#include \<iostream\>  
#include \<string\>

#include "H5Cpp.h"  
#include \<H5File.h\>  
#include "hdf5.h"

#ifndef H5\_NO\_NAMESPACE  
using namespace H5;  
#endif

using namespace std;

int main(int argc, char\* argv[])  
{  
hid\_t file\_id = H5Fcreate("/home/tg2hpps/tg2hpps\_main/src/packageHdf5/dsetddd.h5", H5F\_ACC\_TRUNC, H5P\_DEFAULT, H5P\_DEFAULT);  
H5Fclose(file\_id);  
}

Thanks!

---

<div class="post-metadata">

**Author:** ![derobins](https://forum.hdfgroup.org/user_avatar/forum.hdfgroup.org/derobins/32/1481_2.png) [@derobins](https://forum.hdfgroup.org/u/derobins)\
**Post date:** [July 26, 2016, 5:47am UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831/2 "2016-07-26T05:47:39Z")

</div>

Hi,

It looks like flock() is not implemented on your filesystem, which is causing the create call to fail. flock() file locking is used by the HDF5 1.10.0 to help enforce single-writer/multiple-readers (SWMR) semantics, but is not necessary for correct operation of the library. A fix for this problem should be available in HDF5 1.10.1, but in the meantime you can apply a source patch found here:

[https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf](https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf)

under "Patch to Disable File Locking" at the bottom of the page.

Cheers,

Dana Robinson  
Software Engineer  
The HDF Group

> **···**
>
> From: Hdf-forum [[mailto:hdf-forum-bounces@lists.hdfgroup.org](mailto:hdf-forum-bounces@lists.hdfgroup.org)] On Behalf Of ???  
> Sent: Tuesday, July 26, 2016 1:35 AM  
> To: [hdf-forum@lists.hdfgroup.org](mailto:hdf-forum@lists.hdfgroup.org)  
> Subject: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi,  
> I have met an obscure failure, and not find a good solution for two days. Could you help me? Thanks!  
> (Using: hdf5-1.10.0-patch1-linux-centos6-x86\_64-gcc447-shared.tar.gz)  
> (Environment: redhat6.4-Intel-X64-g++4.4.7)
> 
> The error information:  
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:  
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 491 in H5Fcreate(): unable to create file  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file  
> &nbsp;&nbsp;#001: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5Fint.c line 1168 in H5F\_open(): unable to lock the file or initialize file structure  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file  
> &nbsp;&nbsp;#002: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FD.c line 1821 in H5FD\_lock(): driver lock request failed  
> &nbsp;&nbsp;&nbsp;&nbsp;major: Virtual File Layer  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Can't update object  
> &nbsp;&nbsp;#003: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FDsec2.c line 939 in H5FD\_sec2\_lock(): unable to flock file, errno = 38, error message = 'Function not implemented'  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Bad file ID accessed  
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:  
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 749 in H5Fclose(): not a file ID  
> &nbsp;&nbsp;&nbsp;&nbsp;major: Invalid arguments to routine  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Inappropriate type
> 
> compile no error: g++ -c packageHdf5.cpp -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp  
> link no error: g++ -o packageHdf5Run packageHdf5.o -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp  
> run error: ./packageHdf5Run (error information as above)
> 
> My code:
> 
> #include \<stdio.h\>  
> #include \<iostream\>  
> #include \<string\>
> 
> #include "H5Cpp.h"  
> #include \<H5File.h\>  
> #include "hdf5.h"
> 
> #ifndef H5\_NO\_NAMESPACE  
> using namespace H5;  
> #endif
> 
> using namespace std;
> 
> int main(int argc, char\* argv[])  
> {  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hid\_t file\_id = H5Fcreate("/home/tg2hpps/tg2hpps\_main/src/packageHdf5/dsetddd.h5", H5F\_ACC\_TRUNC, H5P\_DEFAULT, H5P\_DEFAULT);
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5Fclose(file\_id);  
> }
> 
> Thanks!

---

<div class="post-metadata">

**Author:** ![1114](https://forum.hdfgroup.org/letter_avatar_proxy/v4/letter/1/77aa72/32.png) [@1114](https://forum.hdfgroup.org/u/1114)\
**Post date:** [July 27, 2016, 6:15am UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831/3 "2016-07-27T06:15:31Z")

</div>

Hi Dana,  
Thanks for your response.

I've tried with your method to patch and compile hdf5-1.10.0-patch1 source code. Patch and compile have no error. Unfortunately when run my code the error still exist. And error information is the same as before.

What should I do? Please help me.

Thank you again for your effort!

Haijun Yu

> **···**
>
> At 2016-07-26 13:47:39, "Dana Robinson" \<[derobins@hdfgroup.org](mailto:derobins@hdfgroup.org)\> wrote:
> 
> Hi,
> 
> It looks like flock() is not implemented on your filesystem, which is causing the create call to fail. flock() file locking is used by the HDF5 1.10.0 to help enforce single-writer/multiple-readers (SWMR) semantics, but is not necessary for correct operation of the library. A fix for this problem should be available in HDF5 1.10.1, but in the meantime you can apply a source patch found here:
> 
> [https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf](https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf)
> 
> under "Patch to Disable File Locking" at the bottom of the page.
> 
> Cheers,
> 
> Dana Robinson
> 
> Software Engineer
> 
> The HDF Group
> 
> From: Hdf-forum [[mailto:hdf-forum-bounces@lists.hdfgroup.org](mailto:hdf-forum-bounces@lists.hdfgroup.org)] On Behalf Of ???  
> Sent: Tuesday, July 26, 2016 1:35 AM  
> [To:hdf-forum@lists.hdfgroup.org](mailto:To:hdf-forum@lists.hdfgroup.org)  
> Subject: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi,
> 
> I have met an obscure failure, and not find a good solution for two days. Could you help me? Thanks!
> 
> (Using: hdf5-1.10.0-patch1-linux-centos6-x86\_64-gcc447-shared.tar.gz)
> 
> (Environment: redhat6.4-Intel-X64-g++4.4.7)
> 
> The error information:
> 
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> 
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 491 in H5Fcreate(): unable to create file
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> 
> &nbsp;&nbsp;#001: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5Fint.c line 1168 in H5F\_open(): unable to lock the file or initialize file structure
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> 
> &nbsp;&nbsp;#002: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FD.c line 1821 in H5FD\_lock(): driver lock request failed
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: Virtual File Layer
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Can't update object
> 
> &nbsp;&nbsp;#003: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FDsec2.c line 939 in H5FD\_sec2\_lock(): unable to flock file, errno = 38, error message = 'Function not implemented'
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Bad file ID accessed
> 
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> 
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 749 in H5Fclose(): not a file ID
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: Invalid arguments to routine
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Inappropriate type
> 
> compile no error: g++ -c packageHdf5.cpp -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp
> 
> link no error: g++ -o packageHdf5Run packageHdf5.o -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp
> 
> run error: ./packageHdf5Run (error information as above)
> 
> My code:
> 
> #include \<stdio.h\>
> 
> #include \<iostream\>
> 
> #include \<string\>
> 
> #include "H5Cpp.h"
> 
> #include \<H5File.h\>
> 
> #include "hdf5.h"
> 
> #ifndef H5\_NO\_NAMESPACE
> 
> using namespace H5;
> 
> #endif
> 
> using namespace std;
> 
> int main(int argc, char\* argv[])
> 
> {
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hid\_t file\_id = H5Fcreate("/home/tg2hpps/tg2hpps\_main/src/packageHdf5/dsetddd.h5", H5F\_ACC\_TRUNC, H5P\_DEFAULT, H5P\_DEFAULT);
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5Fclose(file\_id);
> 
> }
> 
> Thanks!

---

<div class="post-metadata">

**Author:** ![pbisbal](https://forum.hdfgroup.org/letter_avatar_proxy/v4/letter/p/8e7dd6/32.png) [@pbisbal](https://forum.hdfgroup.org/u/pbisbal)\
**Post date:** [July 27, 2016, 1:46pm UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831/4 "2016-07-27T13:46:43Z")

</div>

Haijun,

Did do a 'make clean' or (even better) 'make distclean' before recompiling your code? Make is supposed to determine that the source files are newer than the object files and build all the object files that depend on those source files and so on, but it's possible that the dependency tree broke down somewhere.

I would recommend deleting your entire HDF5 source directory, unzipping HDF again, applying the patch, and the going through the configure and make process again.

Prentice

> **···**
>
> On 07/27/2016 08:24 AM, Dana Robinson wrote:
> 
> > Hi Haijun,
> > 
> > If you are still getting a flock error, I'd be suspicious that you aren't linking to the patched HDF5 library. The source patch completely removes flock so you shouldn't be seeing file locking errors.
> > 
> > Dana Robinson
> > 
> > Software Engineer
> > 
> > The HDF Group
> > 
> > \*From:\*Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org] \*On Behalf Of \*???  
> > \*Sent:\* Wednesday, July 27, 2016 2:16 AM  
> > \*To:\* HDF Users Discussion List \<hdf-forum@lists.hdfgroup.org\>  
> > \*Subject:\* Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Hi Dana,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Thanks for your response.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;I've tried with your method to patch and compile  
> > &nbsp;&nbsp;&nbsp;&nbsp;hdf5-1.10.0-patch1 source code. Patch and compile have no error.  
> > &nbsp;&nbsp;&nbsp;&nbsp;Unfortunately when run my code the error still exist. And error  
> > &nbsp;&nbsp;&nbsp;&nbsp;information is the same as before.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;What should I do? Please help me.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Thank you again for your effort!
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu
> > 
> > At 2016-07-26 13:47:39, "Dana Robinson" \<derobins@hdfgroup.org \> \<mailto:derobins@hdfgroup.org\>\> wrote:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Hi,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;It looks like flock() is not implemented on your filesystem, which  
> > &nbsp;&nbsp;&nbsp;&nbsp;is causing the create call to fail. flock() file locking is used  
> > &nbsp;&nbsp;&nbsp;&nbsp;by the HDF5 1.10.0 to help enforce single-writer/multiple-readers  
> > &nbsp;&nbsp;&nbsp;&nbsp;(SWMR) semantics, but is not necessary for correct operation of  
> > &nbsp;&nbsp;&nbsp;&nbsp;the library. A fix for this problem should be available in HDF5  
> > &nbsp;&nbsp;&nbsp;&nbsp;1.10.1, but in the meantime you can apply a source patch found here:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;[https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf](https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;under "Patch to Disable File Locking" at the bottom of the page.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Cheers,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Dana Robinson
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Software Engineer
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;The HDF Group
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;\*From:\*Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org  
> > &nbsp;&nbsp;&nbsp;&nbsp;\<mailto:hdf-forum-bounces@lists.hdfgroup.org\>] \*On Behalf Of \*???  
> > &nbsp;&nbsp;&nbsp;&nbsp;\*Sent:\* Tuesday, July 26, 2016 1:35 AM  
> > &nbsp;&nbsp;&nbsp;&nbsp;\*To:\* hdf-forum@lists.hdfgroup.org  
> > &nbsp;&nbsp;&nbsp;&nbsp;\<mailto:hdf-forum@lists.hdfgroup.org\>  
> > &nbsp;&nbsp;&nbsp;&nbsp;\*Subject:\* [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0:  
> > &nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Hi,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;I have met an obscure failure, and not find a good solution for  
> > &nbsp;&nbsp;&nbsp;&nbsp;two days. Could you help me? Thanks!
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;(Using: hdf5-1.10.0-patch1-linux-centos6-x86\_64-gcc447-shared.tar.gz)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;(Environment: redhat6.4-Intel-X64-g++4.4.7)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;The error information:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c  
> > &nbsp;&nbsp;&nbsp;&nbsp;line 491 in H5Fcreate(): unable to create file
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#001: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5Fint.c  
> > &nbsp;&nbsp;&nbsp;&nbsp;line 1168 in H5F\_open(): unable to lock the file or initialize  
> > &nbsp;&nbsp;&nbsp;&nbsp;file structure
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#002: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FD.c  
> > &nbsp;&nbsp;&nbsp;&nbsp;line 1821 in H5FD\_lock(): driver lock request failed
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: Virtual File Layer
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Can't update object
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#003:  
> > &nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FDsec2.c  
> > &nbsp;&nbsp;&nbsp;&nbsp;line 939 in H5FD\_sec2\_lock(): unable to flock file, errno = 38,  
> > &nbsp;&nbsp;&nbsp;&nbsp;error message = 'Function not implemented'
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Bad file ID accessed
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c  
> > &nbsp;&nbsp;&nbsp;&nbsp;line 749 in H5Fclose(): not a file ID
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: Invalid arguments to routine
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Inappropriate type
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;compile no error: g++ -c packageHdf5.cpp -I ../latest/include -L  
> > &nbsp;&nbsp;&nbsp;&nbsp;../latest/lib -lhdf5 -lhdf5\_cpp
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;link no error: g++ -o packageHdf5Run packageHdf5.o -I  
> > &nbsp;&nbsp;&nbsp;&nbsp;../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;run error: ./packageHdf5Run (error information as above)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;My code:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#include \<stdio.h\>
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#include \<iostream\>
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#include \<string\>
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#include "H5Cpp.h"
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#include \<H5File.h\>
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#include "hdf5.h"
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#ifndef H5\_NO\_NAMESPACE
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;using namespace H5;
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;#endif
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;using namespace std;
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;int main(int argc, char\* argv)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;{
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;hid\_t file\_id =  
> > &nbsp;&nbsp;&nbsp;&nbsp;H5Fcreate("/home/tg2hpps/tg2hpps\_main/src/packageHdf5/dsetddd.h5",  
> > &nbsp;&nbsp;&nbsp;&nbsp;H5F\_ACC\_TRUNC, H5P\_DEFAULT, H5P\_DEFAULT);
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;H5Fclose(file\_id);
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;}
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Thanks!
> > 
> > \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> > Hdf-forum is for HDF software users discussion.  
> > Hdf-forum@lists.hdfgroup.org  
> > [http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)  
> > Twitter: [x.com](https://twitter.com/hdf5)

---

<div class="post-metadata">

**Author:** ![derobins](https://forum.hdfgroup.org/user_avatar/forum.hdfgroup.org/derobins/32/1481_2.png) [@derobins](https://forum.hdfgroup.org/u/derobins)\
**Post date:** [July 27, 2016, 12:24pm UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831/5 "2016-07-27T12:24:39Z")

</div>

Hi Haijun,

If you are still getting a flock error, I'd be suspicious that you aren't linking to the patched HDF5 library. The source patch completely removes flock so you shouldn't be seeing file locking errors.

Dana Robinson  
Software Engineer  
The HDF Group

> **···**
>
> From: Hdf-forum [[mailto:hdf-forum-bounces@lists.hdfgroup.org](mailto:hdf-forum-bounces@lists.hdfgroup.org)] On Behalf Of ???  
> Sent: Wednesday, July 27, 2016 2:16 AM  
> To: HDF Users Discussion List \<[hdf-forum@lists.hdfgroup.org](mailto:hdf-forum@lists.hdfgroup.org)\>  
> Subject: Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi Dana,  
> Thanks for your response.
> 
> I've tried with your method to patch and compile hdf5-1.10.0-patch1 source code. Patch and compile have no error. Unfortunately when run my code the error still exist. And error information is the same as before.
> 
> What should I do? Please help me.
> 
> Thank you again for your effort!
> 
> Haijun Yu
> 
> At 2016-07-26 13:47:39, "Dana Robinson" \<[derobins@hdfgroup.org](mailto:derobins@hdfgroup.org)\<[mailto:derobins@hdfgroup.org](mailto:derobins@hdfgroup.org)\>\> wrote:
> 
> Hi,
> 
> It looks like flock() is not implemented on your filesystem, which is causing the create call to fail. flock() file locking is used by the HDF5 1.10.0 to help enforce single-writer/multiple-readers (SWMR) semantics, but is not necessary for correct operation of the library. A fix for this problem should be available in HDF5 1.10.1, but in the meantime you can apply a source patch found here:
> 
> [https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf](https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf)
> 
> under "Patch to Disable File Locking" at the bottom of the page.
> 
> Cheers,
> 
> Dana Robinson  
> Software Engineer  
> The HDF Group
> 
> From: Hdf-forum [[mailto:hdf-forum-bounces@lists.hdfgroup.org](mailto:hdf-forum-bounces@lists.hdfgroup.org)\<[mailto:hdf-forum-bounces@lists.hdfgroup.org](mailto:hdf-forum-bounces@lists.hdfgroup.org)\>] On Behalf Of ???  
> Sent: Tuesday, July 26, 2016 1:35 AM  
> To: [hdf-forum@lists.hdfgroup.org](mailto:hdf-forum@lists.hdfgroup.org)\<[mailto:hdf-forum@lists.hdfgroup.org](mailto:hdf-forum@lists.hdfgroup.org)\>  
> Subject: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi,  
> I have met an obscure failure, and not find a good solution for two days. Could you help me? Thanks!  
> (Using: hdf5-1.10.0-patch1-linux-centos6-x86\_64-gcc447-shared.tar.gz)  
> (Environment: redhat6.4-Intel-X64-g++4.4.7)
> 
> The error information:  
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:  
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 491 in H5Fcreate(): unable to create file  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file  
> &nbsp;&nbsp;#001: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5Fint.c line 1168 in H5F\_open(): unable to lock the file or initialize file structure  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file  
> &nbsp;&nbsp;#002: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FD.c line 1821 in H5FD\_lock(): driver lock request failed  
> &nbsp;&nbsp;&nbsp;&nbsp;major: Virtual File Layer  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Can't update object  
> &nbsp;&nbsp;#003: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FDsec2.c line 939 in H5FD\_sec2\_lock(): unable to flock file, errno = 38, error message = 'Function not implemented'  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Bad file ID accessed  
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:  
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 749 in H5Fclose(): not a file ID  
> &nbsp;&nbsp;&nbsp;&nbsp;major: Invalid arguments to routine  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Inappropriate type
> 
> compile no error: g++ -c packageHdf5.cpp -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp  
> link no error: g++ -o packageHdf5Run packageHdf5.o -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp  
> run error: ./packageHdf5Run (error information as above)
> 
> My code:
> 
> #include \<stdio.h\>  
> #include \<iostream\>  
> #include \<string\>
> 
> #include "H5Cpp.h"  
> #include \<H5File.h\>  
> #include "hdf5.h"
> 
> #ifndef H5\_NO\_NAMESPACE  
> using namespace H5;  
> #endif
> 
> using namespace std;
> 
> int main(int argc, char\* argv[])  
> {  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hid\_t file\_id = H5Fcreate("/home/tg2hpps/tg2hpps\_main/src/packageHdf5/dsetddd.h5", H5F\_ACC\_TRUNC, H5P\_DEFAULT, H5P\_DEFAULT);
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5Fclose(file\_id);  
> }
> 
> Thanks!

---

<div class="post-metadata">

**Author:** ![1114](https://forum.hdfgroup.org/letter_avatar_proxy/v4/letter/1/77aa72/32.png) [@1114](https://forum.hdfgroup.org/u/1114)\
**Post date:** [July 29, 2016, 3:24am UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831/6 "2016-07-29T03:24:17Z")

</div>

Hi Dana and Prentice,  
&nbsp;&nbsp;&nbsp;&nbsp;  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks for your response.  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I've tried with your method to repatch and recompile hdf5-1.10.0-patch1 source code. And I also checked the three files H5private.h, H5system.c and swmr.c. They were actually changed after run patch. Unfortunately when run my code the error still exist. And error information is the same as before.

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile the hdf5 code as follows:  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;patch -p0 \< file-lock-removal.diff  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./configure --prefix=/home/duc001/3dtools/hdf5-1.10.0 --enable-cxx --with-zlib=/home/duc001/zlib-1.2.8/  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make clean  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make install  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check-install  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo $PATH as follows:  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/duc001/3dtools/hdf5-1.10.0/bin

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile my code as follows:  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;g++ -c test.cpp -I /home/duc001/3dtools/hdf5-1.10.0/include -L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp //no error  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;g++ -o testRun test.o -I /home/duc001/3dtools/hdf5-1.10.0/include -L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp //no error  
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./testRun // with error

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Are there any questions in the above operation?

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks again for your effort!

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu

> **···**
>
> At 2016-07-27 21:46:43, "Prentice Bisbal" \<[pbisbal@pppl.gov](mailto:pbisbal@pppl.gov)\> wrote:  
> Haijun,
> 
> Did do a 'make clean' or (even better) 'make distclean' before recompiling your code? Make is supposed to determine that the source files are newer than the object files and build all the object files that depend on those source files and so on, but it's possible that the dependency tree broke down somewhere.
> 
> I would recommend deleting your entire HDF5 source directory, unzipping HDF again, applying the patch, and the going through the configure and make process again.
> 
> Prentice  
> On 07/27/2016 08:24 AM, Dana Robinson wrote:
> 
> Hi Haijun,
> 
> If you are still getting a flock error, I'd be suspicious that you aren't linking to the patched HDF5 library. The source patch completely removes flock so you shouldn't be seeing file locking errors.
> 
> Dana Robinson
> 
> Software Engineer
> 
> The HDF Group
> 
> From: Hdf-forum [[mailto:hdf-forum-bounces@lists.hdfgroup.org](mailto:hdf-forum-bounces@lists.hdfgroup.org)] On Behalf Of ???  
> Sent: Wednesday, July 27, 2016 2:16 AM  
> To: HDF Users Discussion List \<[hdf-forum@lists.hdfgroup.org](mailto:hdf-forum@lists.hdfgroup.org)\>  
> Subject: Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi Dana,
> 
> Thanks for your response.
> 
> I've tried with your method to patch and compile hdf5-1.10.0-patch1 source code. Patch and compile have no error. Unfortunately when run my code the error still exist. And error information is the same as before.
> 
> What should I do? Please help me.
> 
> Thank you again for your effort!
> 
> Haijun Yu
> 
> At 2016-07-26 13:47:39, "Dana Robinson" \<[derobins@hdfgroup.org](mailto:derobins@hdfgroup.org)\> wrote:
> 
> Hi,
> 
> It looks like flock() is not implemented on your filesystem, which is causing the create call to fail. flock() file locking is used by the HDF5 1.10.0 to help enforce single-writer/multiple-readers (SWMR) semantics, but is not necessary for correct operation of the library. A fix for this problem should be available in HDF5 1.10.1, but in the meantime you can apply a source patch found here:
> 
> [https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf](https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf)
> 
> under "Patch to Disable File Locking" at the bottom of the page.
> 
> Cheers,
> 
> Dana Robinson
> 
> Software Engineer
> 
> The HDF Group
> 
> From: Hdf-forum [[mailto:hdf-forum-bounces@lists.hdfgroup.org](mailto:hdf-forum-bounces@lists.hdfgroup.org)] On Behalf Of ???  
> Sent: Tuesday, July 26, 2016 1:35 AM  
> [To:hdf-forum@lists.hdfgroup.org](mailto:To:hdf-forum@lists.hdfgroup.org)  
> Subject: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi,
> 
> I have met an obscure failure, and not find a good solution for two days. Could you help me? Thanks!
> 
> (Using: hdf5-1.10.0-patch1-linux-centos6-x86\_64-gcc447-shared.tar.gz)
> 
> (Environment: redhat6.4-Intel-X64-g++4.4.7)
> 
> The error information:
> 
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> 
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 491 in H5Fcreate(): unable to create file
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> 
> &nbsp;&nbsp;#001: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5Fint.c line 1168 in H5F\_open(): unable to lock the file or initialize file structure
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> 
> &nbsp;&nbsp;#002: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FD.c line 1821 in H5FD\_lock(): driver lock request failed
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: Virtual File Layer
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Can't update object
> 
> &nbsp;&nbsp;#003: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FDsec2.c line 939 in H5FD\_sec2\_lock(): unable to flock file, errno = 38, error message = 'Function not implemented'
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Bad file ID accessed
> 
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> 
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 749 in H5Fclose(): not a file ID
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: Invalid arguments to routine
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Inappropriate type
> 
> compile no error: g++ -c packageHdf5.cpp -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp
> 
> link no error: g++ -o packageHdf5Run packageHdf5.o -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp
> 
> run error: ./packageHdf5Run (error information as above)
> 
> My code:
> 
> #include \<stdio.h\>
> 
> #include \<iostream\>
> 
> #include \<string\>
> 
> #include "H5Cpp.h"
> 
> #include \<H5File.h\>
> 
> #include "hdf5.h"
> 
> #ifndef H5\_NO\_NAMESPACE
> 
> using namespace H5;
> 
> #endif
> 
> using namespace std;
> 
> int main(int argc, char\* argv[])
> 
> {
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hid\_t file\_id = H5Fcreate("/home/tg2hpps/tg2hpps\_main/src/packageHdf5/dsetddd.h5", H5F\_ACC\_TRUNC, H5P\_DEFAULT, H5P\_DEFAULT);
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5Fclose(file\_id);
> 
> }
> 
> Thanks!
> 
> \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> Hdf-forum is for HDF software users discussion.  
> Hdf-forum@lists.hdfgroup.orghttp://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org  
> Twitter: [https://twitter.com/hdf5](https://twitter.com/hdf5)

---

<div class="post-metadata">

**Author:** ![pbisbal](https://forum.hdfgroup.org/letter_avatar_proxy/v4/letter/p/8e7dd6/32.png) [@pbisbal](https://forum.hdfgroup.org/u/pbisbal)\
**Post date:** [July 29, 2016, 1:42pm UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831/7 "2016-07-29T13:42:50Z")

</div>

I know this may sound like a stupid question, but I have to ask, because I've learned never to assume things: Are you sure you have write access where you're trying to create this file? Have you confirmed this by going the directory where you are trying to create the directory and doing 'touch test', which will create an empty file named "test"?

Prentice

> **···**
>
> On 07/28/2016 11:24 PM, 于海军 wrote:
> 
> > Hi Dana and Prentice,  
> > Thanks for your response.  
> > I've tried with your method to repatch and recompile hdf5-1.10.0-patch1 source code. And I also checked the three files H5private.h, H5system.c and swmr.c. They were actually changed after run patch. Unfortunately when run my code the error still exist. And error information is the same as before.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile the hdf5 code as follows:  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;patch -p0 \< file-lock-removal.diff  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./configure --prefix=/home/duc001/3dtools/hdf5-1.10.0 --enable-cxx --with-zlib=/home/duc001/zlib-1.2.8/  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make clean  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make install  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check-install  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo $PATH as follows:  
> > /home/duc001/3dtools/hdf5-1.10.0/bin
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile my code as follows:  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;g++ -c test.cpp -I /home/duc001/3dtools/hdf5-1.10.0/include -L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp //no error  
> > g++ -o testRun test.o -I /home/duc001/3dtools/hdf5-1.10.0/include -L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp //no error  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./testRun // with error
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Are there any questions in the above operation?
> > 
> > Thanks again for your effort!
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu
> > 
> > At 2016-07-27 21:46:43, "Prentice Bisbal" \<pbisbal@pppl.gov\> wrote:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Haijun,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Did do a 'make clean' or (even better) 'make distclean' before  
> > &nbsp;&nbsp;&nbsp;&nbsp;recompiling your code? Make is supposed to determine that the  
> > &nbsp;&nbsp;&nbsp;&nbsp;source files are newer than the object files and build all the  
> > &nbsp;&nbsp;&nbsp;&nbsp;object files that depend on those source files and so on, but it's  
> > &nbsp;&nbsp;&nbsp;&nbsp;possible that the dependency tree broke down somewhere.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;I would recommend deleting your entire HDF5 source directory,  
> > &nbsp;&nbsp;&nbsp;&nbsp;unzipping HDF again, applying the patch, and the going through  
> > &nbsp;&nbsp;&nbsp;&nbsp;the configure and make process again.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Prentice
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;On 07/27/2016 08:24 AM, Dana Robinson wrote:
> > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;Hi Haijun,
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;If you are still getting a flock error, I'd be suspicious that  
> > > &nbsp;&nbsp;&nbsp;&nbsp;you aren't linking to the patched HDF5 library. The source patch  
> > > &nbsp;&nbsp;&nbsp;&nbsp;completely removes flock so you shouldn't be seeing file locking  
> > > &nbsp;&nbsp;&nbsp;&nbsp;errors.
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;Dana Robinson
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;Software Engineer
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;The HDF Group
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;\*From:\*Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org]  
> > > &nbsp;&nbsp;&nbsp;&nbsp;\*On Behalf Of \*???  
> > > &nbsp;&nbsp;&nbsp;&nbsp;\*Sent:\* Wednesday, July 27, 2016 2:16 AM  
> > > &nbsp;&nbsp;&nbsp;&nbsp;\*To:\* HDF Users Discussion List \<hdf-forum@lists.hdfgroup.org\>  
> > > &nbsp;&nbsp;&nbsp;&nbsp;\*Subject:\* Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread  
> > > &nbsp;&nbsp;&nbsp;&nbsp;0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hi Dana,
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks for your response.
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I've tried with your method to patch and compile  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hdf5-1.10.0-patch1 source code. Patch and compile have no  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;error. Unfortunately when run my code the error still exist.  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;And error information is the same as before.
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;What should I do? Please help me.
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thank you again for your effort!
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;At 2016-07-26 13:47:39, "Dana Robinson" \<derobins@hdfgroup.org \>\> \<mailto:derobins@hdfgroup.org\>\> wrote:
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hi,
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;It looks like flock() is not implemented on your filesystem,  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;which is causing the create call to fail. flock() file  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;locking is used by the HDF5 1.10.0 to help enforce  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;single-writer/multiple-readers (SWMR) semantics, but is not  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;necessary for correct operation of the library. A fix for  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;this problem should be available in HDF5 1.10.1, but in the  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;meantime you can apply a source patch found here:
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf](https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf)
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;under "Patch to Disable File Locking" at the bottom of the page.
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cheers,
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Dana Robinson
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Software Engineer
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The HDF Group
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*From:\*Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\<mailto:hdf-forum-bounces@lists.hdfgroup.org\>] \*On Behalf Of \*???  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*Sent:\* Tuesday, July 26, 2016 1:35 AM  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*To:\* hdf-forum@lists.hdfgroup.org  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\<mailto:hdf-forum@lists.hdfgroup.org\>  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*Subject:\* [Hdf-forum] Error detected in HDF5 (1.10.0) thread  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hi,
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I have met an obscure failure, and not find a good solution  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;for two days. Could you help me? Thanks!
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(Using:  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hdf5-1.10.0-patch1-linux-centos6-x86\_64-gcc447-shared.tar.gz)
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(Environment: redhat6.4-Intel-X64-g++4.4.7)
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The error information:
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#000:  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;line 491 in H5Fcreate(): unable to create file
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#001:  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5Fint.c  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;line 1168 in H5F\_open(): unable to lock the file or  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;initialize file structure
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#002:  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FD.c  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;line 1821 in H5FD\_lock(): driver lock request failed
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: Virtual File Layer
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Can't update object
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#003:  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FDsec2.c  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;line 939 in H5FD\_sec2\_lock(): unable to flock file, errno =  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;38, error message = 'Function not implemented'
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Bad file ID accessed
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#000:  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;line 749 in H5Fclose(): not a file ID
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: Invalid arguments to routine
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Inappropriate type
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;compile no error: g++ -c packageHdf5.cpp -I ../latest/include  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-L ../latest/lib -lhdf5 -lhdf5\_cpp
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;link no error: g++ -o packageHdf5Run packageHdf5.o -I  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;run error: ./packageHdf5Run (error information as above)
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;My code:
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include \<stdio.h\>
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include \<iostream\>
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include \<string\>
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include "H5Cpp.h"
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include \<H5File.h\>
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include "hdf5.h"
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#ifndef H5\_NO\_NAMESPACE
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;using namespace H5;
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#endif
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;using namespace std;
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;int main(int argc, char\* argv)
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hid\_t file\_id =  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5Fcreate("/home/tg2hpps/tg2hpps\_main/src/packageHdf5/dsetddd.h5",  
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5F\_ACC\_TRUNC, H5P\_DEFAULT, H5P\_DEFAULT);
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5Fclose(file\_id);
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks!
> > > 
> > > &nbsp;&nbsp;&nbsp;&nbsp;\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> > > &nbsp;&nbsp;&nbsp;&nbsp;Hdf-forum is for HDF software users discussion.  
> > > &nbsp;&nbsp;&nbsp;&nbsp;Hdf-forum@lists.hdfgroup.org  
> > > &nbsp;&nbsp;&nbsp;&nbsp;[http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)  
> > > &nbsp;&nbsp;&nbsp;&nbsp;Twitter:[x.com](https://twitter.com/hdf5)
> > 
> > \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> > Hdf-forum is for HDF software users discussion.  
> > Hdf-forum@lists.hdfgroup.org  
> > [http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)  
> > Twitter: [x.com](https://twitter.com/hdf5)

---

<div class="post-metadata">

**Author:** ![derobins](https://forum.hdfgroup.org/user_avatar/forum.hdfgroup.org/derobins/32/1481_2.png) [@derobins](https://forum.hdfgroup.org/u/derobins)\
**Post date:** [July 29, 2016, 3:40pm UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831/8 "2016-07-29T15:40:52Z")

</div>

Hi all,

The source patch removes all references to flock() so this error should not be occurring, regardless of the permissions. If you are still seeing errors, I suspect that you are linking to a different HDF5 library than the one you patched.

One thing I would try is, instead of using g++ directly, try using the h5c++ compiler wrapper that should be located in the bin directory of the HDF5 install. That will ensure that you are linking to the correct libraries. When you use h5c++, you won't need to include the -I, -L, and -l flags for HDF5 paths and libraries since h5c++ sets that up for you.

Dana Robinson  
Software Engineer  
The HDF Group

> **···**
>
> From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org] On Behalf Of Prentice Bisbal  
> Sent: Friday, July 29, 2016 9:43 AM  
> To: hdf-forum@lists.hdfgroup.org  
> Subject: Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> I know this may sound like a stupid question, but I have to ask, because I've learned never to assume things: Are you sure you have write access where you're trying to create this file? Have you confirmed this by going the directory where you are trying to create the directory and doing 'touch test', which will create an empty file named "test"?
> 
> Prentice  
> On 07/28/2016 11:24 PM, 于海军 wrote:  
> Hi Dana and Prentice,
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks for your response.  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I've tried with your method to repatch and recompile hdf5-1.10.0-patch1 source code. And I also checked the three files H5private.h, H5system.c and swmr.c. They were actually changed after run patch. Unfortunately when run my code the error still exist. And error information is the same as before.
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile the hdf5 code as follows:  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;patch -p0 \< file-lock-removal.diff  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./configure --prefix=/home/duc001/3dtools/hdf5-1.10.0 --enable-cxx --with-zlib=/home/duc001/zlib-1.2.8/  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make clean  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make install  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check-install
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo $PATH as follows:  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/duc001/3dtools/hdf5-1.10.0/bin
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile my code as follows:  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;g++ -c test.cpp -I /home/duc001/3dtools/hdf5-1.10.0/include -L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp //no error  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;g++ -o testRun test.o -I /home/duc001/3dtools/hdf5-1.10.0/include -L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp //no error  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./testRun // with error
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Are there any questions in the above operation?
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks again for your effort!
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu
> 
> At 2016-07-27 21:46:43, "Prentice Bisbal" \<pbisbal@pppl.gov\>\<mailto:pbisbal@pppl.gov\> wrote:
> 
> Haijun,
> 
> Did do a 'make clean' or (even better) 'make distclean' before recompiling your code? Make is supposed to determine that the source files are newer than the object files and build all the object files that depend on those source files and so on, but it's possible that the dependency tree broke down somewhere.
> 
> I would recommend deleting your entire HDF5 source directory, unzipping HDF again, applying the patch, and the going through the configure and make process again.
> 
> Prentice  
> On 07/27/2016 08:24 AM, Dana Robinson wrote:  
> Hi Haijun,
> 
> If you are still getting a flock error, I'd be suspicious that you aren't linking to the patched HDF5 library. The source patch completely removes flock so you shouldn't be seeing file locking errors.
> 
> Dana Robinson  
> Software Engineer  
> The HDF Group
> 
> From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org] On Behalf Of ???  
> Sent: Wednesday, July 27, 2016 2:16 AM  
> To: HDF Users Discussion List \<hdf-forum@lists.hdfgroup.org\>\<mailto:hdf-forum@lists.hdfgroup.org\>  
> Subject: Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi Dana,  
> Thanks for your response.
> 
> I've tried with your method to patch and compile hdf5-1.10.0-patch1 source code. Patch and compile have no error. Unfortunately when run my code the error still exist. And error information is the same as before.
> 
> What should I do? Please help me.
> 
> Thank you again for your effort!
> 
> Haijun Yu
> 
> At 2016-07-26 13:47:39, "Dana Robinson" \<derobins@hdfgroup.org\<mailto:derobins@hdfgroup.org\>\> wrote:
> 
> Hi,
> 
> It looks like flock() is not implemented on your filesystem, which is causing the create call to fail. flock() file locking is used by the HDF5 1.10.0 to help enforce single-writer/multiple-readers (SWMR) semantics, but is not necessary for correct operation of the library. A fix for this problem should be available in HDF5 1.10.1, but in the meantime you can apply a source patch found here:
> 
> [https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf](https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf)
> 
> under "Patch to Disable File Locking" at the bottom of the page.
> 
> Cheers,
> 
> Dana Robinson  
> Software Engineer  
> The HDF Group
> 
> From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org\<mailto:hdf-forum-bounces@lists.hdfgroup.org\>] On Behalf Of ???  
> Sent: Tuesday, July 26, 2016 1:35 AM  
> To: hdf-forum@lists.hdfgroup.org\<mailto:hdf-forum@lists.hdfgroup.org\>  
> Subject: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi,  
> I have met an obscure failure, and not find a good solution for two days. Could you help me? Thanks!  
> (Using: hdf5-1.10.0-patch1-linux-centos6-x86\_64-gcc447-shared.tar.gz)  
> (Environment: redhat6.4-Intel-X64-g++4.4.7)
> 
> The error information:  
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:  
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 491 in H5Fcreate(): unable to create file  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file  
> &nbsp;&nbsp;#001: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5Fint.c line 1168 in H5F\_open(): unable to lock the file or initialize file structure  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file  
> &nbsp;&nbsp;#002: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FD.c line 1821 in H5FD\_lock(): driver lock request failed  
> &nbsp;&nbsp;&nbsp;&nbsp;major: Virtual File Layer  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Can't update object  
> &nbsp;&nbsp;#003: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FDsec2.c line 939 in H5FD\_sec2\_lock(): unable to flock file, errno = 38, error message = 'Function not implemented'  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Bad file ID accessed  
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:  
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 749 in H5Fclose(): not a file ID  
> &nbsp;&nbsp;&nbsp;&nbsp;major: Invalid arguments to routine  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Inappropriate type
> 
> compile no error: g++ -c packageHdf5.cpp -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp  
> link no error: g++ -o packageHdf5Run packageHdf5.o -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp  
> run error: ./packageHdf5Run (error information as above)
> 
> My code:
> 
> #include \<stdio.h\>  
> #include \<iostream\>  
> #include \<string\>
> 
> #include "H5Cpp.h"  
> #include \<H5File.h\>  
> #include "hdf5.h"
> 
> #ifndef H5\_NO\_NAMESPACE  
> using namespace H5;  
> #endif
> 
> using namespace std;
> 
> int main(int argc, char\* argv[])  
> {  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hid\_t file\_id = H5Fcreate("/home/tg2hpps/tg2hpps\_main/src/packageHdf5/dsetddd.h5", H5F\_ACC\_TRUNC, H5P\_DEFAULT, H5P\_DEFAULT);
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5Fclose(file\_id);  
> }
> 
> Thanks!
> 
> \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_
> 
> Hdf-forum is for HDF software users discussion.
> 
> Hdf-forum@lists.hdfgroup.org\<mailto:Hdf-forum@lists.hdfgroup.org\>
> 
> [http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)
> 
> Twitter: [https://twitter.com/hdf5](https://twitter.com/hdf5)
> 
> \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_
> 
> Hdf-forum is for HDF software users discussion.
> 
> Hdf-forum@lists.hdfgroup.org\<mailto:Hdf-forum@lists.hdfgroup.org\>
> 
> [http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)
> 
> Twitter: [https://twitter.com/hdf5](https://twitter.com/hdf5)

---

<div class="post-metadata">

**Author:** ![1114](https://forum.hdfgroup.org/letter_avatar_proxy/v4/letter/1/77aa72/32.png) [@1114](https://forum.hdfgroup.org/u/1114)\
**Post date:** [August 1, 2016, 3:14am UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831/9 "2016-08-01T03:14:50Z")

</div>

Hi Dana and Prentice,

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks for your help.

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;My problem has been solved perfectly. I use the h5c++ compiler to compile the code, and it works. Wonderful!

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Maybe I linked to the error libraries when I linked mannually.

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks again for your help!

&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu

> **···**
>
> At 2016-07-29 23:40:52, "Dana Robinson" \<derobins@hdfgroup.org\> wrote:
> 
> Hi all,
> 
> The source patch removes all references to flock() so this error should not be occurring, regardless of the permissions. If you are still seeing errors, I suspect that you are linking to a different HDF5 library than the one you patched.
> 
> One thing I would try is, instead of using g++ directly, try using the h5c++ compiler wrapper that should be located in the bin directory of the HDF5 install. That will ensure that you are linking to the correct libraries. When you use h5c++, you won't need to include the -I, -L, and -l flags for HDF5 paths and libraries since h5c++ sets that up for you.
> 
> Dana Robinson
> 
> Software Engineer
> 
> The HDF Group
> 
> From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org] On Behalf Of Prentice Bisbal  
> Sent: Friday, July 29, 2016 9:43 AM  
> To:hdf-forum@lists.hdfgroup.org  
> Subject: Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> I know this may sound like a stupid question, but I have to ask, because I've learned never to assume things: Are you sure you have write access where you're trying to create this file? Have you confirmed this by going the directory where you are trying to create the directory and doing 'touch test', which will create an empty file named "test"?
> 
> Prentice
> 
> On 07/28/2016 11:24 PM, 于海军 wrote:
> 
> Hi Dana and Prentice,
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks for your response.
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I've tried with your method to repatch and recompile hdf5-1.10.0-patch1 source code. And I also checked the three files H5private.h, H5system.c and swmr.c. They were actually changed after run patch. Unfortunately when run my code the error still exist. And error information is the same as before.
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile the hdf5 code as follows:
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;patch -p0 \< file-lock-removal.diff
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./configure --prefix=/home/duc001/3dtools/hdf5-1.10.0 --enable-cxx --with-zlib=/home/duc001/zlib-1.2.8/
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make clean
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make install
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check-install
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo $PATH as follows:
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/duc001/3dtools/hdf5-1.10.0/bin
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile my code as follows:
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;g++ -c test.cpp -I /home/duc001/3dtools/hdf5-1.10.0/include -L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp //no error
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;g++ -o testRun test.o -I /home/duc001/3dtools/hdf5-1.10.0/include -L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp //no error
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./testRun // with error
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Are there any questions in the above operation?
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks again for your effort!
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu
> 
> At 2016-07-27 21:46:43, "Prentice Bisbal" \<pbisbal@pppl.gov\> wrote:
> 
> Haijun,
> 
> Did do a 'make clean' or (even better) 'make distclean' before recompiling your code? Make is supposed to determine that the source files are newer than the object files and build all the object files that depend on those source files and so on, but it's possible that the dependency tree broke down somewhere.
> 
> I would recommend deleting your entire HDF5 source directory, unzipping HDF again, applying the patch, and the going through the configure and make process again.
> 
> Prentice
> 
> On 07/27/2016 08:24 AM, Dana Robinson wrote:
> 
> Hi Haijun,
> 
> If you are still getting a flock error, I'd be suspicious that you aren't linking to the patched HDF5 library. The source patch completely removes flock so you shouldn't be seeing file locking errors.
> 
> Dana Robinson
> 
> Software Engineer
> 
> The HDF Group
> 
> From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org] On Behalf Of ???  
> Sent: Wednesday, July 27, 2016 2:16 AM  
> To: HDF Users Discussion List \<hdf-forum@lists.hdfgroup.org\>  
> Subject: Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi Dana,
> 
> Thanks for your response.
> 
> I've tried with your method to patch and compile hdf5-1.10.0-patch1 source code. Patch and compile have no error. Unfortunately when run my code the error still exist. And error information is the same as before.
> 
> What should I do? Please help me.
> 
> Thank you again for your effort!
> 
> Haijun Yu
> 
> At 2016-07-26 13:47:39, "Dana Robinson" \<derobins@hdfgroup.org\> wrote:
> 
> Hi,
> 
> It looks like flock() is not implemented on your filesystem, which is causing the create call to fail. flock() file locking is used by the HDF5 1.10.0 to help enforce single-writer/multiple-readers (SWMR) semantics, but is not necessary for correct operation of the library. A fix for this problem should be available in HDF5 1.10.1, but in the meantime you can apply a source patch found here:
> 
> [https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf](https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf)
> 
> under "Patch to Disable File Locking" at the bottom of the page.
> 
> Cheers,
> 
> Dana Robinson
> 
> Software Engineer
> 
> The HDF Group
> 
> From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org] On Behalf Of ???  
> Sent: Tuesday, July 26, 2016 1:35 AM  
> To:hdf-forum@lists.hdfgroup.org  
> Subject: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi,
> 
> I have met an obscure failure, and not find a good solution for two days. Could you help me? Thanks!
> 
> (Using: hdf5-1.10.0-patch1-linux-centos6-x86\_64-gcc447-shared.tar.gz)
> 
> (Environment: redhat6.4-Intel-X64-g++4.4.7)
> 
> The error information:
> 
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> 
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 491 in H5Fcreate(): unable to create file
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> 
> &nbsp;&nbsp;#001: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5Fint.c line 1168 in H5F\_open(): unable to lock the file or initialize file structure
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> 
> &nbsp;&nbsp;#002: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FD.c line 1821 in H5FD\_lock(): driver lock request failed
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: Virtual File Layer
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Can't update object
> 
> &nbsp;&nbsp;#003: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FDsec2.c line 939 in H5FD\_sec2\_lock(): unable to flock file, errno = 38, error message = 'Function not implemented'
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Bad file ID accessed
> 
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> 
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 749 in H5Fclose(): not a file ID
> 
> &nbsp;&nbsp;&nbsp;&nbsp;major: Invalid arguments to routine
> 
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Inappropriate type
> 
> compile no error: g++ -c packageHdf5.cpp -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp
> 
> link no error: g++ -o packageHdf5Run packageHdf5.o -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp
> 
> run error: ./packageHdf5Run (error information as above)
> 
> My code:
> 
> #include \<stdio.h\>
> 
> #include \<iostream\>
> 
> #include \<string\>
> 
> #include "H5Cpp.h"
> 
> #include \<H5File.h\>
> 
> #include "hdf5.h"
> 
> #ifndef H5\_NO\_NAMESPACE
> 
> using namespace H5;
> 
> #endif
> 
> using namespace std;
> 
> int main(int argc, char\* argv[])
> 
> {
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hid\_t file\_id = H5Fcreate("/home/tg2hpps/tg2hpps\_main/src/packageHdf5/dsetddd.h5", H5F\_ACC\_TRUNC, H5P\_DEFAULT, H5P\_DEFAULT);
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5Fclose(file\_id);
> 
> }
> 
> Thanks!
> 
> \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> Hdf-forum is for HDF software users discussion.  
> Hdf-forum@lists.hdfgroup.org  
> [http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)  
> Twitter: [https://twitter.com/hdf5](https://twitter.com/hdf5)
> 
> \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> Hdf-forum is for HDF software users discussion.  
> Hdf-forum@lists.hdfgroup.org  
> [http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)  
> Twitter: [https://twitter.com/hdf5](https://twitter.com/hdf5)

---

<div class="post-metadata">

**Author:** ![pbisbal](https://forum.hdfgroup.org/letter_avatar_proxy/v4/letter/p/8e7dd6/32.png) [@pbisbal](https://forum.hdfgroup.org/u/pbisbal)\
**Post date:** [August 1, 2016, 5:02pm UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831/10 "2016-08-01T17:02:50Z")

</div>

Great news! Thanks for letting us know.

Prentice

> **···**
>
> On 07/31/2016 11:14 PM, 于海军 wrote:
> 
> > Hi Dana and Prentice,
> > 
> > Thanks for your help.
> > 
> > &nbsp;&nbsp;&nbsp;My problem has been solved perfectly. I use the h5c++ compiler to compile the code, and it works. Wonderful!
> > 
> > Maybe I linked to the error libraries when I linked mannually.
> > 
> > Thanks again for your help!
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu
> > 
> > At 2016-07-29 23:40:52, "Dana Robinson" \<derobins@hdfgroup.org\> wrote:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Hi all,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;The source patch removes all references to flock() so this error  
> > &nbsp;&nbsp;&nbsp;&nbsp;should not be occurring, regardless of the permissions. If you are  
> > &nbsp;&nbsp;&nbsp;&nbsp;still seeing errors, I suspect that you are linking to a different  
> > &nbsp;&nbsp;&nbsp;&nbsp;HDF5 library than the one you patched.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;One thing I would try is, instead of using g++ directly, try using  
> > &nbsp;&nbsp;&nbsp;&nbsp;the h5c++ compiler wrapper that should be located in the bin  
> > &nbsp;&nbsp;&nbsp;&nbsp;directory of the HDF5 install. That will ensure that you are  
> > &nbsp;&nbsp;&nbsp;&nbsp;linking to the correct libraries. When you use h5c++, you won't  
> > &nbsp;&nbsp;&nbsp;&nbsp;need to include the -I, -L, and -l flags for HDF5 paths and  
> > &nbsp;&nbsp;&nbsp;&nbsp;libraries since h5c++ sets that up for you.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Dana Robinson
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Software Engineer
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;The HDF Group
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;\*From:\*Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org  
> > &nbsp;&nbsp;&nbsp;&nbsp;\<mailto:hdf-forum-bounces@lists.hdfgroup.org\>] \*On Behalf Of  
> > &nbsp;&nbsp;&nbsp;&nbsp;\*Prentice Bisbal  
> > &nbsp;&nbsp;&nbsp;&nbsp;\*Sent:\* Friday, July 29, 2016 9:43 AM  
> > &nbsp;&nbsp;&nbsp;&nbsp;\*To:\* hdf-forum@lists.hdfgroup.org  
> > &nbsp;&nbsp;&nbsp;&nbsp;\<mailto:hdf-forum@lists.hdfgroup.org\>  
> > &nbsp;&nbsp;&nbsp;&nbsp;\*Subject:\* Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread  
> > &nbsp;&nbsp;&nbsp;&nbsp;0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;I know this may sound like a stupid question, but I have to ask,  
> > &nbsp;&nbsp;&nbsp;&nbsp;because I've learned never to assume things: Are you sure you have  
> > &nbsp;&nbsp;&nbsp;&nbsp;write access where you're trying to create this file? Have you  
> > &nbsp;&nbsp;&nbsp;&nbsp;confirmed this by going the directory where you are trying to  
> > &nbsp;&nbsp;&nbsp;&nbsp;create the directory and doing 'touch test', which will create an  
> > &nbsp;&nbsp;&nbsp;&nbsp;empty file named "test"?
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;Prentice
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;On 07/28/2016 11:24 PM, 于海军 wrote:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hi Dana and Prentice,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks for your response.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I've tried with your method to repatch and recompile  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hdf5-1.10.0-patch1 source code. And I also checked the three  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;files H5private.h, H5system.c and swmr.c. They were actually  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;changed after run patch. Unfortunately when run my code the  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;error still exist. And error information is the same as before.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile the hdf5 code as follows:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;patch -p0 \< file-lock-removal.diff
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./configure --prefix=/home/duc001/3dtools/hdf5-1.10.0  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;--enable-cxx --with-zlib=/home/duc001/zlib-1.2.8/
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make clean
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make install
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check-install
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo $PATH as follows:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/duc001/3dtools/hdf5-1.10.0/bin
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile my code as follows:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;g++ -c test.cpp  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-I /home/duc001/3dtools/hdf5-1.10.0/include  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//no error
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;g++ -o testRun test.o  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-I /home/duc001/3dtools/hdf5-1.10.0/include  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;//no error
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./testRun // with error
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Are there any questions in the above operation?
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks again for your effort!
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;At 2016-07-27 21:46:43, "Prentice Bisbal" \<pbisbal@pppl.gov\> \> \<mailto:pbisbal@pppl.gov\>wrote:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Did do a 'make clean' or (even better) 'make distclean'  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;before recompiling your code? Make is supposed to  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;determine that the source files are newer than the object  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;files and build all the object files that depend on those  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;source files and so on, but it's possible that the  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;dependency tree broke down somewhere.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I would recommend deleting your entire HDF5 source  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;directory, unzipping HDF again, applying the patch, and  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;the going through the configure and make process again.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Prentice
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;On 07/27/2016 08:24 AM, Dana Robinson wrote:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hi Haijun,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;If you are still getting a flock error, I'd be  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;suspicious that you aren't linking to the patched HDF5  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;library. The source patch completely removes flock so  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;you shouldn't be seeing file locking errors.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Dana Robinson
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Software Engineer
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The HDF Group
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*From:\*Hdf-forum  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[mailto:hdf-forum-bounces@lists.hdfgroup.org] \*On  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Behalf Of \*???  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*Sent:\* Wednesday, July 27, 2016 2:16 AM  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*To:\* HDF Users Discussion List  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\<hdf-forum@lists.hdfgroup.org\>  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\<mailto:hdf-forum@lists.hdfgroup.org\>  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*Subject:\* Re: [Hdf-forum] Error detected in HDF5  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(1.10.0) thread 0:  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hi Dana,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks for your response.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I've tried with your method to patch and compile  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hdf5-1.10.0-patch1 source code. Patch and compile  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;have no error. Unfortunately when run my code the  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;error still exist. And error information is the  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;same as before.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;What should I do? Please help me.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thank you again for your effort!
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;At 2016-07-26 13:47:39, "Dana Robinson" \> \<derobins@hdfgroup.org \<mailto:derobins@hdfgroup.org\>\> \> wrote:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hi,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;It looks like flock() is not implemented on your  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;filesystem, which is causing the create call to  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;fail. flock() file locking is used by the HDF5  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;1.10.0 to help enforce  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;single-writer/multiple-readers (SWMR) semantics,  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;but is not necessary for correct operation of the  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;library. A fix for this problem should be  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;available in HDF5 1.10.1, but in the meantime you  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;can apply a source patch found here:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf](https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;under "Patch to Disable File Locking" at the  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;bottom of the page.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Cheers,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Dana Robinson
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Software Engineer
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The HDF Group
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*From:\*Hdf-forum  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[mailto:hdf-forum-bounces@lists.hdfgroup.org  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\<mailto:hdf-forum-bounces@lists.hdfgroup.org\>] \*On  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Behalf Of \*???  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*Sent:\* Tuesday, July 26, 2016 1:35 AM  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*To:\* hdf-forum@lists.hdfgroup.org  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\<mailto:hdf-forum@lists.hdfgroup.org\>  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\*Subject:\* [Hdf-forum] Error detected in HDF5  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(1.10.0) thread 0:  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hi,
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I have met an obscure failure, and not find a good  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;solution for two days. Could you help me? Thanks!
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(Using:  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hdf5-1.10.0-patch1-linux-centos6-x86\_64-gcc447-shared.tar.gz)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;(Environment: redhat6.4-Intel-X64-g++4.4.7)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;The error information:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#000:  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;line 491 in H5Fcreate(): unable to create file
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#001:  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5Fint.c  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;line 1168 in H5F\_open(): unable to lock the file  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;or initialize file structure
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#002:  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FD.c  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;line 1821 in H5FD\_lock(): driver lock request failed
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: Virtual File Layer
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Can't update object
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#003:  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FDsec2.c  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;line 939 in H5FD\_sec2\_lock(): unable to flock  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;file, errno = 38, error message = 'Function not  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;implemented'
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Bad file ID accessed
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#000:  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;line 749 in H5Fclose(): not a file ID
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;major: Invalid arguments to routine
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;minor: Inappropriate type
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;compile no error: g++ -c packageHdf5.cpp -I  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;link no error: g++ -o packageHdf5Run packageHdf5.o  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-I ../latest/include -L ../latest/lib -lhdf5  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;-lhdf5\_cpp
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;run error: ./packageHdf5Run (error information  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;as above)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;My code:
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include \<stdio.h\>
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include \<iostream\>
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include \<string\>
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include "H5Cpp.h"
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include \<H5File.h\>
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#include "hdf5.h"
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#ifndef H5\_NO\_NAMESPACE
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;using namespace H5;
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;#endif
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;using namespace std;
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;int main(int argc, char\* argv)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;{
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hid\_t file\_id =  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5Fcreate("/home/tg2hpps/tg2hpps\_main/src/packageHdf5/dsetddd.h5",  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5F\_ACC\_TRUNC, H5P\_DEFAULT, H5P\_DEFAULT);
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5Fclose(file\_id);
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;}
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks!
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hdf-forum is for HDF software users discussion.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hdf-forum@lists.hdfgroup.org  
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\<mailto:Hdf-forum@lists.hdfgroup.org\>
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Twitter:[x.com](https://twitter.com/hdf5)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hdf-forum is for HDF software users discussion.
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Hdf-forum@lists.hdfgroup.org \<mailto:Hdf-forum@lists.hdfgroup.org\>
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;[http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)
> > 
> > &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Twitter:[x.com](https://twitter.com/hdf5)
> > 
> > \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_  
> > Hdf-forum is for HDF software users discussion.  
> > Hdf-forum@lists.hdfgroup.org  
> > [http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)  
> > Twitter: [x.com](https://twitter.com/hdf5)

---

<div class="post-metadata">

**Author:** ![derobins](https://forum.hdfgroup.org/user_avatar/forum.hdfgroup.org/derobins/32/1481_2.png) [@derobins](https://forum.hdfgroup.org/u/derobins)\
**Post date:** [August 1, 2016, 3:45pm UTC](https://forum.hdfgroup.org/t/error-detected-in-hdf5-1-10-0-thread-0-home-hdftest-snapshots-hdf5-1-10-alpha-current-src/3831/11 "2016-08-01T15:45:39Z")

</div>

Great! Glad that worked for you.

Dana

> **···**
>
> From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org] On Behalf Of ???  
> Sent: Sunday, July 31, 2016 11:15 PM  
> To: HDF Users Discussion List \<hdf-forum@lists.hdfgroup.org\>  
> Subject: Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi Dana and Prentice,  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks for your help.  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;My problem has been solved perfectly. I use the h5c++ compiler to compile the code, and it works. Wonderful!  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Maybe I linked to the error libraries when I linked mannually.  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks again for your help!  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu
> 
> At 2016-07-29 23:40:52, "Dana Robinson" \<derobins@hdfgroup.org\<mailto:derobins@hdfgroup.org\>\> wrote:
> 
> Hi all,
> 
> The source patch removes all references to flock() so this error should not be occurring, regardless of the permissions. If you are still seeing errors, I suspect that you are linking to a different HDF5 library than the one you patched.
> 
> One thing I would try is, instead of using g++ directly, try using the h5c++ compiler wrapper that should be located in the bin directory of the HDF5 install. That will ensure that you are linking to the correct libraries. When you use h5c++, you won't need to include the -I, -L, and -l flags for HDF5 paths and libraries since h5c++ sets that up for you.
> 
> Dana Robinson  
> Software Engineer  
> The HDF Group
> 
> From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org\<mailto:hdf-forum-bounces@lists.hdfgroup.org\>] On Behalf Of Prentice Bisbal  
> Sent: Friday, July 29, 2016 9:43 AM  
> To: hdf-forum@lists.hdfgroup.org\<mailto:hdf-forum@lists.hdfgroup.org\>  
> Subject: Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> I know this may sound like a stupid question, but I have to ask, because I've learned never to assume things: Are you sure you have write access where you're trying to create this file? Have you confirmed this by going the directory where you are trying to create the directory and doing 'touch test', which will create an empty file named "test"?
> 
> Prentice  
> On 07/28/2016 11:24 PM, 于海军 wrote:  
> Hi Dana and Prentice,
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks for your response.  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I've tried with your method to repatch and recompile hdf5-1.10.0-patch1 source code. And I also checked the three files H5private.h, H5system.c and swmr.c. They were actually changed after run patch. Unfortunately when run my code the error still exist. And error information is the same as before.
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile the hdf5 code as follows:  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;patch -p0 \< file-lock-removal.diff  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./configure --prefix=/home/duc001/3dtools/hdf5-1.10.0 --enable-cxx --with-zlib=/home/duc001/zlib-1.2.8/  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make clean  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make install  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;make check-install
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;echo $PATH as follows:  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;/home/duc001/3dtools/hdf5-1.10.0/bin
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;I compile my code as follows:  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;g++ -c test.cpp -I /home/duc001/3dtools/hdf5-1.10.0/include -L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp //no error  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;g++ -o testRun test.o -I /home/duc001/3dtools/hdf5-1.10.0/include -L /home/duc001/3dtools/hdf5-1.10.0/lib -lhdf5 -lhdf5\_cpp //no error  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;./testRun // with error
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Are there any questions in the above operation?
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Thanks again for your effort!
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;Haijun Yu
> 
> At 2016-07-27 21:46:43, "Prentice Bisbal" \<pbisbal@pppl.gov\>\<mailto:pbisbal@pppl.gov\> wrote:  
> Haijun,
> 
> Did do a 'make clean' or (even better) 'make distclean' before recompiling your code? Make is supposed to determine that the source files are newer than the object files and build all the object files that depend on those source files and so on, but it's possible that the dependency tree broke down somewhere.
> 
> I would recommend deleting your entire HDF5 source directory, unzipping HDF again, applying the patch, and the going through the configure and make process again.
> 
> Prentice  
> On 07/27/2016 08:24 AM, Dana Robinson wrote:  
> Hi Haijun,
> 
> If you are still getting a flock error, I'd be suspicious that you aren't linking to the patched HDF5 library. The source patch completely removes flock so you shouldn't be seeing file locking errors.
> 
> Dana Robinson  
> Software Engineer  
> The HDF Group
> 
> From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org] On Behalf Of ???  
> Sent: Wednesday, July 27, 2016 2:16 AM  
> To: HDF Users Discussion List \<hdf-forum@lists.hdfgroup.org\>\<mailto:hdf-forum@lists.hdfgroup.org\>  
> Subject: Re: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi Dana,  
> Thanks for your response.
> 
> I've tried with your method to patch and compile hdf5-1.10.0-patch1 source code. Patch and compile have no error. Unfortunately when run my code the error still exist. And error information is the same as before.
> 
> What should I do? Please help me.
> 
> Thank you again for your effort!
> 
> Haijun Yu
> 
> At 2016-07-26 13:47:39, "Dana Robinson" \<derobins@hdfgroup.org\<mailto:derobins@hdfgroup.org\>\> wrote:
> 
> Hi,
> 
> It looks like flock() is not implemented on your filesystem, which is causing the create call to fail. flock() file locking is used by the HDF5 1.10.0 to help enforce single-writer/multiple-readers (SWMR) semantics, but is not necessary for correct operation of the library. A fix for this problem should be available in HDF5 1.10.1, but in the meantime you can apply a source patch found here:
> 
> [https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf](https://www.hdfgroup.org/HDF5/release/obtainsrc5110.html#conf)
> 
> under "Patch to Disable File Locking" at the bottom of the page.
> 
> Cheers,
> 
> Dana Robinson  
> Software Engineer  
> The HDF Group
> 
> From: Hdf-forum [mailto:hdf-forum-bounces@lists.hdfgroup.org\<mailto:hdf-forum-bounces@lists.hdfgroup.org\>] On Behalf Of ???  
> Sent: Tuesday, July 26, 2016 1:35 AM  
> To: hdf-forum@lists.hdfgroup.org\<mailto:hdf-forum@lists.hdfgroup.org\>  
> Subject: [Hdf-forum] Error detected in HDF5 (1.10.0) thread 0: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src
> 
> Hi,  
> I have met an obscure failure, and not find a good solution for two days. Could you help me? Thanks!  
> (Using: hdf5-1.10.0-patch1-linux-centos6-x86\_64-gcc447-shared.tar.gz)  
> (Environment: redhat6.4-Intel-X64-g++4.4.7)
> 
> The error information:  
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:  
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 491 in H5Fcreate(): unable to create file  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file  
> &nbsp;&nbsp;#001: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5Fint.c line 1168 in H5F\_open(): unable to lock the file or initialize file structure  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Unable to open file  
> &nbsp;&nbsp;#002: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FD.c line 1821 in H5FD\_lock(): driver lock request failed  
> &nbsp;&nbsp;&nbsp;&nbsp;major: Virtual File Layer  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Can't update object  
> &nbsp;&nbsp;#003: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5FDsec2.c line 939 in H5FD\_sec2\_lock(): unable to flock file, errno = 38, error message = 'Function not implemented'  
> &nbsp;&nbsp;&nbsp;&nbsp;major: File accessibilty  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Bad file ID accessed  
> HDF5-DIAG: Error detected in HDF5 (1.10.0) thread 0:  
> &nbsp;&nbsp;#000: /home/hdftest/snapshots-hdf5\_1\_10\_alpha/current/src/H5F.c line 749 in H5Fclose(): not a file ID  
> &nbsp;&nbsp;&nbsp;&nbsp;major: Invalid arguments to routine  
> &nbsp;&nbsp;&nbsp;&nbsp;minor: Inappropriate type
> 
> compile no error: g++ -c packageHdf5.cpp -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp  
> link no error: g++ -o packageHdf5Run packageHdf5.o -I ../latest/include -L ../latest/lib -lhdf5 -lhdf5\_cpp  
> run error: ./packageHdf5Run (error information as above)
> 
> My code:
> 
> #include \<stdio.h\>  
> #include \<iostream\>  
> #include \<string\>
> 
> #include "H5Cpp.h"  
> #include \<H5File.h\>  
> #include "hdf5.h"
> 
> #ifndef H5\_NO\_NAMESPACE  
> using namespace H5;  
> #endif
> 
> using namespace std;
> 
> int main(int argc, char\* argv[])  
> {  
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;hid\_t file\_id = H5Fcreate("/home/tg2hpps/tg2hpps\_main/src/packageHdf5/dsetddd.h5", H5F\_ACC\_TRUNC, H5P\_DEFAULT, H5P\_DEFAULT);
> 
> &nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;H5Fclose(file\_id);  
> }
> 
> Thanks!
> 
> \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_
> 
> Hdf-forum is for HDF software users discussion.
> 
> Hdf-forum@lists.hdfgroup.org\<mailto:Hdf-forum@lists.hdfgroup.org\>
> 
> [http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)
> 
> Twitter: [https://twitter.com/hdf5](https://twitter.com/hdf5)
> 
> \_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_\_
> 
> Hdf-forum is for HDF software users discussion.
> 
> Hdf-forum@lists.hdfgroup.org\<mailto:Hdf-forum@lists.hdfgroup.org\>
> 
> [http://lists.hdfgroup.org/mailman/listinfo/hdf-forum\_lists.hdfgroup.org](http://lists.hdfgroup.org/mailman/listinfo/hdf-forum_lists.hdfgroup.org)
> 
> Twitter: [https://twitter.com/hdf5](https://twitter.com/hdf5)
