Tuesday, May 1, 2012

Delete All Files And Folders In Linux

How do I delete all files and folders stored in /home/jerry/movies directories under Linux operating systems?

You need to the rm command.
Open a terminal or shell (bash) prompt and type the following command to delete everything in /home/jerry/movies
 
cd /home/jerry/movies
pwd
rm -rf *
OR you can use the following single command:
 
rm -rf /home/jerry/movies/
 
Please note that all folders and files including movies will be deleted. Once deleted you will not able to get back your data. So be careful when typing rm -rf command.

No comments:

Post a Comment