# Node Operating Commands
These commands will get access to the information belongs to the Miyabi node. All commands are online commands.
# get info
# Usage
Usage: miyabi-cli getinfo [Options]
Options:
--help Show help information
# Functionality
General reference command that returns the node status and information. The height here is the current height of the connected node, could be lower or higher due to network latency.
# Example
$ ./miyabi-cli.exe getinfo
{"status":"Running","height":16,"mempoolSize":0,"identity":"026beca06739461a20249fd4b24cf27542013624d18710bc418e8de10d6ef68568","role":0,"extensions":["miyabi.BLS","miyabi.Binary","miyabi.Asset","miyabi.Entity","miyabi.Contract"]}
# get all info
# Usage
Usage: miyabi-cli getallinfo [Options]
Options:
--help Show help information
# Functionality
General reference commands that return the brief information of all nodes in the config(hosts). --host
, --config
or default config should be provided.
# Example
$ ./miyabi-cli.exe --config cli_config.json getallinfo
host (rpc) status height mempool address role
----------------------------- -------- ------- --------- ------- -----
https://localhost:9010/ Running 826 0 026beca06739 Core
https://localhost:9011/ Running 826 0 02fce59e2dd0 Core
https://localhost:9012/ Running 822 0 025e50e24dd8 Observer
https://localhost:9013/ Running 822 0 033abce4dbb0 Observer
# get consensus credentials
# Usage
Usage: miyabi-cli getconsensuscredentials [Options]
Options:
--help Show help information
-h|--height <number> Height
# Functionality
General reference command that returns all consensus nodes credentials for a specific height. If -h
is not specified, directly return the credentials of the current height of the connected node.
# Example
$ ./miyabi-cli.exe getconsensuscredentials
{"members":["026beca06739461a20249fd4b24cf27542013624d18710bc418e8de10d6ef68568"],"quorumCredentials":[]}
# get peer count
# Usage
Usage: miyabi-cli getpeercount [Options]
Options:
--help Show help information
# Functionality
General reference command that returns the number of nodes that the current node is connected to.
# Example
$ ./miyabi-cli.exe getpeercount
4
# get peers
# Usage
Usage: miyabi-cli getpeers [Options]
Options:
--help Show help information
# Functionality
General reference command that returns the credential of nodes that the current node is connected to
# Example
$ ./miyabi-cli.exe getpeers
["033abce4dbb0e1c60dd5bdc86d769d9830ef0a3dc874f0ceb57390d90cc710a1ea","025e50e24dd813cc8fe1a7566074cbff7cf9b80f9782d0360d570f92e4975b1532","02fce59e2dd0015bbb34da445f6c3a4ac2254a1b90ffa9c66fbd8621bf0c1a6deb"]
# get performance
# Usage
Usage: miyabi-cli getperformance [Options]
Options:
--help Show help information
# Functionality
General reference command that gets the performance data of the node
# Example
$ ./miyabi-cli.exe getperformance
{"statsStartHeight":462,"txPerBlock":{"max":83,"min":1,"avg":1.5526315789473695,"movAvg":1.0000170307924798,"sum":1475},"tps":{"max":41,"min":0,"avg":0.12539515279241306,"movAvg":1.6851953691384713E-05},"confTimeMs":{"max":339080371,"min":328,"avg":5182371.995785031,"movAvg":2099849.951629233}}
# get node config
# Usage
Usage: miyabi-cli getnodeconfig [Options]
Options:
--help Show help information
# Functionality
Admin reference command that gets the node.config
of the connected node. Must specify the admin endpoint in the config and specify the client certificate by -cc
.
# Example
$ ./miyabi-cli.exe --host https://localhost:8000 -ins -cc admin.p12 getnodeconfig
{"bindings":["0.0.0.0:3820"],"initialNodes":[],"nodeAdmin":"03046bf1185537b4fc97fd8eab74c5e08cbe306aa7c394de812a8c1b6abcc2e5a4","sslKeyStorePath":"c:\\ssl.p12","consensusKeyStorePath":"c:\\consensuskey.p12","dbConfig":{"baseLocation":"c:\\_configs\\node_000","storageCacheSizeMb":64,"storageCompressedCacheSizeMb":64,"storagePointLookupBlockCacheSizeMb":8},"generalWebApiConfig":{"webApiEndPoint":"https://+:9010/","serverKeyStorePath":"c:\\server.p12"},"adminWebApiConfig":{"webApiEndPoint":"https://+:8000/","serverKeyStorePath":"c:\\server.p12"},"consensus":{"timeout":"00:00:10","interval":"00:00:04"},"busyWaitTransactions":false,"waitForTx":"00:00:00","memoryPoolCapacity":1048576,"maxGetBlockSize":5,"maxBlockDepth":100,"extensions":[]}
# set node config
# Usage
Usage: miyabi-cli setnodeconfig [Options]
Options:
--help Show help information
-f|--file <path> Path to node config file
# Functionality
Admin Update command that upload the file specified by -f
and replace the node config of the current node. Admin endpoint should be specified and a client certificate is required. The node will reject config files of incorrect format.
# Example
$ ./miyabi-cli.exe --host https://localhost:8000 -ins -cc admin.p12 setnodeconfig -f config_node_updated.json
{"bindings":["0.0.0.0:3820"],"initialNodes":[],"nodeAdmin":"03046bf1185537b4fc97fd8eab74c5e08cbe306aa7c394de812a8c1b6abcc2e5a4","sslKeyStorePath":"c:\\ssl.p12"...