# Connection between core node and relay node fail

**URL:** <https://forum.cardano.org/t/connection-between-core-node-and-relay-node-fail/66487>\
**Category:** Setup a Stake Pool\
**Created:** [7 July 2021 10:55 UTC](https://forum.cardano.org/t/connection-between-core-node-and-relay-node-fail/66487 "2021-07-07T10:55:49Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![NguyenCongVn](https://avatars.discourse-cdn.com/v4/letter/n/41988e/32.png) [@NguyenCongVn](https://forum.cardano.org/u/NguyenCongVn)\
**Post date:** [7 July 2021 10:55 UTC](https://forum.cardano.org/t/connection-between-core-node-and-relay-node-fail/66487/1 "2021-07-07T10:55:49Z")

</div>

Hi everyone!  
I have learnt how to setup stake pool in this course `https://cardano-foundation.gitbook.io/stake-pool-course/stake-pool-guide/stake-pool/corenode-start`

I using Amazon EC2 to host there nodes. But when i run core node, it’s fail for relay node to connect to core node.

In relay node, it says :

> [ip-172-3:cardano.node.IpSubscription:Info:165] [2021-07-07 10:51:30.10 UTC] IPs: 0.0.0.0:0 [52.0.169.106:3001] Trying to connect to 52.0.169.106:3001  
> [ip-172-3:cardano.node.IpSubscription:Notice:165] [2021-07-07 10:51:30.10 UTC] IPs: 0.0.0.0:0 [52.0.169.106:3001] Waiting 0.025s before attempting a new connection  
> [ip-172-3:cardano.node.IpSubscription:Info:14287] [2021-07-07 10:51:30.10 UTC] IPs: 0.0.0.0:0 [52.0.169.106:3001] Connection Attempt Start, destination 52.0.169.106:3001  
> [ip-172-3:cardano.node.IpSubscription:Notice:14287] [2021-07-07 10:51:30.10 UTC] IPs: 0.0.0.0:0 [52.0.169.106:3001] Connection Attempt End, destination 52.0.169.106:3001 outcome: ConnectSuccessLast  
> [ip-172-3:cardano.node.IpSubscription:Info:14287] [2021-07-07 10:51:30.14 UTC] IPs: 0.0.0.0:0 [52.0.169.106:3001] Closed socket to 52.0.169.106:3001  
> [ip-172-3:cardano.node.IpSubscription:Info:165] [2021-07-07 10:51:31.14 UTC] IPs: 0.0.0.0:0 [52.0.169.106:3001] Restarting Subscription after 1.045980199s desired valency 1 current valency 0

I think it needs to sync blockchain but nothing new. In core node , it’s failed too

> [ip-172-3:cardano.node.LeadershipCheck:Info:793] [2021-07-07 10:47:09.01 UTC] {“credentials”:“Cardano”,“kind”:“TraceStartLeadershipCheck”,“delegMapSize”:1464,“slot”:31285613,“chainDensity”:3.4998138e-2,“utxoSize”:78469}  
> [ip-172-3:cardano.node.ForgeTime:Info:793] [2021-07-07 10:47:09.01 UTC] fromList   
> [ip-172-3:cardano.node.ForgeTime:Info:793] [2021-07-07 10:47:09.01 UTC] fromList   
> [ip-172-3:cardano.node.ForgeTime:Info:793] [2021-07-07 10:47:09.01 UTC] fromList   
> [ip-172-3:cardano.node.Forge:Error:793] [2021-07-07 10:47:09.01 UTC] fromList [(“credentials”,String “Cardano”),(“val”,Object (fromList [(“kind”,String “TraceNoLedgerView”),(“slot”,Number 3.1285613e7)]))]  
> [ip-172-3:cardano.node.ForgeTime:Info:793] [2021-07-07 10:47:09.01 UTC] fromList

This is the topology.json file in relay node:

> { “Producers”: [{ “addr” : “52.0.169.106”, “port” : 3001, “valency” : 1 }, { “addr”: “[relays-new.cardano-testnet.iohkdev.io](http://relays-new.cardano-testnet.iohkdev.io)”, “port”: 3000, “continent”: “Europe”, “state”: “GB”, “valency” : 1 } ] }

And the topology.json file in core node:

> {  
> “Producers”: [  
> {  
> “addr”: “3.225.159.56”,  
> “port”: 3001,  
> “valency”: 1  
> }  
> ]  
> }

When I check connection between two node by telnet. It’s successed.

Please help me solve this problem!

---

<div class="post-metadata">

**Author:** ![Xpriens](https://sea1.discourse-cdn.com/flex023/user_avatar/forum.cardano.org/xpriens/32/45030_2.png) [@Xpriens](https://forum.cardano.org/u/Xpriens)\
**Post date:** [7 July 2021 12:02 UTC](https://forum.cardano.org/t/connection-between-core-node-and-relay-node-fail/66487/2 "2021-07-07T12:02:21Z")

</div>

Topology looks fine, let them sync first and check again.

---

<div class="post-metadata">

**Author:** ![NguyenCongVn](https://avatars.discourse-cdn.com/v4/letter/n/41988e/32.png) [@NguyenCongVn](https://forum.cardano.org/u/NguyenCongVn)\
**Post date:** [7 July 2021 12:38 UTC](https://forum.cardano.org/t/connection-between-core-node-and-relay-node-fail/66487/3 "2021-07-07T12:38:37Z")

</div>

I run the nodes again but it still failed

This message is from relay node :

> [ip-172-3:cardano.node.IpSubscription:Error:496] [2021-07-07 12:37:22.28 UTC] IPs: 0.0.0.0:0 [52.0.169.106:3001] Application Exception: 52.0.169.106:3001 ExceededTimeLimit (ChainSync (Header (HardForkBlock (‘: \* ByronBlock (’: \* (ShelleyBlock (ShelleyEra StandardCrypto)) (‘: \* (ShelleyBlock (ShelleyMAEra ‘Allegra StandardCrypto)) (’: \* (ShelleyBlock (ShelleyMAEra ‘Mary StandardCrypto)) (’ \*))))))) (Tip HardForkBlock (’: \* ByronBlock (‘: \* (ShelleyBlock (ShelleyEra StandardCrypto)) (’: \* (ShelleyBlock (ShelleyMAEra ‘Allegra StandardCrypto)) (’: \* (ShelleyBlock (ShelleyMAEra ‘Mary StandardCrypto)) (’ \*))))))) (ServerAgency TokNext TokMustReply)  
> [ip-172-3:cardano.node.ErrorPolicy:Notice:174] [2021-07-07 12:37:22.28 UTC] IP 52.0.169.106:3001 ErrorPolicySuspendConsumer (Just (ApplicationExceptionTrace ExceededTimeLimit (ChainSync (Header (HardForkBlock (‘: \* ByronBlock (’: \* (ShelleyBlock (ShelleyEra StandardCrypto)) (‘: \* (ShelleyBlock (ShelleyMAEra ‘Allegra StandardCrypto)) (’: \* (ShelleyBlock (ShelleyMAEra ‘Mary StandardCrypto)) (’ \*))))))) (Tip HardForkBlock (’: \* ByronBlock (‘: \* (ShelleyBlock (ShelleyEra StandardCrypto)) (’: \* (ShelleyBlock (ShelleyMAEra ‘Allegra StandardCrypto)) (’: \* (ShelleyBlock (ShelleyMAEra ‘Mary StandardCrypto)) (’ \*))))))) (ServerAgency TokNext TokMustReply))) 20s

.This message is from core node :

> [ip-172-3:cardano.node.LeadershipCheck:Info:157] [2021-07-07 12:32:50.00 UTC] {“credentials”:“Cardano”,“kind”:“TraceStartLeadershipCheck”,“delegMapSize”:1997,“slot”:31291954,“chainDensity”:2.9968629e-2,“utxoSize”:214072}  
> [ip-172-3:cardano.node.ForgeTime:Info:157] [2021-07-07 12:32:50.00 UTC] fromList   
> [ip-172-3:cardano.node.ForgeTime:Info:157] [2021-07-07 12:32:50.00 UTC] fromList   
> [ip-172-3:cardano.node.ForgeTime:Info:157] [2021-07-07 12:32:50.00 UTC] fromList   
> [ip-172-3:cardano.node.ForgeTime:Info:157] [2021-07-07 12:32:50.00 UTC] fromList

---

<div class="post-metadata">

**Author:** ![NguyenCongVn](https://avatars.discourse-cdn.com/v4/letter/n/41988e/32.png) [@NguyenCongVn](https://forum.cardano.org/u/NguyenCongVn)\
**Post date:** [7 July 2021 12:55 UTC](https://forum.cardano.org/t/connection-between-core-node-and-relay-node-fail/66487/4 "2021-07-07T12:55:06Z")

</div>

I run with this command :  
relay node :

```auto
 cardano-node run \
 --topology testnet-topology.json \
 --database-path db \
 --socket-path db/node.socket \
 --host-addr 0.0.0.0 \
 --port 3001 \
 --config testnet-config.json\

```

core node :

> cardano-node run   
> –topology testnet-topology.json   
> –database-path ./db   
> –socket-path ./db/node.socket   
> –host-addr 0.0.0.0   
> –port 3001   
> –config testnet-config.json   
> –shelley-kes-key kes.skey   
> –shelley-vrf-key vrf.skey   
> –shelley-operational-certificate node.cert

---

<div class="post-metadata">

**Author:** ![Xpriens](https://sea1.discourse-cdn.com/flex023/user_avatar/forum.cardano.org/xpriens/32/45030_2.png) [@Xpriens](https://forum.cardano.org/u/Xpriens)\
**Post date:** [7 July 2021 18:43 UTC](https://forum.cardano.org/t/connection-between-core-node-and-relay-node-fail/66487/5 "2021-07-07T18:43:00Z")

</div>

Both run commands seem correct. Your topology files are correct.  
Are your nodes fully synced?
