/etc/link problem via /etc/mvdir
~XT4103000~Marc Mengel~C25~G25~6184~
mmengel at cuuxb.ATT.COM
Tue May 24 00:07:17 AEST 1988
In article <532 at etn-rad.UUCP> markus at etn-rad.UUCP (Markus Richardson) writes:
>I did something dangerous/stupid but only realized it after the fact.
>...
>I entered '/etc/mvdir * dir9'
>...
>Needless to say, I could not locate the directories and associated files
>until I did a /etc/fsck. They all turned out to be UNREFerenced. What the
>heck happened? If it matters, I am running SysV.2 on a Plexus.
I assume you moved dir9 into itself, i.e.
link("dir9","dir9/dir9");
link("dir9/dir9/..", "dir9");
unlink("dir9");
Thereby generating a circular reference (hence the ref count on dir9
was still 1 after the whole proceeding, so no warnings about removing
the last link to a non-empyt directory).
And some people wonder why linking/unlinking directories requires
root permissions under Sys V...
--
Marc Mengel
attmail!mmengel
...!{moss|lll-crg|mtune|ihnp4}!cuuxb!mmengel
More information about the Comp.bugs.sys5
mailing list