[Hdf-forum] Following external links - permissions
Allen Sanderson
allen at sci.utah.edu
Mon Jan 4 16:23:30 EST 2010
Thanks Quincy,
Over the holidays I did some checking and I think it is a case of too
many objects opened and not properly closed that is leading to the
failure. The HDF5 calls were part of a larger API which I decided to
scrap because trying to follow it was too difficult and use a simpler
API. The simpler API worked as expected so I was able to make
everything work for writing - unfortunately the API needs to be used
for reading. And has some other issues with the external links. But I
think I know what needs to fixed there.
Cheers,
Allen
On Jan 4, 2010, at 7:40 AM, Quincey Koziol wrote:
> Hi Allen,
>
> On Dec 19, 2009, at 1:33 PM, allen wrote:
>
>> Hi Quincey,
>>
>> I am currently using 1.8.2.
>>
>> One other clue, this only happens when I utilize one particular
>> piece of code (a third party lib). If I skip it then the link is
>> followed fine later (I access it in multiple places). So I think
>> the link and the permissions are okay but how this third party code
>> opens the link initially tends to make it inaccessible later on. So
>> my guess is that this particular piece of code pooches something. I
>> have not started looking at it yet. (Probably will be able to as my
>> hard drive on that machine died Friday night).
>>
>> Some random thoughts if the file was initially opened as RDONLY
>> with that link accessed. If opening the file again as RDWR would
>> that force the access to that link to fail?
>
> Yes, that would cause the second access to fail.
>
>> If there a way to see what groups are currently open?
>
> You can use the H5Fget_obj_count/H5Fget_obj_ids routines to
> investigate this.
>
> Quincey
>
>
>> Cheers,
>>
>> Allen
>>
>>
>> Allen Sanderson
>> SCI Institute
>> University of Utah
>> www.sci.utah.edu
>>
>>
>>
>> On Dec 18, 2009, at 10:22 PM, Quincey Koziol wrote:
>>
>>> Hi Allen,
>>>
>>> On Dec 18, 2009, at 7:07 PM, Allen Sanderson wrote:
>>>
>>>> One followup could this problem be related to perhaps already
>>>> having the one link open ??? and then trying to open it again???
>>>
>>> Hmm, are you using the latest release (1.8.4)?
>>>
>>> Quincey
>>>
>>>>
>>>>
>>>> Cheers,
>>>>
>>>> Allen
>>>>
>>>>
>>>>
>>>>
>>>> On Dec 18, 2009, at 6:02 PM, Allen Sanderson wrote:
>>>>
>>>>> I have a file with two external links that at are both at the
>>>>> top level:
>>>>>
>>>>> HDF5 "DATA.h5" {
>>>>> GROUP "/" {
>>>>> EXTERNAL_LINK "Mesh" {
>>>>> TARGETFILE "Mesh.h5"
>>>>> TARGETPATH "/Mesh"
>>>>> GROUP "/Mesh" {
>>>>> }
>>>>> }
>>>>> EXTERNAL_LINK "Step#0" {
>>>>> TARGETFILE "step_0.h5"
>>>>> TARGETPATH "/Step#0"
>>>>> GROUP "/Step#0" {
>>>>> }
>>>>> }
>>>>> }
>>>>> }
>>>>>
>>>>> When I open the main file, DATA.h5 as RDONLY I am able to
>>>>> traverse both links as one would expect.
>>>>>
>>>>> However, when I open the main file, DATA.h5 as RDWR the group "/
>>>>> Mesh" succeeds but the "Step#0" fails. Both links are created in
>>>>> the exact same manner.
>>>>>
>>>>> if( H5Lcreate_external(MESH_NAME, "/Mesh",
>>>>> file_id, "Mesh",
>>>>> H5P_DEFAULT, H5P_DEFAULT) < 0 ) {
>>>>> }
>>>>>
>>>>> So I am at a loss as to why the access is different. I tried to
>>>>> follow through and understand more on the Property list that is
>>>>> set to teh default. ie this var:
>>>>> hid_t lapl_id IN: Link access property list identifier.
>>>>>
>>>>> but I did not get far. Should I be setting something here????
>>>>>
>>>>>
>>>>> Cheers,
>>>>>
>>>>> Allen
>>>>>
>>>>>
>>>>> Allen Sanderson
>>>>> SCI Institute
>>>>> University of Utah
>>>>> www.sci.utah.edu
>>>>>
>>>>>
>>>>>
>>>>> _______________________________________________
>>>>> Hdf-forum is for HDF software users discussion.
>>>>> Hdf-forum at hdfgroup.org
>>>>> http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org
>>>>
>>>> _______________________________________________
>>>> Hdf-forum is for HDF software users discussion.
>>>> Hdf-forum at hdfgroup.org
>>>> http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org
>>>
>>> _______________________________________________
>>> Hdf-forum is for HDF software users discussion.
>>> Hdf-forum at hdfgroup.org
>>> http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org
>>
>> _______________________________________________
>> Hdf-forum is for HDF software users discussion.
>> Hdf-forum at hdfgroup.org
>> http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org
>
> _______________________________________________
> Hdf-forum is for HDF software users discussion.
> Hdf-forum at hdfgroup.org
> http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.hdfgroup.org/pipermail/hdf-forum_hdfgroup.org/attachments/20100104/83c4a0dd/attachment.html>
More information about the Hdf-forum
mailing list