Operating System - HP-UX
1752755 Members
5139 Online
108789 Solutions
New Discussion юеВ

unable to remove directory

 
SOLVED
Go to solution
dictum9
Super Advisor

unable to remove directory

On 11.23.
How can I remove this directory?


sapsbox:/home/oracle.b# l
total 32
drwxr-xr-x 3 oracle dba 8192 Jan 15 10:35 .
dr-xr-xr-x 1 root root 1 Jan 15 10:44 NAS_archoverflow
drwxr-xr-x 19 root root 8192 Jan 15 10:55 ..
sapsbox:/home/oracle.b# rm -rf NAS*
rm: cannot read NAS_archoverflow: Permission denied sapsbox:/home/oracle.b# ll NAS* NAS_archoverflow unreadable total 0
sapsbox:/home/oracle.b#
5 REPLIES 5
F Verschuren
Esteemed Contributor
Solution

Re: unable to remove directory

I think you need to be root to rm and seeing the error maybe you do not have enauf permisions.
Steven E. Protter
Exalted Contributor

Re: unable to remove directory

Shalom,

fuser -cuk /directory_name

That will kill all open processes on the folder then you should be able to delete.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
F Verschuren
Esteemed Contributor

Re: unable to remove directory


can you post a
bdf /home/oracle/NAS_archoverflow
(to check if it is not a nfs share.)


whoami

If it is a share and you have root privilages, please check if root may write to the share
Michael Mike Reaser
Valued Contributor

Re: unable to remove directory

Hmmm. "rm -rf" first wants to try to remove all files within the directory, which you can't do because no one (other than root) can write to that directory. Yet, based on your prompt, you appear to be root???

If you're sure that the directory is already empty, you could just do a "rmdir NAS*", presuming you have the proper permissions on the parent directory. Based on what you're showing for "..", it would appear that **ONLY** a root user can manipulate this /home/oracle.b directory and its contents.

How are you logged in when you try this - as what username?
There's no place like 127.0.0.1

HP-Server-Literate since 1979
dictum9
Super Advisor

Re: unable to remove directory

the system was confused as the directory was an auto mount filesystem but the VG was not created.

I changed /etc/auto*master, rebooted, then deleted it...