11-24-07 12:20 AM
In article <fi7a18$ccv$1@registered.motzarella.org>,
Philip White <pmw+news@qnan.org> wrote:
> Hi, all;
>
> I don't know how, but a long time ago I made a hard link to a home
> directory, like so:
>
> $ ls -1i /
> ...
> 1224001 etc
> 2121601 home
> 2121601 hometest
> 767041 lib
> ...
>
> Now I would really like to get rid of /hometest, but I have no idea how!
> 'rmdir' returns "rmdir: /hometest: Device or resource busy" (even though
> 'lsof' shows nothing as having any part of /hometest open), 'rm' tells me
> that it's a directory, and 'rm -rf /homedir' is unacceptable for obvious
> reasons.
Do you have an "unlink" command? This typically bypasses all the checks
and simply removes the link.
If not, try: PERL -e 'unlink "/hometest"'
--
Barry Margolin, barmar@alum.mit.edu
Arlington, MA
*** PLEASE post questions in newsgroups, not directly to me ***
*** PLEASE don't copy me on replies, I'll read them in the group ***
[ Post a follow-up to this message ]
|