Re: ODS5 and hardlinks



John E. Malmberg wrote:

....

A hard link on UNIX and an alias created by SET FILE/ENTER are close to the same. There are some differences that are important to some programs and quota management.

My increasingly-feeble powers of recollection just offered up one such. IIRC ODS-2 maintains up-pointers in each file header to each file's/directory's parent - but of course it has room for only one such (which I'd suspect is updated when the file/directory is renamed to another parent). With hard links enabled, presumably either that entry represents the initial parent (or a new parent renamed to from the initial parent) just as it does in non-hard-link systems where additional ENTER operations have been performed, and becomes irrelevant if the file is deleted from that parent, or is simply suppressed to avoid giving any parent unequal status.

I can't off-hand recall why the up-pointer was defined in the first place, save perhaps that it was possible without undue effort and might help reconstruct a directory hierarchy which had become damaged. The file name field in the file header (which IIRC is updated on RENAME operations to the original parent) is in the same boat when it comes to having multiple parents (hard-link-enabled or not), but I think may always have been defined as being merely informational in nature rather than being used by the system in any manner - save perhaps that the combination of the two fields could be used to determine whether a RENAME was being applied to the original parent entry (since there could have been additional entries even in that one parent directory) and hence whether the name should be updated.

- bill
.



Relevant Pages

  • Re: 2.6.4-rc1 oops on HPFS filesystem file rename
    ... and cross-directory rename(), of all things. ... update directory entry in the parent, so it gets the parent inode and locks ... then grab rwsem on parentfor writing. ... Order among semaphores and among rwsems, ...
    (Linux-Kernel)
  • Re: [PATCH 12/25] sysfs: Introduce sysfs_rename_mutex
    ... If the parent directory of the object we are renaming ... changes while the rename is being performed nasty things could ... happen when we go to release our locks. ... Very few code paths actually seem to care. ...
    (Linux-Kernel)
  • Re: Rename Parent worksheet.name?
    ... The Parent of a Worksheet is a Workbook, and a Workbook cannot be renamed. ... but I can not seem to rename the parent name. ...
    (microsoft.public.excel.programming)
  • Re: How to create a duplicate (not sub) class.
    ... then classloc would point to the orignial.vcx and would ... Let 's say you have a original.vcx with classes parent and child, ... If you now rename a ...
    (microsoft.public.fox.programmer.exchange)
  • Re: Exception OU in Delegated Environment
    ... You have delete child permission on the parent ... remove the delete permission from the parent. ... Note also that a rename is effectively a move. ... The only way round this that springs to mind is to use a custom app for ...
    (microsoft.public.windows.server.active_directory)