fhgfs and hardlinks

540 views
Skip to first unread message

Bernd Wollny

unread,
Dec 1, 2014, 11:30:33 AM12/1/14
to fhgfs...@googlegroups.com
Hello,

I have thought that fhgfs supports hard links.

Now I tried this

ln file_a file_b  # OK
ln file_a dir/file_b #  Operation not permitted

do some one know why the first link is OK and the second one fails

Best regards,
  Bernd






trey...@tamu.edu

unread,
Dec 2, 2014, 10:10:16 AM12/2/14
to fhgfs...@googlegroups.com
I believe FhGFS only supports hard links within the same directory.

- Trey

Bernd Wollny

unread,
Dec 8, 2014, 4:13:02 AM12/8/14
to fhgfs...@googlegroups.com
Is there any reason why FhGFS only supports "local" hardlinks?

Steffen Grunewald

unread,
May 13, 2015, 3:49:56 AM5/13/15
to fhgfs...@googlegroups.com
That's something I'd also like to know - we've got a use case for which cross-directory hard-links are essential, and BeeGFS would effectively be excluded if it still couldn't provide this feature.
Can we have an update?

Thanks, S

Christian Mohrbacher

unread,
May 13, 2015, 6:52:30 AM5/13/15
to fhgfs...@googlegroups.com
Hi,
currently, BeeGFS/FhGFS only supports hard links within the same directory. But for most use cases it's sufficient to actually create a symlink instead of a hard link, so maybe the client option "sysCreateHardlinksAsSymlinks" might be useful for you?

Regards,
Christian
--
You received this message because you are subscribed to the Google Groups "beegfs-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email to fhgfs-user+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Steffen Grunewald

unread,
May 13, 2015, 8:49:46 AM5/13/15
to fhgfs...@googlegroups.com
On Wed, May 13, 2015 at 12:53:20PM +0200, Christian Mohrbacher wrote:
> Hi,
> currently, BeeGFS/FhGFS only supports hard links within the same
> directory. But for most use cases it's sufficient to actually create
> a symlink instead of a hard link, so maybe the client option
> "sysCreateHardlinksAsSymlinks" might be useful for you?
>
> Regards,
> Christian

While they in a few cases may be a workaround, symlinks have completely
different semantics. The absence of cross-directory hardlinks results
in, for example, rsnapshot not working again - instead of having
multiple handles to the same file, one would end up with a chain of
symlinks eventually pointing into the void (when the first backup
generation gets removed due to its age).
We're not talking about scientific applications and locking yet,
but that'd be next. Exclusion criteria, y'know.

I don't know anything about BeeGFS's internals, but I'm wondering
what's the difference between same-directory and cross-directory
hardlinking, in terms of the FS. What would happen if I create a
hardlink in the same directory, and afterwards move the result to
another place? Looks like serious Posix breakage to me :(

Am I wrong? Is there still hope?

Thanks, Steffen
> ><mailto:fhgfs-user+...@googlegroups.com>.
> >For more options, visit https://groups.google.com/d/optout.
>
> --
> You received this message because you are subscribed to the Google Groups "beegfs-user" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to fhgfs-user+...@googlegroups.com.
> For more options, visit https://groups.google.com/d/optout.

--
Steffen Grunewald * Cluster Admin * steffen.grunewald(*)aei.mpg.de
MPI f. Gravitationsphysik (AEI) * Am Mühlenberg 1, D-14476 Potsdam
http://www.aei.mpg.de/ * ------- * +49-331-567-{fon:7274,fax:7298}

Sven Breuner

unread,
May 15, 2015, 7:12:30 AM5/15/15
to fhgfs...@googlegroups.com, Steffen....@aei.mpg.de
Hi Steffen,

Steffen Grunewald wrote on 05/13/2015 02:49 PM:
> On Wed, May 13, 2015 at 12:53:20PM +0200, Christian Mohrbacher wrote:
>> currently, BeeGFS/FhGFS only supports hard links within the same
>> directory. But for most use cases it's sufficient to actually create
>> a symlink instead of a hard link, so maybe the client option
>> "sysCreateHardlinksAsSymlinks" might be useful for you?
>
> While they in a few cases may be a workaround, symlinks have completely
> different semantics.

sure, that's why this is not done by default, but only when you enable
it explicitly in the config.

> The absence of cross-directory hardlinks results
> in, for example, rsnapshot not working

...or in creating actual copies instead of hardlinks. But the solution
here could of course be to simply put the snapshots on some cheap, slow,
big other filer that supports cross-dir hardlinks instead of putting
them on your performance-optimized BeeGFS.

> I don't know anything about BeeGFS's internals, but I'm wondering
> what's the difference between same-directory and cross-directory
> hardlinking, in terms of the FS.

For performance reasons, BeeGFS avoids creation of separate inodes for
files and instead inlines the file inode information into the dentry.
Modifying the code to be compatible with cross-dir hardlinks is of
course generally possible, but not trivial due to this optimization.

> What would happen if I create a
> hardlink in the same directory, and afterwards move the result to
> another place?

That move operation will be refused with an error code. So it's not like
BeeGFS would silently turn hardlinks into symlinks in this case, if
that's what you meant.

> Posix breakage

Your favorite web search engine will confirm that the whole operating
system is not "fully posix compliant", but "mostly posix compliant".

> Is there still hope?

Sure. See this simply as a feature that we haven't added yet, because
(even though it's requested every now and then) there are other things
that were/are more important to our customers.

Best regards,
Sven Breuner
Fraunhofer

Steffen Grunewald

unread,
May 18, 2015, 5:36:09 AM5/18/15
to fhgfs...@googlegroups.com
Thanks Sven for this explanation - I'll pass it on to the
users which may be affected by such a limitation.

- S

amel...@gmail.com

unread,
Nov 5, 2015, 9:33:21 AM11/5/15
to beegfs-user
I also need the hard link feature to work across different directories, and I'm wondering if the feature has been added in the meantime, or if the feature has been marked on the roadmap (?)

A.

Zeeshan Ali Shah

unread,
Sep 18, 2018, 4:03:08 PM9/18/18
to beegfs-user
is there any update on this ? 
Reply all
Reply to author
Forward
0 new messages