shadow-plugin-bitcoin icon indicating copy to clipboard operation
shadow-plugin-bitcoin copied to clipboard

Examples for more complicated networks?

Open haasn opened this issue 8 years ago • 3 comments

Being able to run two bitcoind nodes is nice and all, but would it be possible to provide an example of how to extend this to larger networks? (Say, 1000 nodes and 10 miners)

Since the connections seem to be hard-coded in the XML file it's not quite clear to me, apart from manually generating a big XML file with randomized connections, how to do this in a more pragmatic way.

haasn avatar Jul 08 '17 08:07 haasn

Generating a big XML file with hard-coded -connect args for each bitcoin node is the approach that I took. I agree that approach is not ideal, though...

robgjansen avatar Jul 09 '17 17:07 robgjansen

Do you happen to still have scripts lying around for that? Publishing them in the wiki or something would be useful to somebody down the road.

haasn avatar Jul 10 '17 00:07 haasn

I don't have anything usable lying around. Generating Shadow config files is fairly straight forward; just generate a bunch of nodes that run the bitcoind plugin and set the arguments for those nodes correctly. The unknown part is which nodes should connect to which other nodes, but there may be data out there for that or you might just decide on the connections arbitrarily.

An example of generating a Shadow config file is here: https://github.com/shadow/shadow/blob/master/tools/generate_example_config.py#L16

You would just want to change the "tgen" application with bitcoind.

Sorry this is not a great answer, but I hope that helps!

robgjansen avatar Jul 10 '17 23:07 robgjansen