Other > Gravity

Gravity Testnet Instructions Set

(1/2) > >>

Gravity Protocol:
Resyncing the node

Witnesses:

1. To avoid missing the blocks, witnesses have to use the backup node
Make sure that your backup node is running.

2. In the cli_wallet change your witness signing key to backup key


--- Code: ---update_witness g1234r1234v1234z1234 "my url" ZGV...backupSigningPublicKey true
--- End code ---

Make sure that block production continued from your witness

3. Restart the main node
docker:


--- Code: ---docker-compose down
docker-compose up -d
--- End code ---

without docker:


--- Code: ---Ctrl+C
./witness_node --data-dir=data --resync-blockchain
--- End code ---

Wait for synchronization after update

4. Switch your witness back to its main signing key


--- Code: ---update_witness g1234r1234v1234z1234 "my url" ZGV...mainSigningPublicKey true
--- End code ---

Make sure that block production continued from your witness

5. Restart the backup node the same way as the main

Non-witnesses:

1. Restart the node
docker:


--- Code: ---docker-compose down
docker-compose up -d
--- End code ---

without docker:


--- Code: ---Ctrl+C
./witness_node --data-dir=data --resync-blockchain
Wait for synchronization after update
--- End code ---


Follow us
• Website • BitsharesTalk • Telegram channel • Telegram dev chat • Blog on Steemit • Blog on Medium • Twitter • Discord • Linkedin •

Gravity Protocol:
How to update Gravity Protocol node

We’re going to learn how to update Gravity Protocol node.


* First, we’ll go to the node’s directory.
--- Code: ---cd gravity-testnet-docker
--- End code ---


* Here we’ll stop our node.

--- Code: ---sudo docker-compose down
--- End code ---


* Then we’ll receive the update from github.

--- Code: ---git pull origin
--- End code ---


* And new versions of packages from Dockerhub.

--- Code: ---sudo docker-compose pull
--- End code ---


* Now we’ll run the node in daemon mode.

--- Code: ---sudo docker-compose up -d
--- End code ---


* If you prefer, you can display current sync status on the screen.

--- Code: ---sudo docker-compose logs — tail 10 -f
--- End code ---

* To hide the logs, press *Ctrl+Z.
Follow us
• Website • BitsharesTalk • Telegram channel • Telegram dev chat • Blog on Steemit • Blog on Medium • Twitter • Discord • Linkedin •

Gravity Protocol:
How to make proposals and to edit a blockchain configuration

We’re going to learn how to make proposals and to edit a blockchain configuration.


* First we’ll open cli-wallet when the node is launched.
--- Code: ---sudo docker-compose exec gravity_node cli_wallet -w /var/lib/gravity/wallet.json
--- End code ---


* Then we’ll unlock the wallet.

--- Code: ---unlock 1234567
--- End code ---


* And now we’ll get to work.
* We’ll get current configuration values:

--- Code: ---get_global_properties
--- End code ---


* We’ll make a proposal to change the interval between the blocks using the template:

--- Code: ---propose_parameter_change [from account] [time, the value must be greater than CURRENTTIME + committee_proposal_review_period and lower than CURRENTTIME + maximum_proposal_lifetime] {json with the new values} true
--- End code ---


* For example:

--- Code: ---propose_parameter_change “g2090i8190e9280o7900” “2018–06–13T17:28:00” {“block_interval”: 3} true
--- End code ---


* Now we’ll get the number of proposal id.

--- Code: ---get_account_history “g2090i8190e9280o7900” 1
2018–06–13T17:00:20 proposal_create_operation g2090i8190e9280o7900 fee: 20.00007 ZGV result: 1.10.1
--- End code ---


* And we’ll vote.

--- Code: ---approve_proposal g2090i8190e9280o7900 1.10.1 {“active_approvals_to_add” : [“g2090i8190e9280o7900”]} true
--- End code ---


* Now we’ll close the cli-wallet using Ctrl+C
And we’ll change the fees:


* First we’ll get current values of the configuration

--- Code: ---get_global_properties
--- End code ---


* Then we’ll make a proposal to change the fees.

--- Code: ---propose_fee_change “g2090i8190e9280o7900” “2018–06–13T04:32:00” {0 : {“fee”: 1, “price_per_kbyte”: 0,1}, 34 : {“fee”: 10000000}} true
--- End code ---


* Now we’ll get the number of proposal id.

--- Code: ---get_account_history “g2090i8190e9280o7900” 1
2018–06–13T17:00:20 proposal_create_operation g2090i8190e9280o7900 fee: 20.00007 ZGV result: 1.10.1
--- End code ---


* And vote:

--- Code: ---approve_proposal g2090i8190e9280o7900 1.10.1 {“active_approvals_to_add” : [“g2090i8190e9280o7900”]} true

--- End code ---

Follow us
• Website • BitsharesTalk • Telegram channel • Telegram dev chat • Blog on Steemit • Blog on Medium • Twitter • Discord • Linkedin •

Gravity Protocol:
Comittee Memember Registration Tutorial

We’ll be learning how to create a member of the committee from an account.

Video instrustion is here.


* To begin, we need to open the file with the program node.
--- Code: ---cd gravity-testnet-docker
--- End code ---


* Now, let’s start our node with demonization.

--- Code: ---sudo docker-compose up -d
--- End code ---


* Next, run the cli-wallet with extra parameters.

--- Code: ---sudo docker-compose exec gravity_node cli_wallet -w /var/lib/gravity/wallet.json
--- End code ---


* At this time, we’ll create a password for the wallet.

--- Code: ---set_password password
--- End code ---


* Unblock the wallet and we’ll be sent into our account.

--- Code: ---unlock password
--- End code ---


* Here, we’ll import our account.

--- Code: ---import_key “your-account” “your-active-private-key”
--- End code ---


* Now that we’ve done this, we have a lifetime membership for this account,

--- Code: ---upgrade_account “account” true
--- End code ---


* From this account we’ll be creating a member of the committee.

--- Code: ---create_committee_member “account” “url” true
--- End code ---

* Execute the following command, an example is in the video description.
* Now close the cli-wallet using the keyboard shortcut Ctrl+C.
* Now your account is a candidate to be a member of the committee.
* All that is left to do is convince people to vote for you.
If you’ve already created a witness node, you can skip the password setting steps for the wallet, import the account and purchase a lifetime membership.

Follow us
• Website • BitsharesTalk • Telegram channel • Telegram dev chat • Blog on Steemit • Blog on Medium • Twitter • Discord • Linkedin •

Gravity Protocol:
Turn a node into a witness node

We’re going to turn a node into a witness node.

Video instructions you can find here.


* First, open node’s directory.
--- Code: ---cd gravity-testnet-docker
--- End code ---


* Then, run the node in daemon mode, and run the cli-wallet with advanced settings.

--- Code: ---sudo docker-compose up -d
sudo docker-compose exec gravity_node cli_wallet -w /var/lib/gravity/wallet.json

--- End code ---

* Next, Set a password for the wallet and unblock the wallet.

--- Code: ---set_password password
unlock password
--- End code ---


* Import your account in the wallet.

--- Code: ---import_key “your-account” “your-active-private-key”
--- End code ---


* Here’s where you’ll get a lifetime membership, and then create a witness.

--- Code: ---upgrade_account “account” true
create_witness “account” “url” true
--- End code ---


* Now you’ll need to get your witness-ID.

--- Code: ---get_witness “account”
--- End code ---


* As you can see, the witness-ID for this specific account is “1.6.*” You’re going to want to memorize it or write it down. There is also a public key for signing blocks which also needs to be saved.
* Now you can derive a private key using the public key, save the private key as well.

--- Code: ---get_private_key [public signing key]
--- End code ---
(without quote)


* Now close the cli-wallet using Ctrl+C.
* After that, you’ll need to edit the config.ini file.

--- Code: ---sudo nano ./data/config.ini
--- End code ---


* Add your witness-ID, and replace the keys.
* Don’t forget to delete the sharp symbol (#) in front of witness-id to turn the comment line into a code line.
* After you’ve added your witness-ID and replaced the keys, press Ctrl+X.
* Then press Y to save the changes.
* Now you’ll need to restart the node. For that, use the docker-compose down and docker-compose up commands.

--- Code: ---sudo docker-compose down
sudo docker-compose up -d
--- End code ---

* And there you have it, a running witness node!
* Now, all you have to do is convince people to vote for you.
Follow us
• Website • BitsharesTalk • Telegram channel • Telegram dev chat • Blog on Steemit • Blog on Medium • Twitter • Discord • Linkedin •

Navigation

[0] Message Index

[#] Next page

Go to full version