Stake pool course - relay and core nodes not connecting

I’m still going through the Stake pool course. My relay node is not talking to the core node and vice versa.

#Relay node topology file. I got the ip address from AWS EC2->corenode->Public IPv4 address
[ec2-user@ip-xxx-xx-x-xxx relay]$ cat testnet-topology.json
{
“Producers”: [
{
“addr”: “core ipaddress”,
“port”: 3000,
“valency”: 1
}
]
}

#Core node topology file. I got the ip address from AWS EC2->relaynode->Public IPv4 address
[ec2-user@ip-xxx-xx-x-xxx pool]$ cat testnet-topology.json
{
“Producers”: [
{
“addr”: “relaynode ipaddress”,
“port”: 3000,
“valency”: 1
}
]
}

First I start the relay node
cd relay
cardano-node run
–topology testnet-topology.json
–database-path db
–socket-path db/node.socket
–host-addr 0.0.0.0
–port 3000
–config testnet-config.json

#I see the messages below saying failed to start subscriptions. I guess it’s not connecting to core node because it’s not started yet.
[ip-172-3:cardano.node.IpSubscription:Info:54] [2021-04-22 15:02:14.64 UTC] IPs: 0.0.0.0:0 [core ipaddress:3000] Skipping peer core ipaddress:3000
[ip-172-3:cardano.node.IpSubscription:Error:54] [2021-04-22 15:02:14.64 UTC] IPs: 0.0.0.0:0 [core ipaddress:3000] Failed to start all required subscriptions
[ip-172-3:cardano.node.IpSubscription:Info:54] [2021-04-22 15:02:15.64 UTC] IPs: 0.0.0.0:0 [core ipaddress:3000] Restarting Subscription after 1.001414497s desired valency 1 current valency 0

#then I start the core node
cd
cardano-node run
–topology pool/testnet-topology.json
–database-path pool/db
–socket-path pool/db/node.socket
–host-addr 0.0.0.0
–port 3000
–config pool/testnet-config.json
–shelley-kes-key pool-keys/kes.skey
–shelley-vrf-key pool-keys/vrf.skey
–shelley-operational-certificate pool-keys/node.cert

#I get similar messages even though relay node is running.
[ip-172-3:cardano.node.IpSubscription:Info:54] [2021-04-22 15:08:38.53 UTC] IPs: 0.0.0.0:0 [relay ipaddress:3000] Skipping peer relay ipaddress:3000
[ip-172-3:cardano.node.IpSubscription:Error:54] [2021-04-22 15:08:38.53 UTC] IPs: 0.0.0.0:0 [relay ipaddress:3000] Failed to start all required subscriptions
[ip-172-3:cardano.node.IpSubscription:Info:54] [2021-04-22 15:08:39.53 UTC] IPs: 0.0.0.0:0 [relay ipaddress:3000] Restarting Subscription after 1.002236912s desired valency 1 current valency 0

It doesn’t look like they’re connecting. Appreciate any ideas.

Hi!

so your topology file contains empty string - "" - in the addr field?

no, the Relay node topology file contains the core node ip address and the Core node topology file contains the relay node ip address. When I made the post above, I had entered the less than/greater than signs and the whole thing disapperred. I’ll edit the initial post.

image

First - extend the relay topology file with IOHK remote server to able to start syncing

{
  "Producers": [
    {
      "addr": "relays-new.cardano-testnet.iohkdev.io",
      "port": 3001,
      "valency": 2
    },
    {
      "addr": "<producer IP>",
     "port": 3000,
     "valency": 1
    }
  ]
}

so restart the relay with this topology and check the logs of it…

The relay node seems to be syncing now, but I still see the error message.

Relay topology
image

I tried starting the core node, but the error still remains. Do I need to also extend the core topology with the IOHK remote server?

Core topology
image

1 Like

strange - why the IP of the block producing converted to 0.0.0.0:0 in the logs…
could you try it with "valency": 2 at the producer address as well?

Node seems to be synching on port 3001 for the IOHK server. But still an error for port 3000

Relay topology
image

In the cardano-node run statement, should the ip address for host-addr be 0.0.0.0, the Public IPv4 address mentioned on the AWS EC2 site, or the one specified in the ifconfig command?

Same question for the ipaddress mentioned in the relay topology file for producer IP. Should it be the AWS Public IPv4 address or the one mentioned in ifconfig.

Ahh, ok - so yes, host-addr should be 0.0.0.0 - means that it will listens on all interface.
so, first test the connection towards relay from block production node: netcat -vnz 18.218.8.16 3000

I think (but not sure) that it is working. I made the following changes:

  • host-addr 0.0.0.0 in the cardano-node run statement
  • change to private ip address in topology file (since both nodes are in same AWS account)
  • open port 3000 in AWS (It is closed by default)

Then I started both the nodes and let it sync for a while.

image

Does the statement ‘Left FetchDeclineChainNotPlausible’ mean that it’s not working correctly?

Great!

Since it is an Info category the node works fine - I dont know what that log means, but mainly you need to focus on warning and error