摘要:
写了一个shell脚本,手动执行有效,在crontab中执行却没有效果最后发现貌似是环境变量的问题。脚本如下:#!/bin/sh#this is a script to control the message of mail##########################. /etc/profile. ~/.bash_profile##########################sum=`/usr/sbin/postqueue -p |wc -l`if [[ $sum -gt 100 ]]then /usr/sbin/postqueue -p | awk '/cs_0105@q 阅读全文