I am having trouble creating a private ethereum network on AWS. I have enabled TCP/UDP for the desired ports in the firewall in AWS.
On one node A(aws instance) I start the geth console by making use of a custom genesis file using command
geth --datadir="ethdata" init fresh.json
I then execute geth on the same node A using the following command
geth --datadir="ethdata" --networkid 1234 console
Now I startup another AWS instance node B. Here to I initilize geth using the custom genesis file
geth --datadir="ethdata" init fresh.json
And then start geth console in node B using
geth --datadir="ethdata" --networkid 1234 console
And then in node B I execute the following command
>admin.addPeer("<enode of the nodeA")
The above command returns me true
However admin.peers in both node A and node B comes up with empty strings.
Occasionally I am able to view other peers connected to either of these nodes (probably because I am executing geth without --nodiscover option), but I am still unsuccessful in establishing a peer-peer connection between my two nodes.
Please advise what could I be going wrong.
PS: I have tried with the bootnode option as well, but still no success.
Question: Can I have just bootnode running on node A and then node B having a geth console running that connects to the enode using bootnodes "enode url" ? Although I did try this, it still didnt result in a proper peer-peer connection.