In this outdated but seemingly comprehensive guide to creating an altcoin fork of bitcoin they make special mention of the need to change the rpc port.

Although in the intervening time the file names have changed the variables remain so I think this advice is still valid.

What is the purpose of these ports? What information do they transmit? Why are they there and why must we change them when creating a new network?

Step 4- Ports(required)

a) bitcoinrpc.cpp 
    -change RPC port.

    ip::tcp::endpoint endpoint(bindAddress, GetArg("-rpcport", 55883));

    if (!d.connect(GetArg("-rpcconnect", ""), GetArg("-rpcport", "55883")))

b) init.cpp
   -change RPC port

    -rpcport= " + _("Listen for JSON-RPC connections on  (default: 55883)") + "\n" +

    -change Testnet and Common port(P2P).

    -port= " + _("Listen for connections on  (default: 55884 or testnet: 45884)") + "\n" +

c) protocol.h

  -Testnet and P2P port again.

    return testnet ? 45883 : 55884;

There's no reason why you need to change them if you're not concerned about running Bitcoin and an altcoin on the same device/IP address.

| improve this answer | |

The RPC port is the port used for tools such as bitcoin-cli to connect to the node and execute administrative commands (this is why it's bound by default to localhost /

The reason it should be changed is so that it doesn't create conflicts if you wanted to run your altcoin on the same system as a bitcoin node, since only one can use a given port.

| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.