定期删除 中间结果,如同 空间慢 。很可能 计算节点 就不能计算 影响速度
#!/bin/sh
hosts='zw-hadoop-slave221 zw-hadoop-slave222 zw-hadoop-slave223 zw-hadoop-slave224 zw-hadoop-slave225 zw-hadoop-slave226 zw-hadoop-slave227 zw-hadoop-slave228 zw-hadoop-slave229 zw-hadoop-slave33 zw-hadoop-slave34 zw-hadoop-slave35 zw-hadoop-slave36 zw-hadoop-slave54 zw-hadoop-slave55 zw-hadoop-slave56 zw-hadoop-slave57'

for host in $hosts
do
  echo "Begin deploy $host"
  ssh  $host " find /opt/log/hadoop/userlogs/  -maxdepth 1  -mindepth 1 -atime +1 -exec rm -rf {} \; " ;
  echo "Begin deploy $host"
done





09-25 21:51