After the serval documents, you must be eager to know how to run MultiVAC now, let’s enjoy it with Santa Claus!
Note: the example is about to run a testnet by yourself.
Compile and upload to server
1、Enter the MultiVAC directory
$ cd $GOPATH/src/github.com/multivactech/MultiVAC/
2、Switch to the branch you want to go with
If there is no such branch, run:
$ git checkout -b local branch name origin/remote branch name
If there is the branch, run:
$ git checkout local branch name && git pull
3、Check the following configuration parameters
MultiVAC/model/chaincfg/params.go line: 232, HostProbability of re-fragmentation
MultiVAC/configs/params/params.go line: 18, SecurityLevelNumber of re-fragmentation rounds
MultiVAC/configs/params/params.go line: 22, ReshardRoundThresholdNumber of preparation rounds for the re-sharding
MultiVAC/configs/params/params.go line: 25, ReshardPrepareRoundThresholdHeartbeat interval
MultiVAC/configs/params/params.go line:42, SendHeartbeatIntervalSMinimum online time
MultiVAC/configs/params/params.go line:36, OnlineTimeS
4、Set the time point when the first batch of nodes start sending heartbeats
This time point is the time when the first batch of miners automatically start sending heartbeats after deployment, and a future time point needs to be set.
replace the second time value in MultiVAC/btcd.go line:104
$ CGO_ENABLED=0 GOOS=linux GOARCH=amd64 go install
After successful execution, the executable file MultiVAC will be generated in the $GOPATH/bin/linux_amd64/ directory.
Upload the executable file to the server
$ scp $GOPATH/bin/linux_amd64/MultiVAC email@example.com:/xxx/xxx/
Log in to server and deploy nodes
1、Log in to the server
$ ssh firstname.lastname@example.org
2、Configure the number of instances (how many miners, storage nodes)
The configuration is in /home/mac/gcpsupport.json
The instance type InstanceType includes miner, monitor, storageclient, txgenerator
ThisInstanceNum is the number of instances of this type of node
MinerNum is the number of miners running under this instance
StorageNum is the number of storage nodes running under the instance
Start 100 miners on 20 instances, and run 5 in each instance. The configuration is as follows:
3、Configure hardware for several types of instances (number of CPU cores, memory, hard disk)
The configuration is in /home/mac/typeDefine.json
Miner instance 10 core cpu, 10g memory, 10g hard disk
Note: These resources are shared by all miners running under this miner instance, and it can be understood as being equally divided.
$ ./testing-tools gcpsupport.json
Then input “init”, it will start to configure the instance.
5、Upload and deploy MultiVAC
ansible all -m shell -a"ls" -u xx -i ./inventory.yaml
When the IP of the machine turns green, enter “start” and press Enter to start uploading and deploying MultiVAC.
Note: please remember the IP of storage node, such as 188.8.131.52.
6、Monitor heartbeat and send RPC command
If you want to see log, then you can choose one sever (should not be storage node)and then log in it and run:
$ tail -f test/miner-0/logs/mainnet/btcd.log | grep online
After the previous time point we set, the terminal will print a batch of heartbeat information at each heartbeat interval.
After the number of online miners to be printed reaches the number of all miners deployed in the first batch, we can start another terminal that has compiled and execute the startup command(use the IP of storage node):
$ testnet --notls -s 184.108.40.206:18334 -u mtvac -P mtvac startnet
Then the first batch of miners will start mining.
MultiVAC is a high-throughput flexible blockchain platform based all-dimensional sharding. It’s a next-generation public blockchain platform built for integration with large-scale decentralized applications (dApps). MultiVAC is developing the first solution in the world characterized by speediness, efficiency, and all-dimensional sharding to expand its capacity in computation, transmission, and storage. It realizes the maximum throughput while maintaining decentralization and without sacrificing security.
Technical Whitepaper: https://www.mtv.ac/assets/file/MultiVAC_Tech_Whitepaper.pdf
Technical Yellowpaper: https://www.mtv.ac/assets/file/MultiVAC_Sharding_Yellowpaper.pdf
Technical Purplepaper: https://www.mtv.ac/assets/file/MultiVAC_Programming_Purplepaper.pdf
Telegram Group 2020: https://t.me/MultiVAC2020
Telegram Channel: https://t.me/MultiVACMTV