Share your knowledge at the LQ Wiki.
Go Back > Forums > Linux Forums > Linux - Server
User Name
Linux - Server This forum is for the discussion of Linux Software used in a server related context.


  Search this Thread
Old 07-18-2008, 10:05 AM   #1
Registered: Feb 2005
Posts: 37

Rep: Reputation: 15
~ showing up in front of 2 files but I cannot delete them


I am running Fedora 8. We have 2 files on the server that one can access. It looks like someone is still in the file, but this is not the case. The files are E05993.slddrw and E05993.sldprt, each file has a file next to it named ~$E05593.slddrw and ~$E05593.sldprt respectively. I believe if I can delete these files people will be able to access the originals again.. but when I use the rm command in terminal to delete the files with ~$ in front of them I get a warning that there are no such files even though I can see them when I run an ls -l command. Please help!
Old 07-18-2008, 10:14 AM   #2
Senior Member
Registered: Mar 2004
Location: Cary, NC, USA
Distribution: Fedora, Kubuntu, RedHat, CentOS, SuSe
Posts: 1,288

Rep: Reputation: 99
The '~' and '$' are special characters in the shell. You will need to escape them or do this in a different way. Try the following:

rm \~\$E05993.slddrw
If that works, do the same for the other file. If it does not, do the following:

mkdir temp1234
mv *E05993.slddrw temp1234
mv *E05993.sldprt temp1234
mv temp1234/E05993.slddrw .
mv temp1234/E05993.sldprt .
Make sure the files you want to keep are still in the original directory and the files you want to delete are in temp1234. If they are, run:

rm -rf temp1234


Last edited by forrestt; 07-18-2008 at 10:15 AM.
Old 07-18-2008, 10:33 AM   #3
Registered: Feb 2005
Posts: 37

Original Poster
Rep: Reputation: 15
I tried escaping the files like you suggested and that didn't work. However your second selection did work. I moved the files as you described and then deleted the folder. Worked like a charm! Thanks for your help.
Old 07-18-2008, 10:47 AM   #4
LQ Newbie
Registered: Jul 2008
Posts: 5

Rep: Reputation: 0
You could also use interactive mode to select which files to actually delete:
rm -i *E05993*


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Script help - delete files older than 45 days but exclude the system files jojothedogboy Linux - Software 3 06-13-2008 03:43 PM
showing the files in htdocs GeorgeP Linux - Software 6 05-30-2006 12:38 AM
Files not showing up on desktop z9_87 Mandriva 5 05-31-2005 08:37 PM
How to delete the destination files while the source files deleted in cp -u ? myunicom Linux - General 4 09-26-2003 01:13 PM
Files not showing up in vsftpd cjlee Linux - Networking 0 08-26-2003 05:15 PM > Forums > Linux Forums > Linux - Server

All times are GMT -5. The time now is 08:21 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration