支持匹配路径 匹配文件名 多久没有访问的自动清理
复制代码 代码如下:
#用于各系统清理文件脚本,filepath reg_filename fileatime
#author Foyon0806@gmail.com
#date 2013-8-22 14:51:52
#!/bin/sh
if [ $# -eq 0 ];then
echo "Usage: sh auto_clear_file.sh clear_filepath clear_regfilename filecreatetime"
echo "eg: sh auto_clear_file.sh /tmp/log/ user_log -7day"
exit
fi
filepath=$1
regfilename=$2
if [ "-$3" = "-" ];then
filectime=`date -d -7day '+ %s'`
else
filectime=`date -d $3 '+ %s'`
fi
log=`ls $filepath | grep $regfilename`
echo $log
for file in ${log}
do
echo $file
fileatime=`stat -c %X ${filepath}${file}`
if [ ${fileatime} -lt ${filectime} ]; then
opt=`rm -f ${filepath}${file}`
echo $opt
fi
done
自动删除文件
RTX 5090要首发 性能要翻倍!三星展示GDDR7显存
三星在GTC上展示了专为下一代游戏GPU设计的GDDR7内存。
首次推出的GDDR7内存模块密度为16GB,每个模块容量为2GB。其速度预设为32 Gbps(PAM3),但也可以降至28 Gbps,以提高产量和初始阶段的整体性能和成本效益。
据三星表示,GDDR7内存的能效将提高20%,同时工作电压仅为1.1V,低于标准的1.2V。通过采用更新的封装材料和优化的电路设计,使得在高速运行时的发热量降低,GDDR7的热阻比GDDR6降低了70%。