LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Stale NFS file handle (https://www.linuxquestions.org/questions/linux-newbie-8/stale-nfs-file-handle-783830/)

nodopro 01-21-2010 02:03 PM

Stale NFS file handle
 
How do I delete a file if it happens like this.

-????????? ? ? ? ? ? temp.cgi

Thanks,
nodopro

AlucardZero 01-21-2010 02:57 PM

find . -name "*temp.cgi*" -exec rm '{}' \;

?

Also, what does your title have to do with your question?

nodopro 01-21-2010 04:13 PM

How to delete Stale NFS file handle file?
 
Quote:

Originally Posted by AlucardZero (Post 3835534)
find . -name "*temp.cgi*" -exec rm '{}' \;

?

Also, what does your title have to do with your question?

I have tried that but cannot remove the file. The error message below.

[root@localhost]# find . -name "*temp.cgi*" -exec rm '{}' \;
rm: cannot remove `./temp.cgi': Stale NFS file handle


I am sorry about the title. I don't know what to name it so I just put the error message. Should it be "How to delete Stale NFS file handle file"?

AlucardZero 01-21-2010 04:42 PM

No, your body should have related to your topic. You didn't previously tell us that you got "Stale NFS file handle" when trying to remove the file, so it seemed to be a non sequitur.

Anyway, the easiest way is probably to reboot.

nodopro 01-22-2010 11:07 AM

reboot the machine and the problem is still there.

Code:

[root@localhost ~]# ls -l temp.cgi
ls: cannot access temp.cgi: Stale NFS file handle

[root@localhost ~]# rm -rf temp.cgi
rm: cannot remove `temp.cgi': Stale NFS file handle


AlucardZero 01-22-2010 11:17 AM

Ok, please post the output of
df -h
mount
ls -ld /tmp
grep tmp /etc/fstab

and any recent errors in /var/log/syslog or /var/log/messages. Please also tell us what Linux version you are running.


All times are GMT -5. The time now is 09:45 PM.