Bitcoin Forum

Bitcoin => Bitcoin Technical Support => Topic started by: allgoodthings1 on November 30, 2014, 02:03:18 AM



Title: Running bitcoind on >1 computer, same network
Post by: allgoodthings1 on November 30, 2014, 02:03:18 AM
I want to run a full node of bitcoind on two or more computers that I have on my home network.  All are connected to one Linksys E2500 router.

One Port, One Computer: The problem is that my router settings will only let me forward Port 8333 to one IP address (or computer).  It will not let me set more than one IP to forward to the same Port 8333.

I'm sure there must be an easy way around this [i.e., in layman's language], but I cannot find it anywhere.  Can someone help me with this?


Title: Re: Running bitcoind on >1 computer, same network
Post by: Vod on November 30, 2014, 02:35:54 AM
http://lmgtfy.com/?q=how+to+port+forward+to+more+than+one+ip

Hope that helps.  :)


Title: Re: Running bitcoind on >1 computer, same network
Post by: Foxpup on November 30, 2014, 05:03:44 AM
One Port, One Computer: The problem is that my router settings will only let me forward Port 8333 to one IP address (or computer).  It will not let me set more than one IP to forward to the same Port 8333.
An explanation of port forwarding is in order. When you say IP address here, you're referring to private IP addresses (reachable only from your LAN, not the Internet). When other people connect to your Bitcoin node, they are connecting to your public IP address, and you only have one public IP address (that of the router). As a result, all incoming connections end up connecting to your router, not any of your computers, which obviously isn't what you want. This is where port forwarding comes in. With port forwarding, you tell your router that connections to your public IP on a particular public port should be forwarded to one of your computers, on a particular private IP and port.

Now, it is nonsensical to try to forward a connection to two computers simultaneously. If you did, the client connecting to you would receive two simultaneous responses to each request, and fail hilariously if those responses conflicted in even the most minor way. It won't work at all, and any sane configuration software won't let you try. Thus, if you have two computers accepting incoming connections, they must use two different public ports, so that the router can know which connections go with which computer.

The bigger question is, what are you really trying to do? (http://mywiki.wooledge.org/XyProblem) Running two Bitcoin nodes on a single public IP is a strange configuration, and I'm not sure how such a configuration would be useful.


Title: Re: Running bitcoind on >1 computer, same network
Post by: allgoodthings1 on November 30, 2014, 11:56:44 AM
The bigger question is, what are you really trying to do? (http://mywiki.wooledge.org/XyProblem) Running two Bitcoin nodes on a single public IP is a strange configuration, and I'm not sure how such a configuration would be useful.
Asked and answered: "I want to run a full node of bitcoind on two or more computers that I have on my home network."  Why support the network by running a full node on only one computer, if I have more than one computer on my network, all running 24/7 and capable of running their own instance of bitcoind?  Aren't two or three or four contributing full nodes better than one?  That shouldn't be a "strange configuration" for a lot of folks hereabouts, unless it's impossible to set up.


Title: Re: Running bitcoind on >1 computer, same network
Post by: shorena on November 30, 2014, 01:02:04 PM
The bigger question is, what are you really trying to do? (http://mywiki.wooledge.org/XyProblem) Running two Bitcoin nodes on a single public IP is a strange configuration, and I'm not sure how such a configuration would be useful.
Asked and answered: "I want to run a full node of bitcoind on two or more computers that I have on my home network."  Why support the network by running a full node on only one computer, if I have more than one computer on my network, all running 24/7 and capable of running their own instance of bitcoind?  Aren't two or three or four contributing full nodes better than one?  That shouldn't be a "strange configuration" for a lot of folks hereabouts, unless it's impossible to set up.

More than one node per external IP is not helping and while its possible with custom ports, I think its better you run a single node with as much connections as the line can handle than multiple nodes that have the same IP.

PS: another option would be to use VPNs for each node, but you would still be limited by your ISPs bandwith.


Title: Re: Running bitcoind on >1 computer, same network
Post by: Newar on November 30, 2014, 01:52:24 PM
Could you have the second one on TOR only?


Title: Re: Running bitcoind on >1 computer, same network
Post by: allgoodthings1 on November 30, 2014, 10:22:12 PM
PS: another option would be to use VPNs for each node, but you would still be limited by your ISPs bandwith.
Thanks, Shore.  I am more than fine with my ISP's bandwidth limitations.  So what of this VPN option?

I have PIA for my VPN service (with up to four connections on the account), and I can find my connecting address on any of my computers by using speedtest.net   For example, one computer right now is showing a VPN connection on 66.55.144.250, via Choopa LLC in London.  Is there some way I can use this (or other information) to set up and run a beneficial full node on a second computer?


Title: Re: Running bitcoind on >1 computer, same network
Post by: Foxpup on December 01, 2014, 03:47:04 AM
Aren't two or three or four contributing full nodes better than one?
Better? Better for what? Not for bandwidth: your multiple nodes have the same combined bandwidth as you would have if you were running a single node. Not for redundancy: if your Internet connection or power fails, all of your nodes will fail simultaneously. What specific benefit do you hope to gain by this configuration?


Title: Re: Running bitcoind on >1 computer, same network
Post by: shorena on December 01, 2014, 08:46:34 AM
PS: another option would be to use VPNs for each node, but you would still be limited by your ISPs bandwith.
Thanks, Shore.  I am more than fine with my ISP's bandwidth limitations.  So what of this VPN option?

I have PIA for my VPN service (with up to four connections on the account), and I can find my connecting address on any of my computers by using speedtest.net   For example, one computer right now is showing a VPN connection on 66.55.144.250, via Choopa LLC in London.  Is there some way I can use this (or other information) to set up and run a beneficial full node on a second computer?

Not sure how your VPN Serivce handles this, but the basic idea is:

Start the machine (A), connect to VPN (VPN_A) with that machine (do not use the router), start bitcoind afterwards. This would result in A to have the external IP of VPN_A. Youd have to configure the VPN in a way to either just forward everything to the connected client and configure the local firewall as if it was a internet server or configure that port 8333 will be forwarded on VPN_A to machine A. Machine B could connect normally via your router and machine C would use VPN_C, this can be the same service as long as the external IP is different and the service allows you to either just dump all incomming traffic on the client or configure portforwarding based on the clients ID.
Another way would be to use the Tor proxy for one of the nodes. AFAIK this has similar results as the VPN.

The question of Foxpup still stands though. A single big node is as beneficial as 2 smaller nodes IMHO.


Title: Re: Running bitcoind on >1 computer, same network
Post by: allgoodthings1 on December 01, 2014, 11:34:06 AM
Thanks to all.  And to all a good night.


Title: Re: Running bitcoind on >1 computer, same network
Post by: tl121 on December 06, 2014, 03:42:08 AM
I want to run a full node of bitcoind on two or more computers that I have on my home network.  All are connected to one Linksys E2500 router.

One Port, One Computer: The problem is that my router settings will only let me forward Port 8333 to one IP address (or computer).  It will not let me set more than one IP to forward to the same Port 8333.

I'm sure there must be an easy way around this [i.e., in layman's language], but I cannot find it anywhere.  Can someone help me with this?

Unless your home network has unusually good bandwidth to the Internet it is unlikely that you could provide much service to the bitcoin network by running more than one bitcoin node.  At present, I don't have any node mapped to receive incoming connections.  Given my slow upload DSL bandwidth anyone who happened to connect to me to download the block chain would have to wait many days due to my limited bandwidth, so I figure I would actually be doing them a disservice.  A better way to service the network from a slow connection is to seed the bootsrap.dat torrent.

If you want to run multiple bitcoin nodes on your LAN for various reasons (such as testing), then I suggest dedicating a stable machine to be your "front" machine.  If you want that one to serve the network, then map 8333 to it at your router. Your other bitcoin nodes can have a "connect=192.168.1.xx" command in their config file.  That way they won't put any burden on the network. Also, they can clone the blockchain quickly over your LAN.