cardano-ops icon indicating copy to clipboard operation
cardano-ops copied to clipboard

nix script for tx generator

Open CodiePP opened this issue 5 years ago • 4 comments

the tx generator is being manually started on the 'explorer' node:

$ /nix/store/b6dnbn2hs8lb70bl28kiby7wd9qapk85-cardano-node-1.0.0-exe-cardano-cli/bin/cardano-cli \
 --log-config /root/log-config.json \
 --signing-key /root/delegate-keys.000.key\
 --database-path /var/lib/cardano-node/db-shelley-dev|
 --delegation-certificate /root/delegation-cert.000.json\
 --genesis-file /nix/store/hgi34ghapaiy2zkd0zxh1ac7rg4l13hb-genesis.json\
 --genesis-hash dae7a545d0dfdeb2e7702397bc8d986c65641147f2745508d54abd44252f9a82\
 --socket-dir /run/cardano-node\
 --real-pbft\
 generate-txs\
 --num-of-txs 50000\
 --add-tx-size 100\
 --inputs-per-tx 1\
 --outputs-per-tx 1\
 --tx-fee 10000000\
 --tps 100\
 --sig-key /root/delegate-keys.000.key\
 --sig-key /root/delegate-keys.001.key\
 --sig-key /root/delegate-keys.002.key\
 --node-id 0\
 --target-node '("<ip0>",3001)'\
 --target-node '("<ip1>",3001)'\
 --target-node '("<ip2>",3001)'

can this be prepared via nix like for the startup scripts for the nodes etc. ? (also the log-config.json)

CodiePP avatar Dec 03 '19 14:12 CodiePP

in epic: https://github.com/input-output-hk/iohk-monitoring-framework/issues/323

CodiePP avatar Dec 06 '19 11:12 CodiePP

It should be a script available in PATH on explorer machine after deployment, for example run_tx_generator. This script should take "transaction generator"-specific CLI arguments only, for example:

[root@explorer:~]# run_tx_generator --num-of-txs 50000 --add-tx-size 100 --inputs-per-tx 1 --outputs-per-tx 1 --tx-fee 10000000 --tps 100

All other CLI arguments should be taken from deployment configuration. As a result, this script starts full cardano-cli generate-txs command.

denisshevchenko avatar Dec 09 '19 15:12 denisshevchenko

Please see a draft in dev@dev-deployer:~/remote-dev-cluster/run_tx_generator.sh.

denisshevchenko avatar Dec 09 '19 16:12 denisshevchenko

Nix-draft: https://github.com/input-output-hk/cardano-node/commit/107e186070834a7d25a7dc072659759ac3b57ca4

denisshevchenko avatar Dec 10 '19 16:12 denisshevchenko