xfs
[Top] [All Lists]

RE: Hard Links

To: "'Steve Lord '" <lord@xxxxxxx>, "Quang Nguyen (Ngo)" <quang.nguyen@xxxxxxxxxxxx>
Subject: RE: Hard Links
From: "Quang Nguyen (Ngo)" <quang.nguyen@xxxxxxxxxxxx>
Date: Tue, 11 Dec 2001 12:23:59 -0800
Cc: "''linux-xfs@xxxxxxxxxxx' '" <linux-xfs@xxxxxxxxxxx>
Sender: owner-linux-xfs@xxxxxxxxxxx
If I remember correctly, NextStep did provide hardlinks to directories.  I
wonder if OSX's native FS does support them.  Anyway, I'm writing a backup
utility, so I thought I might need to pay attention to them in case, they're
there.

Thanks,
Quang


-----Original Message-----
From: Steve Lord
To: Quang Nguyen (Ngo)
Cc: 'linux-xfs@xxxxxxxxxxx'
Sent: 12/11/01 12:12 PM
Subject: Re: Hard Links

On Tue, 2001-12-11 at 14:08, Quang Nguyen (Ngo) wrote:
> Is XFS going to support hard links to directories?
> 
> # ln -d dir dirLink
> 
> returns
> 
> ln: creating hard link `../dirLink' to `dir': Operation not permitted

Generally you do not want to do this, you can create loops and all
sorts of nasty things with hardlinks to directories. The man page for
link even explicitly lists an error for this:

       EPERM  oldpath is a directory.

You also have to ask yourself, if there are two hardlinks to a
directory, which directory is its parent.

You can create soft links to directories though.

Steve


_____________________________________________________________________
This message has been checked for all known viruses by the 
MessageLabs Virus Scanning Service. For further information visit
http://www.messagelabs.com/stats.asp


[[HTML alternate version deleted]]


<Prev in Thread] Current Thread [Next in Thread>