From ilug-admin@linux.ie  Mon Jul 22 19:50:01 2002
Return-Path: <ilug-admin@linux.ie>
Delivered-To: yyyy@localhost.netnoteinc.com
Received: from localhost (localhost [127.0.0.1])
	by phobos.labs.netnoteinc.com (Postfix) with ESMTP id CB4B4440C8
	for <jm@localhost>; Mon, 22 Jul 2002 14:49:59 -0400 (EDT)
Received: from dogma.slashnull.org [212.17.35.15]
	by localhost with IMAP (fetchmail-5.9.0)
	for jm@localhost (single-drop); Mon, 22 Jul 2002 19:49:59 +0100 (IST)
Received: from webnote.net (mail.webnote.net [193.120.211.219]) by
    dogma.slashnull.org (8.11.6/8.11.6) with ESMTP id g6MHQY403542 for
    <jm-ilug@jmason.org>; Mon, 22 Jul 2002 18:26:34 +0100
Received: from lugh.tuatha.org (root@lugh.tuatha.org [194.125.145.45]) by
    webnote.net (8.9.3/8.9.3) with ESMTP id JAA22837 for <jm-ilug@jmason.org>;
    Sat, 20 Jul 2002 09:56:52 +0100
Received: from lugh (root@localhost [127.0.0.1]) by lugh.tuatha.org
    (8.9.3/8.9.3) with ESMTP id JAA25881; Sat, 20 Jul 2002 09:46:48 +0100
Received: from mail.magicgoeshere.com (nw152-60.indigo.ie [194.125.152.60]
    (may be forged)) by lugh.tuatha.org (8.9.3/8.9.3) with ESMTP id JAA25841
    for <ilug@linux.ie>; Sat, 20 Jul 2002 09:46:41 +0100
X-Authentication-Warning: lugh.tuatha.org: Host nw152-60.indigo.ie
    [194.125.152.60] (may be forged) claimed to be mail.magicgoeshere.com
Received: from bagend.magicgoeshere.com (ts15-163.dublin.indigo.ie
    [194.125.176.163]) by mail.magicgoeshere.com (Postfix) with ESMTP id
    90B81F8FE for <ilug@linux.ie>; Sat, 20 Jul 2002 09:31:33 +0100 (IST)
Received: by bagend.magicgoeshere.com (Postfix, from userid 501) id
    164523C19C; Fri, 19 Jul 2002 23:17:36 +0100 (IST)
Date: Fri, 19 Jul 2002 23:17:35 +0100
From: Niall O Broin <niall@linux.ie>
To: ilug@linux.ie
Subject: Re: [ILUG] How to copy some files
Message-Id: <20020719221735.GB3854@bagend.makalumedia.com>
Reply-To: ilug@linux.ie
Mail-Followup-To: Niall O Broin <niall@linux.ie>, ilug@linux.ie
References: <1027108120.3d386d180910a@webmail.gameshrine.com>
MIME-Version: 1.0
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
In-Reply-To: <1027108120.3d386d180910a@webmail.gameshrine.com>
User-Agent: Mutt/1.3.27i
Sender: ilug-admin@linux.ie
Errors-To: ilug-admin@linux.ie
X-Mailman-Version: 1.1
Precedence: bulk
List-Id: Irish Linux Users' Group <ilug.linux.ie>
X-Beenthere: ilug@linux.ie

On Fri, Jul 19, 2002 at 08:48:40PM +0100, Ronan Cunniffe wrote:
> Quoting Ronan Waide <waider@waider.ie>:
> 
> > Sure, but soft links would do the same. To be honest, I'm trying to
> > think of a useful use of hard links right now, and I'm a little
> > stumped. There's gotta be some benefit that I'm missing that's
> > immediately obvious to everyone.
> 
> Using Niall's example - single set of files but >1 namespace, and suppose that
> you want to delete some items from the set according to rules applied to the
> namespaces.  With soft links you need an *extra* namespace the others refer to,
> and after filtering the namespaces, you have to do a manual reference count to
> decide what goes and what stays.  With hard links, you just unlink and deletion
> is automatic.

Couldn't have put it better myself, but that's not going to stop me trying :-) 
The above situation occurs precisely because of the major functional difference
between symbolic links (AKA soft links, or symlinks to their friends) and hard
links. Two hard links to the same file are exactly equivalent - one is no more
the files "real" directory entry than is the other. OTOH a symlink is a special
thing which is a link to a real file, and when the file linked to is erased, you
end up with a broken symbolic link - you can't have a broken hard link (except
of course in the case of a banjaxed filesystem).


Niall

-- 
Irish Linux Users' Group: ilug@linux.ie
http://www.linux.ie/mailman/listinfo/ilug for (un)subscription information.
List maintainer: listmaster@linux.ie


