Re: cannot delete directory - why?

Wakko Warner (wakko@animx.eu.org)
Tue, 5 Oct 1999 12:47:21 -0400


> > |> Hello,
> > |>
> > |> I can't seem to delete the following directory:
> > |>
> > |> snoopy# pwd
> > |> /homes/diskless/slink/root/dev
> > |> snoopy# ls -ld pts
> > |> drwxr-xr-x 2 root root 0 Oct 2 15:20 pts
> >
> > I think you have a corrupted filesystem. A directory inode with a zero
> > size but nonzero link count does not look sane.
>
> No, it's normal. /dev/pts is the root of the pseudo-terminal
> filesystem. It's not a "real" filesystem so the size shows as 0.
> Since it's a mounted filesystem, you can't remove the directory.
> Unmounting it (when it isn't busy) will get rid of it but I doubt
> that's really what's wanted (I haven't read the original query,
> though).

Has anyone thought to check to see where this 'pts' lies? I've found out
that one of the dev_t elements of stat show the device these were mounted
from (I wrote a program to show this info as well, there is also on in
debian that does something similar). Obviously, if the major/minor of pts
is != to the major/minor of . (where pts is), then it's mounted.

Anyone disagree?

-- 
 Lab tests show that use of micro$oft causes cancer in lab animals

- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.rutgers.edu Please read the FAQ at http://www.tux.org/lkml/