rm is the Linux Posix command to remove and delete files or directories.

learn more… | top users | synonyms

-1
votes
3answers
50 views

Remove all files but one folder with rm

I want to use rm -rf to remove files/folders inside a folder, but skip or ignore a specific folder. It has been suggested as duplicated to another quesiton, but that is not the case. The other ...
1
vote
2answers
489 views

unable to remove file and directory

i'm trying to remove directory from my external hard drive that i mounted to the file system i'm using the rm -r command but i got the the strange error : rm: cannot remove `Lundu nitip/Downloads/...
1
vote
2answers
1k views

Remove all except one file and directory at path

I need to remove all the files in a directory except for one file and one folder. Up to the grep I can output the correct list of items I want to remove but when i add xags, nothing is deleted. this ...
0
votes
2answers
89 views

override environment variables

I would like to override a particular environment variable on a one-shot basis. The system currently has a variable for the "rm" command, forcing verification for each file. In general I am fine ...
3
votes
1answer
44 views

OS X - DEAAD300 File Can't be seen via Terminal or Deleted

OS X - 10.7.5 I have a file DEAAD300 on a users desktop that I can not delete. EDIT - The file can not be opened either. The icon that shows up looks like an Excel file (The user has Office 2011 ...
2
votes
1answer
186 views

Is there any difference in power between sudo rm and sudo rm -f?

Simple question, but I'm not sure I got a complete understanding from man rm. To the best of my knowledge the only difference is that adding the -f will plow through files without prompting and ...
2
votes
1answer
240 views

Can't delete some symbolic links on HFS volume (Mac OS X 10.7.2)

I can't seem to delete a pile of files; what all these files have in common is as follows: They're all symbolic links, or otherwise parenting directories They're all owned by an unmapped user and ...
1
vote
1answer
38 views

unable to remove symbolic links of rsync copy of /bin and /dev

I accidentally made a rsync copy of my root directory, "/" using the -a option, as follows: user@mycomputer:~$ rsync -a / /backup-dir user@mycomputer:~$ ls -l /backup-dir/ total 10102784 drwxrwxrwx 1 ...
1
vote
1answer
516 views

Slow directory removal (rm -rf) on Max OS X

Can anyone help me diagnose why removing a directory would be so slow on my Mac? $ du -hs mydir/ 606M mydir/ $ find mydir/ -type f -print | wc -l 12720 $ date Tue Sep 10 10:59:27 PDT 2013 $ rm -...
0
votes
1answer
33 views

How to remove file on Linux with ? in name

Cannot move or remove file with ? in name. Any ideas? Have tried the following: # ls manager?%80%99s-viewpoint.html what-wcsap-can-offer-you-?%80%93-guide-new-directors.html # mv manager\?%80%99s-...
0
votes
1answer
24 views

Delete all the folders and file except one folder

I want to remove all the folders and files but except one. I have a Ubuntu server and I tried several methods and none of them worked. This is my folder structure. app app/public app/public/uploads ...
0
votes
1answer
195 views

How to kill/rm pipe by inode number only?

EDIT: I originally cut and pasted a question I'd asked earlier on stackoverflow that got closed: http://stackoverflow.com/questions/32622224/how-to-kill-pipe-by-inode-number-only I've now run into ...
0
votes
1answer
50 views

How can I know what subfolders rm -rf attempted to delete first?

I mistakenly run rm -rf on a wrong folder and than cancel the operation after two seconds. The folder is quite big with many subfolders and maybe 1% was deleted. How can I know what subfolders rm ...
-3
votes
1answer
263 views

Couldn't remove a directory, already tried rmdir -rf

I kept on trying to remove a folder in the server, but I kept on getting a same error. Please help me. I used this post as a reference http://askubuntu.com/questions/217893/how-to-delete-a-non-empty-...
0
votes
0answers
33 views

How to make a busy file not busy so it can be deleted. rm: filename: Resource busy

I have somehow generated a file on a network mounted volume that is in the busy state, and I have no knowledge of what could be using it. I want the file gone, and am not really concerned about ...
0
votes
0answers
32 views

Have I messed up Time Machine backup?

I recently had a full power outage which happened in the middle of a Time-Machine backup to a Time Capsule on my network over WiFi. I've only recently got and started using the TimeCapsule device but ...
0
votes
0answers
56 views

Remove backups older than 7 days except first of every month

I want to delete backups older than 7 days but keep the first of every month. The name of the files is name_$(date +\%d\%m\%Y).tar.gz I want to keep name_$(date +\01\%m\%Y).tar.gz I want something ...
0
votes
0answers
128 views

10.11 rm -rf Facetime

I try to get rid of Facetime (then auto call link on random number is annoying me too much) I've try rm -rf /Applications/FaceTime.app/ but never have enough privilege (operation denied) Sudo is ...
0
votes
0answers
40 views

Accidentally partially deleted home directory . . . Killed with ctl-c, which file is corrupted?

I was running some software in my home directory (last time I do that!). Stupid config file asks what directory I wanted to put my output files. I accidently used ~/ as my output directory. It ...
0
votes
0answers
54 views

Linux: Delete all but x files?

I have a series of files with different IDs: File_ID1_1 File_ID1_2 File_ID1_3 File_ID1_4 File_ID1_5 File_ID1_6 File_ID2_1 File_ID2_2 File_ID3_1 File_ID3_2 File_ID3_3 For every ID there is a defined ...
0
votes
0answers
401 views

Bypass the $Recycle Bin in CygWin?

I'm using a CygWin session to find a large number of directories at a certain level in the file system tree in a loop, compress each directory into 1 archive, then delete the directory This ...
0
votes
0answers
120 views

rm -rf * results in “Killed”

I used PHP to generate about 4,000,000 files in a directory (f/) because I was bored. When I cd .. and use rm -rf f, it simply returns "Killed" about half a second later and does not delete the ...
0
votes
0answers
73 views

How can I tell whether an interrupted rm -r removed any files?

I installed sshfs a Linux box and then mounted my Mac home directory. In the middle of troubleshooting a configuration issue, I did an ls -l on the mount directory (as normal user), receiving: total ...
0
votes
0answers
475 views

How to delete *.vmdk files?

I can't seem to delete *.vmdk files and related on Mac OS X 10.6.8 with sudo rm: $ sudo rm -rf /Volumes/Temp/vm/ rm: /Volumes/Temp/vm//MarukoVM/nvram: Read-only file system rm: /Volumes/Temp/vm//...
0
votes
0answers
292 views

bash script rm cannot delete folder created by php mkdir

I cannot delete folder created by php mkdir for I in `echo $*` do find $I -type f -name "sess_*" -exec rm -f {} \; find $I -type f -name "*.bak" -exec rm -f {} \; find $I -type f -name "...