Re: Re: chroot & mount --bind = security ?
Date: Sun, 11 Apr 2004 16:59:45 +0200 To: firstname.lastname@example.org
On Fri, Apr 09, 2004 at 05:21:44PM -0400, Scott Gifford wrote:
> Most filesystems I've used are intolerant of hardlinks between
> [sgifford@sghome sgifford]$ ln tmp tmp2
> ln: `tmp': hard link not allowed for directory
> The manpage on Linux says you can hardlink directories if you're
> superuser, although I couldn't get the flags to work. On Solaris I've
> created hardlinked directories before, but fsck destroyed them
> whenever it ran, and I eventually used a solution much like the OP's.
> IIRC, the manpage said directory hardlinks weren't recommended to
> "prevent your directory tree from becoming an arbitrary mishmash."
Specifically, hard links can cause cyclical references in your filesystem
(if a subdirectory is hard linked to its parent, say). Since the reclaiming
of disk resources is generally based upon the reference count, this can pose
a problem :-)