Couldn't connect to the seed node error on Ubuntu AWS EC2

+2 votes
I have our chain running for a few weeks now with 4 nodes. I can fire up new nodes on my AWS account and be connected and running in a few minutes. I can do this repeatedly with zero issues. I've launched, connected and mined with hundreds of testing nodes by now.

However, when ANY other server outside my AWS account tries to connect to our chain they get the same problem here:

https://www.multichain.com/qa/3381/couldnt-connect-to-the-seed-node-error-on-ubuntu-aws-ec2

I ran multichaind -debug=mchn -debug=mchnminor -debug=net on our chain but I don't see anything in the debug.log file at the timestamp when I try to connect.

Here's all I see around that time stamp on the debug.log

2017-08-26 19:03:42 (8 bytes) peer=1
2017-08-26 19:03:42 mchn: RECV: pong, peer=1
2017-08-26 19:03:42 received: pong (8 bytes) peer=1
2017-08-26 19:03:43 mchn: RECV: ping, peer=2
2017-08-26 19:03:43 received: ping (8 bytes) peer=2
2017-08-26 19:03:43 sending: pong mchn: SEND: pong
2017-08-26 19:03:43 (8 bytes) peer=2
2017-08-26 19:03:43 sending: ping mchn: SEND: ping
2017-08-26 19:03:43 (8 bytes) peer=2
2017-08-26 19:03:43 mchn: RECV: pong, peer=2
2017-08-26 19:03:43 received: pong (8 bytes) peer=2
2017-08-26 19:03:44 mchn: RECV: ping, peer=3
2017-08-26 19:03:44 received: ping (8 bytes) peer=3
2017-08-26 19:03:44 sending: pong mchn: SEND: pong
2017-08-26 19:03:44 (8 bytes) peer=3
2017-08-26 19:03:44 sending: ping mchn: SEND: ping
2017-08-26 19:03:44 (8 bytes) peer=3
2017-08-26 19:03:44 mchn: RECV: pong, peer=3
2017-08-26 19:03:44 received: pong (8 bytes) peer=3
2017-08-26 19:03:52 mchn: RECV: ping, peer=1
2017-08-26 19:03:52 received: ping (8 bytes) peer=1
2017-08-26 19:03:52 sending: pong mchn: SEND: pong
2017-08-26 19:03:52 (8 bytes) peer=1
2017-08-26 19:03:52 sending: ping mchn: SEND: ping
2017-08-26 19:03:52 (8 bytes) peer=1
2017-08-26 19:03:52 mchn: RECV: pong, peer=1
2017-08-26 19:03:52 received: pong (8 bytes) peer=1
2017-08-26 19:03:53 mchn: RECV: ping, peer=2
2017-08-26 19:03:53 received: ping (8 bytes) peer=2
2017-08-26 19:03:53 sending: pong mchn: SEND: pong
2017-08-26 19:03:53 (8 bytes) peer=2
2017-08-26 19:03:53 sending: ping mchn: SEND: ping
2017-08-26 19:03:53 (8 bytes) peer=2

Could this be something simple I'm using in security settings on AWS? I can connect nodes from inside my own AWS account but no one else can connect. All get the same error. The ports are wide open too.

Ideas?
asked Aug 26, 2017 by matttrainer
edited Aug 26, 2017 by matttrainer

2 Answers

+1 vote
This is likely to be a networking issue. The place to start is to check that the IP address your connecting to (in the node address) is visible from outside AWS. You can also check firewall settings both in the servers and at the AWS console level. Finally you'll find that if you telnet directly to the p2p port from outside, you can check connectivity at the lowest level.
answered Aug 28, 2017 by MultiChain
+3 votes
OK I found the problem, multichain returns the private IP to connect to, not the public one when using Amazon EC2. The private one works fine for internal connections (inside same account) but not outside connections no matter how many ports are opened up.

So instead of using what multichain returns to you when you follow the tutorial which is:

multichaind chainname@PRIVATEIP:PORT

You have to use multichaind chainname@PUBLICIP:PORT then it all works great.
answered Aug 28, 2017 by matttrainer
Yes, this makes sense. Didn't MultiChain show you some other possibilities when it ran, or in EC2 are servers not aware of their public IP addresses?
...