错误: 使用InetAddress.getLocalHost().getHostAddress()提示方法不存在 系统:centos7 环境:docker容器 原因:SElinux处于开启状态 解决办
错误: 使用InetAddress.getLocalHost().getHostAddress()提示方法不存在
系统:centos7
环境:docker容器
原因:SElinux处于开启状态
解决办法: setenforce 0 关闭SELinux
注:有时候在centos下提示连接数据库失败,可能是配置文件中数据库地址写成了localhost并且系统没有关闭SELinux