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 ...
随机推荐
- java性能优化策略
1. 尽量使用局部变量代替成员变量,循环中对成员变量.方法的调用不超过2次 2. ArrayList如果知道大小,初始化时应指明 3. HashMap的遍历,用Entry 4. 如果确定类不可继承尽量 ...
- 自己的一些 Demo,源码链接
1.指纹解锁(GitHub). 2.JS 与 OC 交互(GitHub). 3.模仿 HTML 下拉菜单(GitHub). 4.OC开发常用类目(GitHub).
- win8 telnet VirtualBox中的redhat9
1. VirtualBox设置网络连接为“桥接网卡”,并且此网卡要为win8正在使用的网卡(比如我的电脑上使用的就是无线网卡,则选择网卡时也要用无线网卡) 2. 在redhat的终端里,运行ifcon ...
- 【BZOJ】【2819】NIM
这题……咋说捏,其实是一道披着博弈论外衣的树上操作问题…… 随便用dfs序或者树链剖分转成序列,然后查询路径上的所有点的NIM和(异或和)就行了,毕竟除了是在树上以外,就是裸的NIM问题. 树链剖分: ...
- [转载]WebBrowser控件表单(form)的自动填写和提交
话说有了WebBrowser类,终于不用自己手动封装SHDocVw的AxWebBrowser这个ActiveX控件了.这个类如果仅仅作为一个和IE一模一样浏览器,那就太没意思了(还不如直接用IE呢). ...
- Ubuntu 14.04 + Linux 3.14.34 系统调用实现文件拷贝
采用 64位系统, ubuntu 14.04 + 新内核linux-3.14.34 下载地址https://www.kernel.org/pub/linux/kernel/v3.x/linux-3.1 ...
- 推荐:根据ISBN号查询图书信息的API - 豆瓣API
转帖,出处:http://blog.csdn.net/berryreload/article/details/9126645 版权声明:本文为博主原创文章,未经博主允许不得转载. 找了半天,还是豆瓣的 ...
- ibatis框架文件配置
最近2天在学ibatis,心里也有一些心得,就把它写下来了. 首先是配置一下ibatis的环境,添加ibatis2.X.jar,mysql-connection-bin.5.1.8.jar,建立一个w ...
- Hadoop基础教程之搭建开发环境及编写Hello World
整个Hadoop是基于Java开发的,所以要开发Hadoop相应的程序就得用JAVA.在linux下开发JAVA还数eclipse方便. 1.下载 进入官网:http://eclipse.org/do ...
- MIT算法导论——第一讲.Analysis of algorithm
本栏目(Algorithms)下MIT算法导论专题是个人对网易公开课MIT算法导论的学习心得与笔记.所有内容均来自MIT公开课Introduction to Algorithms中Charles E. ...