Re: rm question
arodriguez@worldnet.att.net (Antonio Rodriguez) wrote:
>I want to delete a directory with a whole bunch of embeded
>subdirectories, I did
>rm -d kdeo
> and I get Operation not permitted.
>Now, I am doing it as root, so, the permission should not be an issue.
>Whats the problem? Is there a better way of removing a sequence of such
>embedded directories?
Firstly, the kernel and the C library can return EPERM whenever they
like, whether you're root or not. Being root doesn't let you override
the kernel, at least not without installing a new one or bypassing it
entirely by accessing the disk devices directly.
The -d argument to rm can and probably will damage your filesystem.
Don't use it. Use -r instead: so, 'rm -r kdeo', or, if you're *really*
sure, 'rm -rf kdeo' to tell it not to ask you for every file.
--
Colin Watson [cjw44@cam.ac.uk]
Reply to:
- References:
- rm question
- From: Antonio Rodriguez <arodriguez@worldnet.att.net>