Matt Corallo (OP)
|
|
October 13, 2014, 04:54:21 PM |
|
Under the C++ folder I see a make script for 5 components (including a windows client). I am happy with how the client is used and managed to get it going.
Can you perhaps share how the other components could be used to build a relay network? I am not really proficient at reading c++.
My guesses: relaynetworkproxy -> Connects two relay nodes (both on port 8336). relaynetworkterminator -> Seems to provide the 8334 and 8335 tx and block only feeds? relaynetworkoutbound -> Connects a bitcoind and a something on port 8334? relaynetworkserver -> connects to a trusted bitcoind? Also serves clients? Also connects to something local on port 8334? I kept getting connection refused to the local bitcoind when I ran it.
Happy to assist with a readme on your github if needs be.
proxy/terminator are correct. outbound connects to terminator on 8334 and a remote (untrusted) bitcoind. server connects to a trusted bitcoind to decide which txn to relay, connects to terminator to get/private a data feed from untrusted bitcoinds and also listens on 8336 for relay clients.
|
|
|
|
naplam
|
|
October 13, 2014, 09:16:05 PM |
|
Having issues with the c++ client receiving anything in the last day connecting to us-west without any other changes. Tried restarting and getting repeated Closing relay socket, failed to read message header (104: Connection reset by peer)
Same here with us-east now. Us-west seems to work fine at this time.
|
|
|
|
Matt Corallo (OP)
|
|
October 13, 2014, 11:34:30 PM |
|
Same here with us-east now. Us-west seems to work fine at this time.
Now?
|
|
|
|
norgan
|
|
October 14, 2014, 07:57:17 AM |
|
Same here with us-east now. Us-west seems to work fine at this time.
Now? yup same with Singapore node. both my p2pool nodes have out of cache errors as well.
|
|
|
|
PatMan
|
|
October 14, 2014, 09:00:11 AM |
|
EU node trotting along nicely.......
|
|
|
|
spin
|
|
October 14, 2014, 01:18:19 PM |
|
So to build a relaynetwork between two nodes one could do the following:
Node 1: 10.0.0.1 bitcoind relaynetworkserver relaynetworkproxy 127.0.0.1 10.0.0.2
Node 2: 10.0.0.2 bitcoind relaynetworkserver 127.0.0.1 8333
On node 2 I could also just run the relaynetworkclient also. On node 1 (or 2) I could also add a relaynetworkproxy 127.0.0.1 public.REGION.relay.mattcorallo.com to connect to your network?
Questions: Would the server also updated the local bitcoind with new tx/blocks? Do I need the terminator at each node also? The servers shows less errors when it is running? Also let me know if you are not happy with me trying this out.
|
If you liked this post buy me a beer. Beers are quite cheap where I live! bc1q707guwp9pc73r08jw23lvecpywtazjjk399daa
|
|
|
Matt Corallo (OP)
|
|
October 14, 2014, 08:03:37 PM |
|
yup same with Singapore node. both my p2pool nodes have out of cache errors as well.
Seems to be a bug when run for too long they start disconnecting new peers with that...I'm trying to figure out why, but, for now, they should all work atm.
|
|
|
|
Matt Corallo (OP)
|
|
October 14, 2014, 08:07:06 PM |
|
So to build a relaynetwork between two nodes one could do the following:
Node 1: 10.0.0.1 bitcoind relaynetworkserver relaynetworkproxy 127.0.0.1 10.0.0.2
Node 2: 10.0.0.2 bitcoind relaynetworkserver 127.0.0.1 8333
On node 2 I could also just run the relaynetworkclient also. On node 1 (or 2) I could also add a relaynetworkproxy 127.0.0.1 public.REGION.relay.mattcorallo.com to connect to your network?
Questions: Would the server also updated the local bitcoind with new tx/blocks? Do I need the terminator at each node also? The servers shows less errors when it is running? Also let me know if you are not happy with me trying this out.
Why not just run two relay node clients from your different nodes? If they're on the same network (or very close to each other, ie you can just be running a regular bitcoin p2p connection between them, try the branch at https://github.com/TheBlueMatt/RelayNode/tree/for-w, which has code to connect to multiple local mining pool instances and relay between them and to the relay network, with a full bitcoind receiving blocks/txn from the network.
|
|
|
|
DrHaribo
Legendary
Offline
Activity: 2730
Merit: 1034
Needs more jiggawatts
|
|
October 14, 2014, 08:51:58 PM |
|
Will new versions of the relay client be announced somewhere? (here maybe?)
|
|
|
|
Matt Corallo (OP)
|
|
October 14, 2014, 09:02:33 PM |
|
Will new versions of the relay client be announced somewhere? (here maybe?)
Major updates will, yes.
|
|
|
|
norgan
|
|
October 15, 2014, 02:48:33 AM |
|
yup same with Singapore node. both my p2pool nodes have out of cache errors as well.
Seems to be a bug when run for too long they start disconnecting new peers with that...I'm trying to figure out why, but, for now, they should all work atm. it seems to cause p2pool to fall over as well. thats anecdotal of course so can't say for sure but the syptoms seem to line up on both nodes.
|
|
|
|
Matt Corallo (OP)
|
|
October 15, 2014, 03:53:16 AM |
|
yup same with Singapore node. both my p2pool nodes have out of cache errors as well.
Seems to be a bug when run for too long they start disconnecting new peers with that...I'm trying to figure out why, but, for now, they should all work atm. it seems to cause p2pool to fall over as well. thats anecdotal of course so can't say for sure but the syptoms seem to line up on both nodes. This one makes no sense...The way it was integrated into p2pool was to just kick off a thread and let it connect to bitcoind (not even to p2pool). Unless it hung python or hung your bitcoind, I dont see how this is possible.
|
|
|
|
norgan
|
|
October 15, 2014, 03:55:13 AM |
|
yup same with Singapore node. both my p2pool nodes have out of cache errors as well.
Seems to be a bug when run for too long they start disconnecting new peers with that...I'm trying to figure out why, but, for now, they should all work atm. it seems to cause p2pool to fall over as well. thats anecdotal of course so can't say for sure but the syptoms seem to line up on both nodes. This one makes no sense...The way it was integrated into p2pool was to just kick off a thread and let it connect to bitcoind (not even to p2pool). Unless it hung python or hung your bitcoind, I dont see how this is possible. yeah liek i said anecdotal, i wanted to be clear on that. I'll do some more testing.
|
|
|
|
-ck
Legendary
Offline
Activity: 4242
Merit: 1644
Ruu \o/
|
|
October 15, 2014, 09:25:18 AM |
|
Running of the c++ client now fails to run on linux due to the position of the -pthread linking with the error: terminate called after throwing an instance of 'std::system_error' what(): Enable multithreading to use std::thread: Operation not permitte
Repositioning the -pthread here makes it work: g++ -std=c++11 -Wall -I. -I/usr/include ./client.cpp -pthread ./flaggedarrayset.cpp ./utils.cpp ./p2pclient.cpp ./crypto/sha2.cpp -o relaynetworkclient Probably should at least add -O2 to default build too
|
Developer/maintainer for cgminer, ckpool/ckproxy, and the -ck kernel 2% Fee Solo mining at solo.ckpool.org -ck
|
|
|
naplam
|
|
October 15, 2014, 12:15:04 PM |
|
yup same with Singapore node. both my p2pool nodes have out of cache errors as well.
Seems to be a bug when run for too long they start disconnecting new peers with that...I'm trying to figure out why, but, for now, they should all work atm. Are you hitting the maximum sockets limit or something? maybe you could restart them automatically every day or so for the time being
|
|
|
|
Matt Corallo (OP)
|
|
October 16, 2014, 02:31:25 AM |
|
Are you hitting the maximum sockets limit or something? maybe you could restart them automatically every day or so for the time being
No, the issue y'all are seeing is that, if the thread handling the trusted bitcoind hangs or otherwise dies, it cant do its async connection reaping and, thus, people get disconnected as duplicate connections from the same IP if their connection gets reset somehow...Of course to fix this I need to actually figure out why its hanging/deadlocking/dying...
|
|
|
|
Matt Corallo (OP)
|
|
October 16, 2014, 02:43:43 AM |
|
Running of the c++ client now fails to run on linux due to the position of the -pthread linking with the error: terminate called after throwing an instance of 'std::system_error' what(): Enable multithreading to use std::thread: Operation not permitte
Repositioning the -pthread here makes it work: g++ -std=c++11 -Wall -I. -I/usr/include ./client.cpp -pthread ./flaggedarrayset.cpp ./utils.cpp ./p2pclient.cpp ./crypto/sha2.cpp -o relaynetworkclient Probably should at least add -O2 to default build too Huh? Which branch are you building from??? Master is https://github.com/TheBlueMatt/RelayNode/blob/master/c%2B%2B/make.sh which (unless you run with ./make test) has DEFINES set to -O2 and -flto, and -pthread is before any code?
|
|
|
|
-ck
Legendary
Offline
Activity: 4242
Merit: 1644
Ruu \o/
|
|
October 16, 2014, 02:47:30 AM |
|
Running of the c++ client now fails to run on linux due to the position of the -pthread linking with the error: terminate called after throwing an instance of 'std::system_error' what(): Enable multithreading to use std::thread: Operation not permitte
Repositioning the -pthread here makes it work: g++ -std=c++11 -Wall -I. -I/usr/include ./client.cpp -pthread ./flaggedarrayset.cpp ./utils.cpp ./p2pclient.cpp ./crypto/sha2.cpp -o relaynetworkclient Probably should at least add -O2 to default build too Huh? Which branch are you building from??? Master is https://github.com/TheBlueMatt/RelayNode/blob/master/c%2B%2B/make.sh which (unless you run with ./make test) has DEFINES set to -O2 and -flto, and -pthread is before any code? Oops, I didn't spot the defines. However -pthread has to be after client.cpp for it to work.
|
Developer/maintainer for cgminer, ckpool/ckproxy, and the -ck kernel 2% Fee Solo mining at solo.ckpool.org -ck
|
|
|
Matt Corallo (OP)
|
|
October 16, 2014, 03:08:44 AM |
|
Oops, I didn't spot the defines. However -pthread has to be after client.cpp for it to work.
Oh after, ok, willdo.
|
|
|
|
naplam
|
|
October 16, 2014, 11:23:01 AM |
|
yep, -phread after works
|
|
|
|
|