rm: Unable to remove directory xxxx/xxxx: File exists


 
Thread Tools Search this Thread
Top Forums UNIX for Dummies Questions & Answers rm: Unable to remove directory xxxx/xxxx: File exists
# 1  
Old 11-06-2005
rm: Unable to remove directory xxxx/xxxx: File exists

Hi Everyone,

I am having problem to delete an "empty" folder ( messages attached ).
It displays "total 12" when i typed "ls -lart" on the fnxroot44 folder, but i can't view any file.

Is there any way to view those unseen files ? I don't know why option "a" is not working this time.

Would appreciate if somebody could give advice on this ?
Thanks in advance !

===================-
kirin{root}162: rm -rf test
rm: Unable to remove directory test/fnxroot44: File exists
rm: Unable to remove directory test: File exists

kirin{root}164: cd test
/export/d12/temp/test
kirin{root}165: ls -lart
total 14
2 drwxrwxrwx 25 root other 1024 Jul 7 17:28 fnxroot44/
10 drwxrwxrwx 3 root 13000 4608 Jul 26 16:40 ./
2 drwxrwxr-x 5 user07 other 512 Nov 7 11:11 ../

kirin{root}170: cd ..
/export/d12/temp/test
kirin{root}172: rmdir fnxroot44
rmdir: directory "fnxroot44": Directory not empty

kirin{root}167: cd fnxroot44/
/export/d12/temp/test/fnxroot44
kirin{root}168: ls -lart
total 12
2 drwxrwxrwx 25 root other 1024 Jul 7 17:28 ./
10 drwxrwxrwx 3 root 13000 4608 Jul 26 16:40 ../
===================-

DeeJay
# 2  
Old 11-07-2005
What does "ls -f" give you? What os? What filesystem type? What mount options were used? What shell are you using? Are you root?

Your ls program is behaving wrong. It must be aliased or functioned. Or perhaps it is part of a rootkit and you have been hacked. Look at the output:
kirin{root}168: ls -lart
total 12
2 drwxrwxrwx 25 root other 1024 Jul 7 17:28 ./
10 drwxrwxrwx 3 root 13000 4608 Jul 26 16:40 ../

Look at that 2 and that 10. Those are the sizes. But "ls -lart" did not request sizes. Somehow your command was translated to "ls -slart". Who did that? Why? What other translations are occurring? Try using the absolute path of ls. Check your PATH environment variable.
 
Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. UNIX for Beginners Questions & Answers

Check that at least one file exists in the directory.

There are some files with suffix dates like abc_20032019.dat abc_17032019.dat If at least one file exists then perform some operation else exit from execution. Korn shell ---------------------------------- array=($inputdir/abc*.dat) If ] ] then echo " file exits" else echo " file does... (10 Replies)
Discussion started by: Rajesh123
10 Replies

2. UNIX for Dummies Questions & Answers

Grep file and print value only if the following line doesnt contain value xxxx

Hi All, I have some large files which I would like to obtain some data from, I want to grep (or alturnative method) out certain values hut only if the folowing line doesnt contain a certain value. I will explain better below showing an example print of the data. NE : V0001 NE : V0002... (6 Replies)
Discussion started by: mutley2202
6 Replies

3. Shell Programming and Scripting

Printing paragraph between semicolons having XXXX

Hello experts, I have below file: 1 2 3 4 5 6 ; 7 8 9 10 XXXX 1 ; 2 3 (4 Replies)
Discussion started by: manuswami
4 Replies

4. Shell Programming and Scripting

Unable to check if file exists on remote server using expect

Hi, I need to check if a file exists on remote server using expect. #!/bin/bash ip_addr=10.10.10.10 user=root passwd=Help filename=/root/test expect -c " spawn ssh -n -T -o NumberOfPasswordPrompts=3 -o StrictHostKeyChecking=no $user@$ip_addr expect \"*?assword:*\" send --... (6 Replies)
Discussion started by: temp_user
6 Replies

5. Shell Programming and Scripting

How to check if the file exists in directory?

Hi Gurus, I have a requests to find if all the file in the filelist exist in certain directory. example: my filelist abc def ddd cde afg how can I find these 5 files exists at director /home/abc Thanks in advance (7 Replies)
Discussion started by: ken6503
7 Replies

6. Shell Programming and Scripting

How to check if a file exists in a directory?

I want to perform SQL *Loader operation only if a file named "load.txt" exists in a directory "/home/loc/etc". Please help how to check this with a if condition. (8 Replies)
Discussion started by: vel4ever
8 Replies

7. UNIX for Dummies Questions & Answers

Script or SED command for [[Xxxx Xxxx Xxxx]] to [[Xxxx xxx xx]]

Hi, To comply with a new naming convention on a mediawiki site we have to run a SED or other PERL command to change all instances of ] or ] or ] to ] Can someone please explain how to do this... It has to be done on a mysql dump, so if there is a way to do this in mysql even... (2 Replies)
Discussion started by: lawstudent
2 Replies

8. Solaris

sar : insufficient address space to load xxxx device records

Hello, i am using Solaris 10, The sar running in my system might be corrupted, but not sure why as there has been no updates to it ( to the best of my knowledge) and it was working fine until few days back. If i try to get sar reports using sar -o <filename> 60 180 there is no error but the... (2 Replies)
Discussion started by: nimi20
2 Replies

9. UNIX for Dummies Questions & Answers

rm: Unable to remove directory /mnt/users/test/logs/: File exists

rm: Unable to remove directory /mnt/users/test/logs/: File exists ls -latr total 191208 drwxrwxrwx 6 test echo 4096 Jul 3 22:36 .. -rwxrwxrwx 1 test echo 97692804 Jul 3 22:36 .nfsDFA4 drwxrwxr-x 2 test echo 4096 Jul 3 23:00 . M not able to delete... (4 Replies)
Discussion started by: solitare123
4 Replies

10. UNIX for Dummies Questions & Answers

Removing spaces between XML tags<XX XX> -> <XXXX>

hey guys, i have an XML like this: <documents> <document> <Object ID>100114699999</Object ID> <Object Create Date Time>2008-04-07T00:00:00</Object Create Date Time> </document> <documents> I need all my tags within the XML to not include any spaces. i.e. everything between <t a g> in... (8 Replies)
Discussion started by: sharoff
8 Replies
Login or Register to Ask a Question