建立脚本
vim /home/it_support/crontab_zhouhao/del.sh
脚本内容如下:
#!/bin/bash
sudo find /data/appadmjjkj/app/information-data-service/logs/backup/2022-06/ -mtime +7 -name "*.log" -exec sudo rm -rf {
} \;
sudo find /data/appadmjjkj/app/information-data-service/logs/backup/2022-06/ -mtime +7 -name "*.log.gz" -ex