Results 1 to 5 of 5
I have a quick question. I'm just getting back into unix so my command line is weak.
How can I delete say all my folders from 2008?
Or delete a ...
- 05-12-2009 #1
deleting old data
I have a quick question. I'm just getting back into unix so my command line is weak.
How can I delete say all my folders from 2008?
Or delete a certain month worth of folders? say Jan 2009.
- 05-12-2009 #2
rm is the remove command use
man rm
to get all the options
- 05-12-2009 #3
Please Refer this thread - it should help you to learn about it ( i guess you can ignore the name option which is specified below and change the mtime option to specific time period)
http://www.linuxforums.org/forum/red...t-exec-rm.html
HTH- Lakshmipathi.G
-------------------
FOSS India Award winning ext3fs Undelete tool and tutorials www.giis.co.in
First they criticize you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
-------------------
- 05-12-2009 #4
Thank you Lakshmipathi. That's exactly what I needed. My drive was filling up and I needed to get rid of the old files. I actually found my answer about 10 minutes after I posted this thread last night.
- 05-22-2009 #5
Today i came to know about this solution:
To delete all files after specific date (say : 2009/05/18 12:00 pm)
first create a file.
then use it with find commandtouch -t 200905181200 test
Hope this helps someonefind /var/log/ -type f -newer test -exec rm {} \;
- Lakshmipathi.G
-------------------
FOSS India Award winning ext3fs Undelete tool and tutorials www.giis.co.in
First they criticize you,Then they laugh at you,Then they fight with you,Then you win. - M.K.Gandhi
-------------------


Reply With Quote