Oozie shell动作不发送邮件通知

时间:2017-05-08 04:29:29

标签: shell email hdfs oozie oozie-coordinator

我正在通过oozie运行shell脚本。我的shell脚本有一段代码。当我通过unix命令行运行这个shell脚本时收到一封电子邮件但是当我通过oozie Job运行这个shell脚本时它会成功,但我没有收到任何邮件。我该如何解决这个问题?或者有没有其他方法可以在unix文件系统中匹配字符串后收到带附件的电子邮件?

if [ "$Var" = "Error" ]
        then
                echo "Data error" | mail -v -s  "Data Error" -a error.csv -S smtp=smtp://mail-gateway -S from=localhost@gmail.com" Kevin@gmail.com
exit

0 个答案:

没有答案
相关问题