55 09 * * * cd /temp/YLMonitor/ && ./mysql_backup_cloud.sh
Jan 24 09:06:01 localhost CROND[185965]: (root) CMD (sh temp/YLMonitor/mysql_backup_cloud.sh)Jan 24 09:06:01 localhost CROND[185963]: (root) MAIL (mailed 69 bytes of output but got status 0x007f#012)

打开inet_protocols = all这一行


loading shared libraries: libmysqlclient.so.18: cannot open shared object file: No suche loading shared libraries: libmysqlclient.so.18: cannot open shared object file: No sucading shared libraries: libmysqlclient.so.18: cannot open shared object file: No such fi
[root@localhost mysql]# cat etc/ld.so.confinclude ld.so.conf.d/*.con[root@localhost mysql]# ls etc/ld.so.conf.d/dyninst-x86_64.conf libiscsi-x86_64.conf qt-x86_64.confkernel-3.10.0-514.el7.x86_64.conf mysql-x86_64.conf xulrunner-64.conf
[root@localhost mysql]# cat /etc/ld.so.conf.d/mysql-x86_64.conf/usr/lib64/mysql

chmod 755 libmysqlclient.so.18*
[root@localhost mysql]# ldconfigldconfig: /usr/lib64/mysql/libmysqlclient.so.18 不是符号连接[root@localhost mysql]# readlink libmysqlclient.so.20 ##查看链接的原始文件libmysqlclient.so.20.3.15[root@localhost mysql]# rm libmysqlclient.so.18rm:是否删除普通文件 "libmysqlclient.so.18"?y[root@localhost mysql]# ln -s libmysqlclient.so.18.0.0 libmysqlclient.so.18 #重新建立链接c[root@localhost mysql]# ldconfig
重启postfix服务,发现已经恢复正常:

三、脚本环境问题
判断可能和系统环境变量有关:
加入:source etc/profile 指令
指定该命令的原始路径 :/usr/local/bin/xxxxxx
[root@localhost YLMonitor]# whereis xxxxxxxxxxxx : /usr/local/bin/xxxxxx
再次加入定时任务验证,发现已经成功解决。


文章转载自巴韭特锁螺丝,如果涉嫌侵权,请发送邮件至:contact@modb.pro进行举报,并提供相关证据,一经查实,墨天轮将立刻删除相关内容。




