Jump to content
Mumble forums

Murmur and PHP Script on separate servers


pv-patrick
 Share

Recommended Posts

I am trying to get a PHP script to work via Ice and can't seem to get it connected.


My first question is: I have Murmur running on 1 machine and my script on another web server. Does the machine running Murmur need to have apache/ice/etc installed and running?


I have this in my .ini : ice="tcp -h 127.0.0.1 -p 6502" and in the logs it shows: MurmurIce: Endpoint "tcp -h 127.0.0.1 -p 6502" running


With my php script, I get the following error:

Uncaught exception ::Ice::ConnectionRefusedException {     error = 111 }   thrown in /opt/Ice-3.4.1/php/Murmur.php on line 1110

 

PHP Code:

require_once 'Ice.php';
require_once 'Murmur.php';
$ICE = Ice_initialize();
$meta = Murmur_MetaPrxHelper::checkedCast($ICE->stringToProxy('Meta:tcp -h MurmurServerIP -p 6502'));

 

I turned off/on the icesecret since I can't figure out how to pass it along with 3.4.1. Any help would be much appreciated, thank you!

Link to comment
Share on other sites

I do not know a lot about Ice, but what I do know is that 127.0.0.1 is the loopback ip of your machine. So if you want Ice to listen to requests coming from the outside you have to set it to the ip address of your computer.

Computer specs: AMD FX-8320, 8GB DDR3-SDRAM, AMD Radeon HD 7950, Asus Xonar D1, Windows 7 Ultimate 64bit/Debian Jessie AMD64.

Link to comment
Share on other sites

  • Administrators

Yeah.

 

My first question is: I have Murmur running on 1 machine and my script on another web server. Does the machine running Murmur need to have apache/ice/etc installed and running?

No.

You only need murmur to listen on the public ip, and a php script can call to Ice from elsewhere via that IP.

 

I have this in my .ini : ice="tcp -h 127.0.0.1 -p 6502" and in the logs it shows: MurmurIce: Endpoint "tcp -h 127.0.0.1 -p 6502" running

As rawnar said, that’s local (loopback).

You’ll have to set this to your public IP (or omit -h 127.0.0.1; it will probably listen on all available IPs then, but I’m not sure / have not tried).

 

I turned off/on the icesecret since I can't figure out how to pass it along with 3.4.1. Any help would be much appreciated, thank you!

When you make Ice public you should do 2 things for security:

  • change the default port of Ice
  • set an ice secret

Without an icesecret you should secure it via firewall or ices thing whichs name I forgot again, which is even more complex though.

To set your icesecret on PHP, see MumPI as a reference.

You’ll have to set the ice context on meta and server objects via ice_context function. Pass an array of 'secret'=>'icesecret value' as a parameter.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

 Share

×
×
  • Create New...