0

I try to create a local private testnet network of ethereum. It seems like when I run two nodes on the same computer(without vm), it uses the same port and ip address although I set different port for each one of them. Is it possible to run a couple of nodes on the same computer, or should I use a vm for that? It also showed me that one of the nodes has 8 peers although I set only 2 nodes. how is it possible?

Thank you

adi
  • 197
  • 1
  • 10

1 Answers1

0

I don't know what are the mandatory options for your node but for the networking only, you can set the port with the following option

  --port value          Network listening port (default: 30303)

If you are connected to 8 peers but you only have 2, I think you are running your geth on a public networkid

--networkid value Network identifier (integer, 1=Frontier, 2=Morden (disused), 3=Ropsten, 4=Rinkeby) (default: 1)

You can find all the available options on this page

oktapodia
  • 467
  • 2
  • 15
  • I see, so the public network is on port 30303? as a network identifier should I choose Ropsten? – adi May 14 '18 at 03:15
  • If you want to have a private network (only with your nodes), you have to choose something upper than that, this article can help you a lot https://souptacular.gitbooks.io/ethereum-tutorials-and-tips-by-hudson/content/private-chain.html – oktapodia May 14 '18 at 10:52