mycat启动报错UnknownHostException(Temporary failure in name resolution)解决方法

重启命令

./mycat restart

查看日志

cd logs
tail -f wrapper.log

报错信息

INFO   | jvm 2    | 2018/05/09 11:28:28 | Error: Exception thrown by the agent : java.net.MalformedURLException: 
Local host name unknown: java.net.UnknownHostException: hifu-test1: hifu-test1: Temporary failure in name resolution

解决方法

su - root

用root用户或有权限的用户

cd /etc
vi hosts

增加:

23.23.22.18     hifu-test1
23.23.22.19     hifu-test2

原因

  • 主机名原来叫aaa,前几天改为hifu-test1,但hosts没修改。
  • 由于mycat已经启动,只要不重新加载,一直运行良好,但一旦重启,则失败。

猜你喜欢

转载自www.cnblogs.com/ouyida3/p/9031454.html