ppd Command
'ppd'commands are used to operate PP(resource) node
Help
elpList ppd usage, available sub-commands and flags
./ppd -h
OR
./ppd --helpResponse:
Usage:
ppd [command]
Available Commands:
config create default configuration file
help Help about any command
start start the node
terminal open terminal attached to node demon
version get version of the build
Flags:
-c, --config string configuration file path (default "./configs/config.yaml")
-h, --help help for ppd
-r, --home string path for the node (default "/mnt/hgfs/code/devnettesting/p2p/sds/target")Config
ConfigCreate default configuration file for a PP(resource) node
node folder is the folder that contains configs and accounts of the PP node. An PP node folder usually looks like
Response:
After the execution of this command, a configs/config.yaml file will be generated under the node folder.
The node folder looks like:
accounts contains important account info, such as wallet and P2P key files , and thus need to be kept secret.
configs includes all configurations for this PP node. User should modify the config.yaml file to accommodate different scenarios. Please pay more attention to the following configurations:
StratosChainUrl: you can configure it to your ownstchaincli rest-serverif you already run one with yourstchaindnode; for Stratos Testnet, this value should be set as "https://rest-test.thestratos.org".SPList: for local running, it looks likefor Stratos Testnet, set
NetworkAddressas:ChainId: Set this value as your own blockchain'schain-id; for the current Stratos Testnet, set it asstratos-testnet-3.NetworkAddress: make sure to set theNetworkAddressto your public IP address and port. If your node is behind a router, you probably need to configure port forwarding on the router, like
peers the pp-list file lists all the PP nodes found in the network.
tmp stores stdout log. It is generated automatically during the node is running.
Start
StartStart a PP(resource) node without interactivity
Response:
Version
Versionget the version of the build
Response:
Terminal
TerminalStart a PP(resource) node with interactivity
This command need to be executed in the PP node folder
Response:
AS shown above, a set of commands can be used to communicate with Stratos-chain, SP node as well as other peers under ppd terminal.
help
helpshow all the commands
rp, registerpeer
rp, registerpeerregister PP node to SP(meta, or indexing) node
wallets
walletsacquire all wallets' address
activate
activate activate <amount> <fee> <gas>
send transaction to Stratos-chain to become an active PP node
prepay
prepayprepay <amount> <fee> <gas>
prepay stos to get ozone, amount in ustos
startmining
startminingstart mining
put
putput <filepath>
upload a file. It will consume ozone
list
listquery all files
list <filename>
list <filename>query a specific uploaded file by filename
get
getget <sdm://account/filehash|filename>
download a file. It will consume ozone
sharefile
sharefilesharefile <filehash> <expiry> <private>
share an uploaded file
allshare
allsharelist all shared files
getsharefile
getsharefilegetsharefile <sharelink> <password>
download a shared file, need to consume ozone
cancelshare
cancelsharecancelshare <shareID>
cancel a shared file
delete
deletedelete <filehash>
delete a file
monitor
monitorshow monitor
newwallet
newwallet <nodeName> <hdPath>
create new wallet, input password in prompt
login
login <>wallet-address>
unlock and log in wallet, input password in prompt
config
config <key> <value>
set config key value, separated by one space
Last updated