StarCluster - Mailing List Archive

Re: Port Forwarding Plugin

From: Justin Riley <no email>
Date: Tue, 31 Jul 2012 18:41:24 -0400

Hey Chris,

Once again, my apologies for the delay. I think using
node.ssh.execute_async should solve your immediate problem with the
plugin but I will test this and get back to you with details on why.

Taking a step back, I don't think this plugin is really necessary. I
already, by default, allow all traffic between nodes in the cluster's
security group so mongo should be able to listen on the public interface
(ie master:$port) and be accessible to all nodes without being wide open
to the world. I just looked at the docs and this clearly needs to be
documented. Added an issue[1] so I don't forget to add it in.




On Thu, Jun 21, 2012 at 10:36:22AM -0400, Chris Diehl wrote:
> Hi All,
> I wrote a plugin yesterday to do port forwarding from a specified port on
> the master to all of the nodes. The goal is to have a DB such as Mongo
> running on the master and available on the specified port on all the
> nodes.
> For whatever reason, when the cluster is firing up, the process grinds to
> a halt when it is running this plugin.
> Any thoughts on what might be the cause? I've tried it both with a port
> value passed in and specified in the code. I can execute the ssh command
> below successfully on the nodes. I used nmap to check if I was using a
> port that I should not be. Everything seems good but clearly something is
> not working as intended.
> Thanks, Chris
> from starcluster.clustersetup import ClusterSetup
> from starcluster.logger import log
> class MongoPortForwarding(ClusterSetup):
> def __init__(self, port):
> self.port = port
> log.debug("port = %s" % port)
> def run(self, nodes, master, user, user_shell, volumes):
> [1]"Number of nodes: %d" % len(nodes))
> for node in nodes:
> if node != master:
> [2]"Setting up port forwarding for node %s." %
> node.alias)
> #node.ssh.execute("ssh -f -N -L %s:localhost:%s
> root_at_master" % (self.port,self.port))
> node.ssh.execute("ssh -f -N -L 1234:localhost:1234
> root_at_master")
> References
> Visible links
> 1.
> 2.

> _______________________________________________
> StarCluster mailing list

  • application/pgp-signature attachment: stored
Received on Tue Jul 31 2012 - 18:41:28 EDT
This archive was generated by hypermail 2.3.0.


Sort all by: