tomcat启动zookeeper也已正常启动报错No provider available for the service

linux下启动zookeeper成功

[root@root bin]# ./zkServer.sh status
JMX enabled by default
Using config: /root/soft/zookeeper-3.4.6/bin/../conf/zoo.cfg
Mode: standalone

在启动服务层工程后,再启动表现层工程tomcat服务器报错

Caused by: java.lang.IllegalStateException: Failed to check the status of the service cn.campus.service.ItemService. No provider available for the service cn.campus.service.ItemService from the url zookeeper://192.168.17.129:2181/com.alibaba.dubbo.registry

解决方案:多数是因为linux系统下的防火墙未关闭造成表现层向zookeeper请求服务无法请求成功,需要关闭防火墙

查看自己使用的是centos6.*还是centOS7.*版本的系统

centOS6系列版本的命令

关闭命令:  service iptables stop 
永久关闭防火墙:chkconfig iptables off
[root@root ~]# service iptables stop
iptables:将链设置为政策 ACCEPT:filter                    [确定]
iptables:清除防火墙规则:                                 [确定]
iptables:正在卸载模块:                                   [确定]
[root@root ~]# service iptables status
iptables:未运行防火墙。

centOS7系列版本的命令

查看防火墙状态:firewall-cmd --state

关闭防火墙:systemctl stop firewalld.service

 

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值