When I run it, this is the error I get:<br><b>/usr/local/lib/ruby/gems/1.8/gems/tmm1-amqp-0.6.4/lib/amqp/client.rb:65:in `initialize&#39;: Could not connect to server <i>hostname</i>:5672 (AMQP::Error)<br>    from /usr/local/lib/ruby/gems/1.8/gems/tmm1-amqp-0.6.4/lib/amqp/client.rb:97:in `call&#39;<br>
    from /usr/local/lib/ruby/gems/1.8/gems/tmm1-amqp-0.6.4/lib/amqp/client.rb:97:in `unbind&#39;<br>    from /usr/local/lib/ruby/gems/1.8/gems/eventmachine-0.12.8/lib/eventmachine.rb:995:in `call&#39;<br>    from /usr/local/lib/ruby/gems/1.8/gems/eventmachine-0.12.8/lib/eventmachine.rb:995:in `run_deferred_callbacks&#39;<br>
    from /usr/local/lib/ruby/gems/1.8/gems/eventmachine-0.12.8/lib/eventmachine.rb:995:in `times&#39;<br>    from /usr/local/lib/ruby/gems/1.8/gems/eventmachine-0.12.8/lib/eventmachine.rb:995:in `run_deferred_callbacks&#39;<br>
    from /usr/local/lib/ruby/gems/1.8/gems/eventmachine-0.12.8/lib/eventmachine.rb:242:in `run_machine&#39;<br>    from /usr/local/lib/ruby/gems/1.8/gems/eventmachine-0.12.8/lib/eventmachine.rb:242:in `run&#39;<br>    from /usr/local/lib/ruby/gems/1.8/gems/tmm1-amqp-0.6.4/lib/amqp.rb:84:in `start&#39;<br>
    from test_processor.rb:7</b><br><br>Could it because port 5672 is not accessible from outside?  In that case, how do I expose it?<br>I tried iptables like this:<br><b>iptables -A INPUT -p tcp --dport 5672 -j ACCEPT</b><br>
<br>But still no luck.  How do I configure rabbitmq to accept requests from external IPs?<br><br>-S<br><br><div class="gmail_quote">2009/9/9 Paul Jones <span dir="ltr">&lt;<a href="mailto:pauljones23@gmail.com">pauljones23@gmail.com</a>&gt;</span><br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">Sridhar,<br><br>Can you describe how this doesn&#39;t work?<br><br>Paul.<br><br><div class="gmail_quote">
<div><div></div><div class="h5">On Wed, Sep 9, 2009 at 8:46 AM, Sridhar Raman <span dir="ltr">&lt;<a href="mailto:sridhar.raman@gmail.com" target="_blank">sridhar.raman@gmail.com</a>&gt;</span> wrote:<br>
</div></div><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div><div></div><div class="h5">Hi<br><br>This is our current setup that is working in a server:<br>
Listener (that receives the data and publishes it):<br>
<b>module QueueData<br>    def receive_data(d)<br>        $amq.queue(&quot;queue_name&quot;).publish(d)<br>

    end<br>end<div><br>EM.run {<br>  $amq = MQ.new<br></div>  EM.start_server &quot;0.0.0.0&quot;, 22003, QueueData <br>}</b><br><br>Processor (that subscribes to the queue and processes it):<br><b>EM.run { <br>
  amq = MQ.new<br>
  amq.queue(&quot;queue_name&quot;).subscribe { |d|<br>    puts d <br>  }<br>}</b><br><br>How do I subscribe to this queue from another machine?  I tried this:<br><b>AMQP.start(:host =&gt; &#39;hostname&#39;, :port =&gt; 5672, :logging =&gt; true) do<br>


  puts &quot;connected ...&quot;<br>  mq = MQ.new<br>  MQ.queue(&#39;queue_name&#39;).subscribe{ |msg|<br>    puts msg<br>  }<br>end</b><br><br>But it doesn&#39;t work.  Any suggestions?<br>
<br></div></div>_______________________________________________<br>
rabbitmq-discuss mailing list<br>
<a href="mailto:rabbitmq-discuss@lists.rabbitmq.com" target="_blank">rabbitmq-discuss@lists.rabbitmq.com</a><br>
<a href="http://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss" target="_blank">http://lists.rabbitmq.com/cgi-bin/mailman/listinfo/rabbitmq-discuss</a><br>
<br></blockquote></div><br>
</blockquote></div><br>