Centos6.5 php5.3中使用ice3.5报错::Ice::SocketException

qq_21718983 2015-03-07 10:58:38
环境Centos6.5 PHP Version 5.3.3
ice
Ice support enabled
Ice version 3.5.1

Directive Local Value Master Value
ice.config no value no value
ice.hide_profiles 1 1
ice.options no value no value
ice.profiles no value no value



<?php
require 'Ice.php';
require 'Hello.php';

$ic = null;
try {
$ic = Ice_initialize();
$base = $ic->stringToProxy("HelloObj:tcp -h 127.0.0.1 -p 10000");
$printer = Demo_HelloPrxHelper::checkedCast($base);
if(!$printer)
throw new RuntimeException("Invalid proxy");

echo $printer->sayHello();
} catch(Exception $ex) {
echo $ex;
}

if($ic) {
try {
$ic->destroy();
} catch(Exception $ex) {
echo $ex;
}
}
?>


运行后报错exception ::Ice::SocketException { error = 13 }

有没有搞过ICE中间件的大神,帮忙解决下。
...全文
203 2 打赏 收藏 转发到动态 举报
写回复
用AI写文章
2 条回复
切换为时间正序
请发表友善的回复…
发表回复
涂荼 2015-09-02
  • 打赏
  • 举报
回复
exception ::Ice::SocketException { error = 13 } 关闭 SELinux echo 0 > /selinux/enforce exception ::Ice::ConnectionRefusedException { error = 111 } 解决方案:关闭防火墙 /etc/rc.d/init.d/iptables stop
涂荼 2015-09-02
  • 打赏
  • 举报
回复
关闭你的防火墙 /etc/rc.d/init.d/iptables stop

19,612

社区成员

发帖
与我相关
我的任务
社区描述
系统使用、管理、维护问题。可以是Ubuntu, Fedora, Unix等等
社区管理员
  • 系统维护与使用区社区
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告
暂无公告

试试用AI创作助手写篇文章吧