请按照日期格式(xxxx-xx-xx)每日生成一个文件,例如今天生成的文件为2017-09-03.log, 并且把磁盘的使用情况写到到这个文件中。

## vim log.sh

#!/bin/bash
d=`date +%F`
touch $d.log
df -hT > $d.log
crontab -e

00 * * * /bin/sh /root/shell/log.sh