[Info-vax] Hard links on VMS ODS5 disks
Chris Townley
news at cct-net.co.uk
Wed Jul 12 13:57:48 EDT 2023
On 12/07/2023 18:00, Johnny Billquist wrote:
> On 2023-07-12 15:34, Chris Townley wrote:
>> I am just about to install V9.2-1 and intrigued about hard links.
>>
>> When I installed E9.2-1 it asked me if I wanted to enable hard links,
>> with a warning to read the docs, but I wasn't much wiser afterwards.
>>
>> I get he impression that it is much cleaner with them enables, but
>> what are the downside risks?
>>
>> I have used soft links on *nix for many years, but only for linking to
>> a directory, which you cannot do with hard links
>>
>> Any thoughts?
>
> I always have a bit of a hard time understanding the topic. One person I
> talked to was of the opinion that ODS "hard links" were not hard links
> because they didn't include reference counting.
>
> But essentially, if we talk about hard links under Unix, it's just
> additional directory entries pointing to the same inode.
> The equivalent of the inode number under Unix is in ODS the file id. And
> you can have multiple directory entries giving the same file id, which
> is exactly the same as the thing in Unix.
>
> The one difference being that in Unix, a file is removed when the link
> count goes to zero. And there is no way for a program to reference a
> file through the inode number itself.
>
> While in ODS, the file id, and file, is more unaware of what directory
> entries might exist that refers to it, and a file can be deleted without
> the directory entry being deleted. And also, programs can open files by
> ID, completely bypassing the directory lookup. Which is also why ODS
> fild ids have a generation number, so that stale file ids don't give you
> some other file you didn't expect.
>
> But I would still already call this hard links. I wonder if "enabling
> hardlinks" in ODS5 is then adding the reference counting, and not
> deleting files until there are no references to them. Or is there
> something else/more hidden in here?
>
> Johnny
>
That is my understanding from recent doc reading.
--
Chris
More information about the Info-vax
mailing list