Setting up multiple bitcoin machines behind NAT

6 messages BitcoinTalk foobar, Satoshi Nakamoto, Xunie, Dominic Sayers, krepta3000 February 16, 2010 — June 26, 2011
foobar February 16, 2010 00:35 UTC Source ·

Hello,

well the title says it all. I want to set up multiple bitcoin machines behind NAT. For this it reason would be nice, if one could choose an other port than 8333, which I guess would have other nice side effects. Maybe someone uses this port for something else or maybe it isn’t possible to set up port forwarding to this port for one reason or another.

Or is there an other way one should go?

Greetings, foobar

Satoshi Nakamoto February 16, 2010 01:34 UTC Source ·

Right now there isn’t a port number setting to do that.  It’s a feature yet to be implemented.  You can only set up your NAT to port-forward to one of the computers.  (I said something earlier about NAT port translation, but that wouldn’t work, other nodes wouldn’t know to connect to that port)

If you want, as a small optimization, you could run the rest of your computers as: bitcoin -connect=

so they get all their network communication from the first computer and don’t all connect over the net individually for the same information.  This saves bandwidth, although it doesn’t use much bandwidth to begin with, so it wouldn’t really matter unless you had tons of computers.

For redundancy in case the first computer goes down, you could have two that connect out and the rest connect to both of them.  The first two are run normally, the rest are run like: bitcoin -connect= -connect=

Xunie April 8, 2010 20:06 UTC Source ·
Quote from: satoshi on February 16, 2010, 1:34:56 AM UTC

Right now there isn’t a port number setting to do that. It’s a feature yet to be implemented.

So, if I somehow I forwarded port router:8333 to bitcoinhost1:8333 and router:8334 to bitcoinhost2:8333, we get undefined behavior? Because that seems like trivial to me, to keep track of port numbers in any p2p app.

Xunie May 17, 2010 19:11 UTC Source ·
Quote from: Xunie on April 08, 2010, 8:06:37 PM UTC
Quote from: satoshi on February 16, 2010, 1:34:56 AM UTC

Right now there isn’t a port number setting to do that. It’s a feature yet to be implemented.

So, if I somehow I forwarded port router:8333 to bitcoinhost1:8333 and router:8334 to bitcoinhost2:8333, we get undefined behavior? Because that seems like trivial to me, to keep track of port numbers in any p2p app.

Sorry about that, must’ve been drunk when I wrote that. 😕

Dominic Sayers May 18, 2011 12:07 UTC Source ·
Quote from: satoshi on February 16, 2010, 1:34:56 AM UTC

You can only set up your NAT to port-forward to one of the computers.

For redundancy in case the first computer goes down, you could have two that connect out and the rest connect to both of them. The first two are run normally, the rest are run like: bitcoin -connect= -connect=

I agree with the first statement (you can only forward the port to one computer).

Therefore I do not understand the second statement. How does this achieve redundancy? Only one of the two will receive forwarded traffic. If that one goes down then you’ve lost the connection (AFAIK).

Am I being dumb?

krepta3000 June 26, 2011 14:04 UTC Source ·
Quote from: Dominic Sayers on May 18, 2011, 12:07:13 PM UTC
Quote from: satoshi on February 16, 2010, 1:34:56 AM UTC

You can only set up your NAT to port-forward to one of the computers.

For redundancy in case the first computer goes down, you could have two that connect out and the rest connect to both of them. The first two are run normally, the rest are run like: bitcoin -connect= -connect=

I agree with the first statement (you can only forward the port to one computer).

Therefore I do not understand the second statement. How does this achieve redundancy? Only one of the two will receive forwarded traffic. If that one goes down then you’ve lost the connection (AFAIK).

Am I being dumb?

I can think of how it can be redundant, if the second connect command is connecting to a known, usually running, node Outside your own network, a public IP address. There, redundancy achieved.