Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Byzcoin Benchmarking #2441

Open
Raycoms opened this issue Mar 24, 2021 · 8 comments
Open

Byzcoin Benchmarking #2441

Raycoms opened this issue Mar 24, 2021 · 8 comments

Comments

@Raycoms
Copy link

Raycoms commented Mar 24, 2021

Hi, I was looking through the repo and I was wondering if there is a "simple" way to startup 400 instances and run a benchmark with fixed sized blocks.

@ineiti
Copy link
Member

ineiti commented Mar 25, 2021

There is a simulation framework where you can do this. Look for example at https://github.com/dedis/cothority/tree/master/byzcoin/simulation - which should have a README :(

In that directory, you can run the simulation with

go run . coins.toml

This sets up a 5-node system and runs a number of coin-transactions on them, then it waits for all transactions to be accepted.

You can find more information about running the simulations here:

https://github.com/dedis/onet/tree/master/simul

@Raycoms
Copy link
Author

Raycoms commented Apr 6, 2021

I now had the time to look deeper into this. Not sure I understood this right, but it seems I can either run this on one of the cloud platforms (Deterlab etc) which need a special signup or solely on localhost using this.

Is there an easy way I can get each process to run within a docker container on a distributed set of processes like Grid5000?

@ineiti
Copy link
Member

ineiti commented Apr 12, 2021

We use mininet to add network bandwidth and latency control. Since a month ago, you can also run it in a virtual machine - check out the end of this:

https://github.com/dedis/onet/blob/master/simul/platform/MININET.md

@Raycoms
Copy link
Author

Raycoms commented Apr 12, 2021

I've seen that you can run it in 1 virtual machine, but I couldn't find anything regarding distributed setups (like, defining a cluster of IPs or similar) to distribute the processes on. The config allows to configure the numer of servers, but doesn't describe where I define the list of servers and how to access them.

Also: https://pkg.go.dev/github.com/dedis/onet?utm_source=godoc#Simulation returns not found.

Getting a docker swarm support would be amazing for this.

@ineiti
Copy link
Member

ineiti commented Apr 12, 2021

Yes, we thought of doing AWS deployments, too, but currently this is very low on our priority list, sorry :(

Using the virtual machine and Mininet, you can simulate up to 200 nodes on a powerful machine, with bandwidth and latency restriction between each pair of nodes. For more you either need to give up the network restrictions and use localhost, or you need to set up manually multiple servers and then use mininet on them.

@ineiti
Copy link
Member

ineiti commented Apr 12, 2021

Theoretically it should be enough to copy https://github.com/dedis/onet/blob/master/simul/platform/mininet.go into a docker-swarm.go and implement the public methods to fit your deployment. But the devil will be in the details, most annoyingly the way the monitor works...

@Raycoms
Copy link
Author

Raycoms commented Apr 22, 2021

I'm very confused about running the simulation (on mini-net or localhost). The localhost description is basically non existent and mininet tells me to run: "go build && ./simul -platform mininet simul.toml" without saying from which folder to run it, and what simul.toml should contain.

I guessed that simul.toml is supposed to contain the simulation settings like:

Simulation = "ExampleHandlers"
Servers = 16
BF = 2
Rounds = 10
#SingleHost = true

Hosts
3
7
15
31

but there is still no executable simul file

root@nova-16:~/onet# go build && ./simul -platform mininet simul.toml
-bash: ./simul: Is a directory

@ineiti
Copy link
Member

ineiti commented Apr 26, 2021

This should work:

git clone https://github.com/dedis/cothority
cd cothoriyt/byzcoin/simulation
go build && ./simulation -platform localhost coins.toml

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants