You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@ignite.apache.org by Ognen Duzlevski <og...@gmail.com> on 2015/04/20 15:59:07 UTC

What ports to open?

Hello, I think I have this question in a few different threads but still no
answer ;-)

What ports need to be open on machines so that an ignite cache cluster can
be functional?

I am getting these errors in the logs of my 5 machine ignite "cluster" on
EC2 (code works on a single machine) - the scala code using the cluster is
using it via setClientMode(true):

[08:49:57,648][INFO][disco-event-worker-#46%null%][GridDiscoveryManager]
Topology snapshot [ver=980, nodes=6, CPUs=40, heap=6.3GB]
[08:49:57,649][WARNING][disco-event-worker-#46%null%][GridDiscoveryManager]
Node FAILED: TcpDiscoveryNode [id=a4cc9d13-e595-4b94-9b3d-2bd0a9b23d2c,
addrs=[10.10.212.123, 127.0.0.1], sockAddrs=[dev-ognen.vpc/
10.10.212.123:47501, /10.10.212.123:47501, /127.0.0.1:47501],
discPort=47501, order=980, intOrder=493, loc=false,
ver=1.0.0#20150328-sha1:5fc2cd05, isClient=false]
[08:49:57,649][INFO][disco-event-worker-#46%null%][GridDiscoveryManager]
Topology snapshot [ver=981, nodes=5, CPUs=40, heap=5.0GB]
[08:49:59,765][WARNING][grid-time-coordinator-#48%null%][TcpCommunicationSpi]
Failed to connect to a remote node (make sure that destination node is
alive and operating system firewall is disabled on local and remote hosts)
[addrs=[/127.0.0.1:47101, dev-ognen.vpc/10.10.212.123:47101, /
10.10.212.123:47101]]

So far I have iptables set up to allow the following ports:
ACCEPT     udp  --  anywhere             anywhere            udp dpt:31100
ACCEPT     udp  --  anywhere             anywhere            udp dpt:47400
ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:47500
ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:47100

Is there anything I am missing? Is it port 47101 that needs to be open? If
so, does it need to be open on all the machines in the "cluster"?

I am happy to write up a guide on how to set these things up on Amazon (for
example) but I need some help/guidance...

Thanks!
Ognen

Re: What ports to open?

Posted by Ognen Duzlevski <og...@gmail.com>.
Val, beautiful - thanks!

On Tue, Apr 21, 2015 at 8:20 PM, Valentin Kulichenko <
valentin.kulichenko@gmail.com> wrote:

> Ognen,
>
> For Ignite node to be functional you need two ports to be opened - one for
> discovery and another for communication.
>
> Both TcpDiscoverySpi and TcpCommunicationSpi have two configuration
> properties: setLocalPort() and setLocalPortRange(). In both cases Ignite
> will use the first available port starting from localPort up until
> localPort+localPortRange.
>
> Default port for discovery is 47500, for communication it's 47100. Default
> range is 100. So with default settings you need to open ports 47500-47600
> and 47100-47200 as they all can be potentially used.
>
> --
> Val
>
> On Mon, Apr 20, 2015 at 8:16 AM, Ognen Duzlevski <
> ognen.duzlevski@gmail.com>
> wrote:
>
> > I have added tcp/47101 to iptables on each instance and then it
> complained
> > about 47501. I added tcp/47501 on every instance and everything is
> working.
> >
> > Are these chosen randomly?
> >
> > Thanks!
> >
> > On Mon, Apr 20, 2015 at 9:11 AM, Dmitriy Setrakyan <
> dsetrakyan@apache.org>
> > wrote:
> >
> > > In my opinion it should be tcp communication port + range and discovery
> > > port + range, however, I am not completely sure.
> > >
> > > I think either Valya or Yakov should know. Can you please respond?
> > >
> > > D.
> > >
> > > On Mon, Apr 20, 2015 at 8:59 AM, Ognen Duzlevski <
> > > ognen.duzlevski@gmail.com>
> > > wrote:
> > >
> > > > Hello, I think I have this question in a few different threads but
> > still
> > > no
> > > > answer ;-)
> > > >
> > > > What ports need to be open on machines so that an ignite cache
> cluster
> > > can
> > > > be functional?
> > > >
> > > > I am getting these errors in the logs of my 5 machine ignite
> "cluster"
> > on
> > > > EC2 (code works on a single machine) - the scala code using the
> cluster
> > > is
> > > > using it via setClientMode(true):
> > > >
> > > >
> > [08:49:57,648][INFO][disco-event-worker-#46%null%][GridDiscoveryManager]
> > > > Topology snapshot [ver=980, nodes=6, CPUs=40, heap=6.3GB]
> > > >
> > >
> >
> [08:49:57,649][WARNING][disco-event-worker-#46%null%][GridDiscoveryManager]
> > > > Node FAILED: TcpDiscoveryNode
> [id=a4cc9d13-e595-4b94-9b3d-2bd0a9b23d2c,
> > > > addrs=[10.10.212.123, 127.0.0.1], sockAddrs=[dev-ognen.vpc/
> > > > 10.10.212.123:47501, /10.10.212.123:47501, /127.0.0.1:47501],
> > > > discPort=47501, order=980, intOrder=493, loc=false,
> > > > ver=1.0.0#20150328-sha1:5fc2cd05, isClient=false]
> > > >
> > [08:49:57,649][INFO][disco-event-worker-#46%null%][GridDiscoveryManager]
> > > > Topology snapshot [ver=981, nodes=5, CPUs=40, heap=5.0GB]
> > > >
> > > >
> > >
> >
> [08:49:59,765][WARNING][grid-time-coordinator-#48%null%][TcpCommunicationSpi]
> > > > Failed to connect to a remote node (make sure that destination node
> is
> > > > alive and operating system firewall is disabled on local and remote
> > > hosts)
> > > > [addrs=[/127.0.0.1:47101, dev-ognen.vpc/10.10.212.123:47101, /
> > > > 10.10.212.123:47101]]
> > > >
> > > > So far I have iptables set up to allow the following ports:
> > > > ACCEPT     udp  --  anywhere             anywhere            udp
> > > dpt:31100
> > > > ACCEPT     udp  --  anywhere             anywhere            udp
> > > dpt:47400
> > > > ACCEPT     tcp  --  anywhere             anywhere            tcp
> > > dpt:47500
> > > > ACCEPT     tcp  --  anywhere             anywhere            tcp
> > > dpt:47100
> > > >
> > > > Is there anything I am missing? Is it port 47101 that needs to be
> open?
> > > If
> > > > so, does it need to be open on all the machines in the "cluster"?
> > > >
> > > > I am happy to write up a guide on how to set these things up on
> Amazon
> > > (for
> > > > example) but I need some help/guidance...
> > > >
> > > > Thanks!
> > > > Ognen
> > > >
> > >
> >
>

Re: What ports to open?

Posted by Valentin Kulichenko <va...@gmail.com>.
Ognen,

For Ignite node to be functional you need two ports to be opened - one for
discovery and another for communication.

Both TcpDiscoverySpi and TcpCommunicationSpi have two configuration
properties: setLocalPort() and setLocalPortRange(). In both cases Ignite
will use the first available port starting from localPort up until
localPort+localPortRange.

Default port for discovery is 47500, for communication it's 47100. Default
range is 100. So with default settings you need to open ports 47500-47600
and 47100-47200 as they all can be potentially used.

--
Val

On Mon, Apr 20, 2015 at 8:16 AM, Ognen Duzlevski <og...@gmail.com>
wrote:

> I have added tcp/47101 to iptables on each instance and then it complained
> about 47501. I added tcp/47501 on every instance and everything is working.
>
> Are these chosen randomly?
>
> Thanks!
>
> On Mon, Apr 20, 2015 at 9:11 AM, Dmitriy Setrakyan <ds...@apache.org>
> wrote:
>
> > In my opinion it should be tcp communication port + range and discovery
> > port + range, however, I am not completely sure.
> >
> > I think either Valya or Yakov should know. Can you please respond?
> >
> > D.
> >
> > On Mon, Apr 20, 2015 at 8:59 AM, Ognen Duzlevski <
> > ognen.duzlevski@gmail.com>
> > wrote:
> >
> > > Hello, I think I have this question in a few different threads but
> still
> > no
> > > answer ;-)
> > >
> > > What ports need to be open on machines so that an ignite cache cluster
> > can
> > > be functional?
> > >
> > > I am getting these errors in the logs of my 5 machine ignite "cluster"
> on
> > > EC2 (code works on a single machine) - the scala code using the cluster
> > is
> > > using it via setClientMode(true):
> > >
> > >
> [08:49:57,648][INFO][disco-event-worker-#46%null%][GridDiscoveryManager]
> > > Topology snapshot [ver=980, nodes=6, CPUs=40, heap=6.3GB]
> > >
> >
> [08:49:57,649][WARNING][disco-event-worker-#46%null%][GridDiscoveryManager]
> > > Node FAILED: TcpDiscoveryNode [id=a4cc9d13-e595-4b94-9b3d-2bd0a9b23d2c,
> > > addrs=[10.10.212.123, 127.0.0.1], sockAddrs=[dev-ognen.vpc/
> > > 10.10.212.123:47501, /10.10.212.123:47501, /127.0.0.1:47501],
> > > discPort=47501, order=980, intOrder=493, loc=false,
> > > ver=1.0.0#20150328-sha1:5fc2cd05, isClient=false]
> > >
> [08:49:57,649][INFO][disco-event-worker-#46%null%][GridDiscoveryManager]
> > > Topology snapshot [ver=981, nodes=5, CPUs=40, heap=5.0GB]
> > >
> > >
> >
> [08:49:59,765][WARNING][grid-time-coordinator-#48%null%][TcpCommunicationSpi]
> > > Failed to connect to a remote node (make sure that destination node is
> > > alive and operating system firewall is disabled on local and remote
> > hosts)
> > > [addrs=[/127.0.0.1:47101, dev-ognen.vpc/10.10.212.123:47101, /
> > > 10.10.212.123:47101]]
> > >
> > > So far I have iptables set up to allow the following ports:
> > > ACCEPT     udp  --  anywhere             anywhere            udp
> > dpt:31100
> > > ACCEPT     udp  --  anywhere             anywhere            udp
> > dpt:47400
> > > ACCEPT     tcp  --  anywhere             anywhere            tcp
> > dpt:47500
> > > ACCEPT     tcp  --  anywhere             anywhere            tcp
> > dpt:47100
> > >
> > > Is there anything I am missing? Is it port 47101 that needs to be open?
> > If
> > > so, does it need to be open on all the machines in the "cluster"?
> > >
> > > I am happy to write up a guide on how to set these things up on Amazon
> > (for
> > > example) but I need some help/guidance...
> > >
> > > Thanks!
> > > Ognen
> > >
> >
>

Re: What ports to open?

Posted by Ognen Duzlevski <og...@gmail.com>.
I have added tcp/47101 to iptables on each instance and then it complained
about 47501. I added tcp/47501 on every instance and everything is working.

Are these chosen randomly?

Thanks!

On Mon, Apr 20, 2015 at 9:11 AM, Dmitriy Setrakyan <ds...@apache.org>
wrote:

> In my opinion it should be tcp communication port + range and discovery
> port + range, however, I am not completely sure.
>
> I think either Valya or Yakov should know. Can you please respond?
>
> D.
>
> On Mon, Apr 20, 2015 at 8:59 AM, Ognen Duzlevski <
> ognen.duzlevski@gmail.com>
> wrote:
>
> > Hello, I think I have this question in a few different threads but still
> no
> > answer ;-)
> >
> > What ports need to be open on machines so that an ignite cache cluster
> can
> > be functional?
> >
> > I am getting these errors in the logs of my 5 machine ignite "cluster" on
> > EC2 (code works on a single machine) - the scala code using the cluster
> is
> > using it via setClientMode(true):
> >
> > [08:49:57,648][INFO][disco-event-worker-#46%null%][GridDiscoveryManager]
> > Topology snapshot [ver=980, nodes=6, CPUs=40, heap=6.3GB]
> >
> [08:49:57,649][WARNING][disco-event-worker-#46%null%][GridDiscoveryManager]
> > Node FAILED: TcpDiscoveryNode [id=a4cc9d13-e595-4b94-9b3d-2bd0a9b23d2c,
> > addrs=[10.10.212.123, 127.0.0.1], sockAddrs=[dev-ognen.vpc/
> > 10.10.212.123:47501, /10.10.212.123:47501, /127.0.0.1:47501],
> > discPort=47501, order=980, intOrder=493, loc=false,
> > ver=1.0.0#20150328-sha1:5fc2cd05, isClient=false]
> > [08:49:57,649][INFO][disco-event-worker-#46%null%][GridDiscoveryManager]
> > Topology snapshot [ver=981, nodes=5, CPUs=40, heap=5.0GB]
> >
> >
> [08:49:59,765][WARNING][grid-time-coordinator-#48%null%][TcpCommunicationSpi]
> > Failed to connect to a remote node (make sure that destination node is
> > alive and operating system firewall is disabled on local and remote
> hosts)
> > [addrs=[/127.0.0.1:47101, dev-ognen.vpc/10.10.212.123:47101, /
> > 10.10.212.123:47101]]
> >
> > So far I have iptables set up to allow the following ports:
> > ACCEPT     udp  --  anywhere             anywhere            udp
> dpt:31100
> > ACCEPT     udp  --  anywhere             anywhere            udp
> dpt:47400
> > ACCEPT     tcp  --  anywhere             anywhere            tcp
> dpt:47500
> > ACCEPT     tcp  --  anywhere             anywhere            tcp
> dpt:47100
> >
> > Is there anything I am missing? Is it port 47101 that needs to be open?
> If
> > so, does it need to be open on all the machines in the "cluster"?
> >
> > I am happy to write up a guide on how to set these things up on Amazon
> (for
> > example) but I need some help/guidance...
> >
> > Thanks!
> > Ognen
> >
>

Re: What ports to open?

Posted by Dmitriy Setrakyan <ds...@apache.org>.
In my opinion it should be tcp communication port + range and discovery
port + range, however, I am not completely sure.

I think either Valya or Yakov should know. Can you please respond?

D.

On Mon, Apr 20, 2015 at 8:59 AM, Ognen Duzlevski <og...@gmail.com>
wrote:

> Hello, I think I have this question in a few different threads but still no
> answer ;-)
>
> What ports need to be open on machines so that an ignite cache cluster can
> be functional?
>
> I am getting these errors in the logs of my 5 machine ignite "cluster" on
> EC2 (code works on a single machine) - the scala code using the cluster is
> using it via setClientMode(true):
>
> [08:49:57,648][INFO][disco-event-worker-#46%null%][GridDiscoveryManager]
> Topology snapshot [ver=980, nodes=6, CPUs=40, heap=6.3GB]
> [08:49:57,649][WARNING][disco-event-worker-#46%null%][GridDiscoveryManager]
> Node FAILED: TcpDiscoveryNode [id=a4cc9d13-e595-4b94-9b3d-2bd0a9b23d2c,
> addrs=[10.10.212.123, 127.0.0.1], sockAddrs=[dev-ognen.vpc/
> 10.10.212.123:47501, /10.10.212.123:47501, /127.0.0.1:47501],
> discPort=47501, order=980, intOrder=493, loc=false,
> ver=1.0.0#20150328-sha1:5fc2cd05, isClient=false]
> [08:49:57,649][INFO][disco-event-worker-#46%null%][GridDiscoveryManager]
> Topology snapshot [ver=981, nodes=5, CPUs=40, heap=5.0GB]
>
> [08:49:59,765][WARNING][grid-time-coordinator-#48%null%][TcpCommunicationSpi]
> Failed to connect to a remote node (make sure that destination node is
> alive and operating system firewall is disabled on local and remote hosts)
> [addrs=[/127.0.0.1:47101, dev-ognen.vpc/10.10.212.123:47101, /
> 10.10.212.123:47101]]
>
> So far I have iptables set up to allow the following ports:
> ACCEPT     udp  --  anywhere             anywhere            udp dpt:31100
> ACCEPT     udp  --  anywhere             anywhere            udp dpt:47400
> ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:47500
> ACCEPT     tcp  --  anywhere             anywhere            tcp dpt:47100
>
> Is there anything I am missing? Is it port 47101 that needs to be open? If
> so, does it need to be open on all the machines in the "cluster"?
>
> I am happy to write up a guide on how to set these things up on Amazon (for
> example) but I need some help/guidance...
>
> Thanks!
> Ognen
>