Blockchain.info http://blockchain.info/connected-nodes shows a list of nodes it is connected to. Is it possible for me to add them as a node for connection?
Asked
Active
Viewed 2,868 times
12
-
1Presumably it's possible, but it may be difficult to figure out the IP address of their bitcoin client (which may or may not be the IP address of their main server or even their RPC API). – Daniel H Aug 28 '12 at 04:12
1 Answers
6
As mentioned in Daniel's comment, if you are trying to connect to the Bitcoin-client that gathers the information for the Blockchain.info site this is not trivial as the IP does not match the one of the website.
If you are just interested in adding the same nodes the site is connected to, that's no problem.
With Linux or OS X you'd do something like this:
curl -s https://blockchain.info/connected-nodes | \
grep -oE '([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)' | \
sort -u
which gives you a sorted list of IPs to connect to. If you want a complete string to just append to your bitcoind client as options then try this:
curl -s https://blockchain.info/connected-nodes | \
grep -oE '([0-9]+\.[0-9]+\.[0-9]+\.[0-9]+)' | \
sort -u | \
sed 's/.*/-addnode=&/g' | \
tr '\n' ' '
this additionally adds the -addnode= prefix to each address and joins the line.
-
currently the list from https://blockchain.info/connected-nodes is 0 (zero) – miguelmorales85 Oct 01 '17 at 14:22
-
1