thebluematt / relaynode Goto Github PK
View Code? Open in Web Editor NEWA block-compressing fast relay server/client
Home Page: http://bitcoinrelaynetwork.org
License: MIT License
A block-compressing fast relay server/client
Home Page: http://bitcoinrelaynetwork.org
License: MIT License
Relay Network code See http://bitcoinrelaynetwork.org/ for information on the network
Closing relay socket, failed to read message header (10054: Unknown error)
Closing relay socket, failed to read message header (10054: Unknown error)
Closing relay socket, failed to read message header (10054: Unknown error)
Closing relay socket, failed to read message header (10054: Unknown error)
Closing relay socket, failed to read message header (10054: Unknown error)
Closing relay socket, failed to read message header (10054: Unknown error)
Closing relay socket, failed to read message header (10054: Unknown error)
Closing relay socket, failed to read message header (10054: Unknown error)
Closing relay socket, failed to read message header (10054: Unknown error)
Closing relay socket, failed to read message header (10054: Unknown error)
Closing relay socket, failed to read message header (10054: Unknown error)
Closing relay socket, failed to read message header (10054: Unknown error)
Will restart the client but wanted to post this. c++ client on windows.
[ERROR] Failed to execute goal on project RelayNode: Could not resolve dependencies for project RelayNode:RelayNode:jar:1.0-SNAPSHOT: Could not find artifact com.google:bitcoinj:jar:0.12-SNAPSHOT_nodelay in central (https://repo.maven.apache.org/maven2) -> [Help 1]
I just pulled the Oct 20th commits including: 9b326ec
After making the new C++ client node and starting it, all seems fine from the client, but my -nowallet bitcoin node used for mining on p2pool sees an issue. The relay client connects without a User Agent and NA ping time, and then after a minute or so disconnects totally (no longer on peer list). The node running log shows no issues. Previous version connected with an identifying User Agent and stayed connected.
Dears,
Just wonder if I can create a new relay node in KR(South Korea) for public use purpose.
if possible, please let me know how to deal with?
('Unknown error processing data from relay node:', error('unpack str size too short for format',))
('Lost connect to relay node:', error(61, 'Connection refused'))
('Failed to send to relay node: ', error(32, 'Broken pipe'))
('Lost connect to bitcoind node:', error(57, 'Socket is not connected'))
Connected to bitcoind with protocol version 70002
Finished connect handshake with bitcoind
The client then hangs, connects back to bitcoind but no longer relays any information.
client.cpp should grow an RPCClient to the same bitcoind and use that to send non-oob txn to the server.
...so that it can deliver them later, keeping the bitcoind sigcache warm.
getblocktemplate would be nice, though that might be too slow? getrawmempool and doing our own sorting really sucks, though.
I've been trying to compile the C++ client on a Mac and keep encountering errors.
It started first with a file not found for endian.h but that was easily fixed by setting an alias for the usual /usr/include location with the Mac location of /usr/include/machine for endian.h header file.
But now I'm getting a bunch of errors like this:
./client.cpp:162:10: error: use of undeclared identifier 'le16toh'
return le16toh((*(it-1) << 8) | *(it-2));
^
./client.cpp:165:10: error: use of undeclared identifier 'le32toh'
return le32toh((*(it-1) << 24) | (*(it-2) << 16) | (*(it-3) << 8) | *(it-4));
^
./client.cpp:168:11: error: use of undeclared identifier 'le64toh'
return le64toh((uint64_t(*(it-1)) << 56) |
^
./client.cpp:187:22: error: use of undeclared identifier 'htole16'
uint16_t lesize = htole16(size);
^
./client.cpp:191:22: error: use of undeclared identifier 'htole32'
uint32_t lesize = htole32(size);
^
./client.cpp:195:22: error: use of undeclared identifier 'htole64'
uint64_t lesize = htole64(size);
^
./client.cpp:272:75: error: use of undeclared identifier 'MSG_NOSIGNAL'
while (total < nbyte && (count = send(filedes, buf + total, nbyte-total, MSG_NOSIGNAL)) > 0)
^
./client.cpp:331:29: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
void reconnect(std::string disconnectReason, bool alreadyLocked=false) {
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
./client.cpp:358:25: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
return me->reconnect("unable to create socket", true);
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
./client.cpp:362:25: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
return me->reconnect("unable to lookup host", true);
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
./client.cpp:366:25: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
return me->reconnect("failed to connect()", true);
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
./client.cpp:384:21: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
return reconnect("failed to write version header", true);
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
./client.cpp:386:21: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
return reconnect("failed to write version string", true);
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
./client.cpp:392:21: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
return reconnect("error during connect", true);
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
./client.cpp:399:22: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
return reconnect("failed to read message header");
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
./client.cpp:402:22: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
return reconnect("invalid magic bytes");
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
./client.cpp:407:22: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
return reconnect("got message too large");
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
./client.cpp:414:23: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
return reconnect("failed to read version message");
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
./client.cpp:417:23: error: implicit instantiation of undefined template 'std::__1::basic_string<char, std::__1::char_traits<char>, std::__1::allocator<char> >'
return reconnect("unknown version string");
^
/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/bin/../lib/c++/v1/iosfwd:188:33: note: template is declared here
class _LIBCPP_TYPE_VIS_ONLY basic_string;
^
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
Failed to build using g++
./make.sh: line 9: i686-w64-mingw32-g++: command not found
Failed to build windows client with mingw
For now, I'm sticking with the java client, but would rather have the C++ client working. Avoiding the Python client for now due to performance concerns (though I'm already running P2Pool via pypy).
Dears,
Which network port should I open on the firewall?
That OSX fix pull request broke c++ client on Ubuntu. I keep getting bitcoind not connected errors.
Reverting my local working copy to commit e465966 and make runs fine without bitcoin connect errors.
On kernel-3.10.0-327.18.2.el7.x86_64 using the binary provided in the 'client' directory I get the following error:
[root@here]# ./relaynetworkclient 127.0.0.1 8333 public.us-east.relay.mattcorallo.com
Using server public.us-east.relay.mattcorallo.com
Illegal instruction
If I run 'make install' in the 'c++' directory I get the same result after running the resultant binary.
This used to work on this server in the past. I noticed the problem after a system update which included a new kernel. Unfortunately I can't review the logs to determine when relaynetworkclient stopped working.
but, yea, the client software is pretty stable
when it fails it just reconnects
which is what makes it stable :)
even to another node?
no, sadly not
i really should implement that
but then it could happen that it switches to a node with higher latency for a small error and does not switch back
yes
issues to consider :)
They seem to work in wine, but apparently they dont (see https://bitcointalk.org/index.php?topic=766190.msg12036075#msg12036075).
Clients probably relay a ton of transactions out-of-band that will never be used to compress and are essentially useless. We shouldn't be doing this. Probably related to #11.
Hi,Matt.
I am confronted with the following errors when compiling the java relay server:
RelayConnection.java:368: error: cannot find symbol
if (msgLength > Block.MAX_BLOCK_SIZE)
^
symbol: variable MAX_BLOCK_SIZE
location: class Block
RelayConnection.java:517: error: cannot find symbol
return Block.MAX_BLOCK_SIZE; // Its bigger than 64k, so buffers will just be 64k in size
^
symbol: variable MAX_BLOCK_SIZE
location: class Block
RelayConnectionListener.java:43: error: no suitable constructor found for Peer(NetworkParameters,VersionMessage,,PeerAddress)
final Peer emulatedPeer = new Peer(params, fakeVersionMessage, null, new PeerAddress(inetAddress));
^
constructor Peer.Peer(NetworkParameters,BlockChain,String,String) is not applicable
(actual argument VersionMessage cannot be converted to BlockChain by method invocation conversion)
constructor Peer.Peer(NetworkParameters,BlockChain,VersionMessage) is not applicable
(actual and formal argument lists differ in length)
So my question is which version of bitcoinj are you using in this project?
BTW, i tried branch master and release-0.9 using the official code here: https://code.google.com/p/bitcoinj/source/browse/
and also tried the bitcoinj in your repository, but neither of them works.
Thanks for your help!
Dears,
I saw that relay network connection on my PC is inbound not an outbound.
is that correct direction?
It would be nice to have a client which is available to miners to peer with each other that doesnt depend on the centralized infrastructure.
Maybe we dont want to use TCP, maybe we want to switch to a different congestion control algorithm, maybe we want to run some dirty hack on the servers that captures all packets via libpcap right after a block is found, and re-send all of them 10ms later so that we dont have to wait when we lose packets (though that may interfere with TCP's backoff-on-dups stuff).
f2pool (and maybe others) are including very large individual transactions which are breaking compression...we should switch metrics to something that allows large individual transactions, but limits total size, instead of limiting tx count and tx size.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.