linux delete files older than 3 days
|
4 down vote accepted
|
This is easy enough (although note that this goes by a modification time more than 3 days ago since a creation time is only available on certain filesystems with special tools):
Remove the To have it run by cron, I would probably just create an executable script (add a shebang - UpdateAs noted below, the
Again remove the Update2To quote from Stéphane Chazelas comment below:
|
link:http://unix.stackexchange.com/questions/136804/cron-job-to-delete-files-older-than-3-days
linux delete files older than 3 days的更多相关文章
- Common Linux log files name and usage--reference
reference:http://www.coolcoder.in/2013/12/common-linux-log-files-name-and-usage.html if you spend lo ...
- linux delete file
今天不小心生成了这么个文件名的文件-ep-ser 然后 rm -ep-ser就删除不了,它认为-e是option 后来,用rm ./-ep-ser就顺利删除了,哈哈,教训啊
- Ansible 删除多个文件或目录
翻译和转载该网页内容 http://www.mydailytutorials.com/ansible-delete-multiple-files-directories-ansible/ 背景 ans ...
- sql server数据同步方案-日志传送
1 功能描述 本方案采用日志传送模式,把核心数据库(主数据库)定期同步到灾备数据库(辅助服务器)及备份库(辅助服务器,便于其他系统使用,减轻主数据压力),期间,如果发生异常导致无法同步,将以电子邮件. ...
- 【shell文字】mysql每日备份shell文字
每天固定时间使用mysqldump 备份mysql数据. #!/bin/bash #每天早上4点, mysql备份数据 orangleliu #chmod 700 backup.sh #crontab ...
- 【shell脚本】mysql每日备份shell脚本
每天固定时间用mysqldump 备份mysql数据. #!/bin/bash #每天早上4点, mysql备份数据 orangleliu #chmod 700 backup.sh #crontab ...
- postgresql backup
#!/bin/sh # Database backup script # Backup use postgres pg_dump command: # pg_dump -U <user> ...
- mysql定时备份shell脚本
#!/bin/bash #每天早上4点, mysql备份数据 # backup.sh #crontab -e # * * * /home/erya/run/moniter/mysql_backup.s ...
- List or delete hidden files from command prompt(CMD)
In Windows, files/folders have a special attribute called hidden attribute. By setting this attribut ...
随机推荐
- oracle merge into 语法
MERGE INTO upperLowerLimitData t1 USING (select name,enname,starttime,value ... from dual) t2 ON ( ...
- Linux查看系统基本信息
问题描述: 查看系统基本信息 问题解决: (1)lspci 是一个用来显示系统中所有PCI总线设备或连接到该总线上的所有设备的工具. 用法: lspci -v (1.1) ...
- CSS滤镜详解
语法:STYLE="filter:filtername(fparameter1, fparameter2...)" (Filtername为滤镜的名称,fparameter1.fp ...
- 【POJ】【1067】取石子游戏
博弈论 这个是博弈游戏中的Wythoff博弈: 以下为我的代码: //POJ 1067 #include<cmath> #include<cstdio> #include< ...
- 【BZOJ】【2693】JZPTAB
莫比乌斯反演 PoPoQQQ讲义第5题,是BZOJ 2154的升级版(多次询问) 题解:http://blog.csdn.net/popoqqq/article/details/42078725 WA ...
- 初识PCA数据降维
PCA要做的事降噪和去冗余,其本质就是对角化协方差矩阵. 一.预备知识 1.1 协方差分析 对于一般的分布,直接代入E(X)之类的就可以计算出来了,但真给你一个具体数值的分布,要计算协方差矩阵,根据这 ...
- hdu 1754 线段树入门
线段树点修改 区间最大值查询 #include <cstdio> #include <cstdlib> #include <cmath> #include < ...
- new Date()的数据类型的问题
function getServerNow(){ return new Date(new Date() + svrMinusLocal); } svrMinusLocal是服务器时间减本地时间的时间差 ...
- POJ 2184 Cow Exhibition (01背包的变形)
本文转载,出处:http://www.cnblogs.com/Findxiaoxun/articles/3398075.html 很巧妙的01背包升级.看完题目以后很明显有背包的感觉,然后就往背包上靠 ...
- WPF中log4net的用法
WPF中如何使用log4nethttp://www.cnblogs.com/C-Sharp2/archive/2013/04/12/WPF-LOG4NET.html Apache log4net Ma ...