[TUHS] moving directories in svr2
Noel Chiappa
jnc at mercury.lcs.mit.edu
Thu Dec 30 13:45:12 AEST 2021
> From: Bakul Shah
> My guess is *not* storing a path instead of a ptr to the inode was done
> to save on memory.
More probably speed; those old disks were not fast, and on a PDP-11, disk
caches were so small that converting the path to the current directory to its
in memory inode could take a bunch of disk reads.
> Every inode has a linkcount so detecting when the last conn. is severed
> not a problem.
Depends; if a directory _has_ to be empty before it can be deleted, maybe; but
if not, no. (Consider if /a/b/c/d exists, and /a/b is removed; the tree
underneath it has to be walked and the components deleted. That could take a
while...) In the general case (e.g. without the restriction to a tree), it's
basically the same problem as garbage collection in LISP.
Noel
More information about the TUHS
mailing list