From cc32413a760d69fe57d23438248c58107c2bc586 Mon Sep 17 00:00:00 2001 From: chris529 Date: Thu, 21 Sep 2023 09:44:31 +0200 Subject: [PATCH 01/15] create-new-page-update-source.adoc --- .../update-existing-node/update-source.adoc | 361 ++++++++++++++++++ 1 file changed, 361 insertions(+) create mode 100644 docs/antora/modules/ROOT/pages/update-existing-node/update-source.adoc diff --git a/docs/antora/modules/ROOT/pages/update-existing-node/update-source.adoc b/docs/antora/modules/ROOT/pages/update-existing-node/update-source.adoc new file mode 100644 index 0000000000..34a40a8546 --- /dev/null +++ b/docs/antora/modules/ROOT/pages/update-existing-node/update-source.adoc @@ -0,0 +1,361 @@ += Update PM2 commands +Mona Bärenfänger Muhammad Talha chris braithwaite +:description: Describes how to manage Lisk Service v0.7.0 with PM2. +:toc: +:idseparator: - +:idprefix: +:imagesdir: ../assets/images +:source-language: bash +// External URLs +:url_pm2_docs: https://pm2.keymetrics.io/docs/usage/quick-start/ +:url_FLUSHALL: https://redis.io/commands/FLUSHALL + +On this page, you'll find the most relevant PM2 commands for running a source-based Lisk Service installation. +For more details about PM2, see {url_pm2_docs}[PM2 docs]. + +Moreover, we'll also talk about the steps to reset a Lisk Service node. + +== Various PM2 commands + +=== Start +Start Lisk Service. + +---- +pm2 start ecosystem.config.js +---- + +.Response +[%collapsible] +==== +.Example output +---- +[PM2] Applying action restartProcessId on app [lisk-service-gateway](ids: [ 0 ]) +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-app-registry](ids: [ 1 ]) +[PM2] [lisk-service-gateway](0) ✓ +[PM2] [lisk-service-blockchain-app-registry](1) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-connector](ids: [ 2 ]) +[PM2] [lisk-service-blockchain-connector](2) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-indexer](ids: [ 3 ]) +[PM2] [lisk-service-blockchain-indexer](3) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-coordinator](ids: [ 4 ]) +[PM2] [lisk-service-blockchain-coordinator](4) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-fee-estimator](ids: [ 5 ]) +[PM2] [lisk-service-fee-estimator](5) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-transaction-statistics](ids: [ 6 ]) +[PM2] [lisk-service-transaction-statistics](6) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-market](ids: [ 7 ]) +[PM2] [lisk-service-market](7) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-export](ids: [ 8 ]) +[PM2] [lisk-service-export](8) ✓ +┌----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┐ +│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ +├----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┤ +│ 1 │ lisk-service-blockchain-app-registry │ default │ 0.7.0-… │ fork │ 33328 │ 0s │ 16 │ online │ 0% │ 65.5mb │ XYZ │ disabled │ +│ 2 │ lisk-service-blockchain-connector │ default │ 0.7.0-… │ fork │ 33331 │ 0s │ 0 │ online │ 0% │ 63.8mb │ XYZ │ disabled │ +│ 4 │ lisk-service-blockchain-coordinator │ default │ 0.7.0-… │ fork │ 33341 │ 0s │ 0 │ online │ 0% │ 54.1mb │ XYZ │ disabled │ +│ 3 │ lisk-service-blockchain-indexer │ default │ 0.7.0-… │ fork │ 33338 │ 0s │ 16 │ online │ 0% │ 54.3mb │ XYZ │ disabled │ +│ 8 │ lisk-service-export │ default │ 0.7.0-… │ fork │ 33355 │ 0s │ 15 │ online │ 0% │ 14.1mb │ XYZ │ disabled │ +│ 5 │ lisk-service-fee-estimator │ default │ 0.7.0-… │ fork │ 33346 │ 0s │ 15 │ online │ 0% │ 46.9mb │ XYZ │ disabled │ +│ 0 │ lisk-service-gateway │ default │ 0.7.0-… │ fork │ 33326 │ 0s │ 15 │ online │ 0% │ 65.6mb │ XYZ │ disabled │ +│ 7 │ lisk-service-market │ default │ 0.7.0-… │ fork │ 33351 │ 0s │ 15 │ online │ 0% │ 36.9mb │ XYZ │ disabled │ +│ 6 │ lisk-service-transaction-statistics │ default │ 0.7.0-… │ fork │ 33348 │ 0s │ 15 │ online │ 0% │ 43.5mb │ XYZ │ disabled │ +└----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ +---- +==== + +=== List + +View the status of different microservices of Lisk Service in the list of PM2 processes: + +---- +pm2 list +---- + +.Response +[%collapsible] +==== +.Example output +---- +┌----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┐ +│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ +├----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┤ +│ 1 │ lisk-service-blockchain-app-registry │ default │ 0.7.0-… │ fork │ 33328 │ 0s │ 16 │ online │ 0% │ 65.5mb │ XYZ │ disabled │ +│ 2 │ lisk-service-blockchain-connector │ default │ 0.7.0-… │ fork │ 33331 │ 0s │ 0 │ online │ 0% │ 63.8mb │ XYZ │ disabled │ +│ 4 │ lisk-service-blockchain-coordinator │ default │ 0.7.0-… │ fork │ 33341 │ 0s │ 0 │ online │ 0% │ 54.1mb │ XYZ │ disabled │ +│ 3 │ lisk-service-blockchain-indexer │ default │ 0.7.0-… │ fork │ 33338 │ 0s │ 16 │ online │ 0% │ 54.3mb │ XYZ │ disabled │ +│ 8 │ lisk-service-export │ default │ 0.7.0-… │ fork │ 33355 │ 0s │ 15 │ online │ 0% │ 14.1mb │ XYZ │ disabled │ +│ 5 │ lisk-service-fee-estimator │ default │ 0.7.0-… │ fork │ 33346 │ 0s │ 15 │ online │ 0% │ 46.9mb │ XYZ │ disabled │ +│ 0 │ lisk-service-gateway │ default │ 0.7.0-… │ fork │ 33326 │ 0s │ 15 │ online │ 0% │ 65.6mb │ XYZ │ disabled │ +│ 7 │ lisk-service-market │ default │ 0.7.0-… │ fork │ 33351 │ 0s │ 15 │ online │ 0% │ 36.9mb │ XYZ │ disabled │ +│ 6 │ lisk-service-transaction-statistics │ default │ 0.7.0-… │ fork │ 33348 │ 0s │ 15 │ online │ 0% │ 43.5mb │ XYZ │ disabled │ +└----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ +---- +==== + +=== Logs +To check the logs for the different microservices of Lisk Service, use the command `pm2 logs PROCESS_NAME`, where `PROCESS_NAME` is the respective PM2-managed process that contains the logs you wish to view. + +Alternatively, it is also possible to check the logs for a specific PM2 process based on its process ID. +For example, `pm2 logs 0` can be used to check the Lisk Service Gateway logs. + +TIP: The process ID of each PM2-managed process can be seen by executing the <> command. + +For example, to see the logs for the Gateway microservice, execute the following command: + +---- +pm2 logs lisk-service-gateway +---- + +.Response +[%collapsible] +==== +.Example output +---- +0|lisk-ser | 2023-07-19 17:53:08 503: 2023-07-19T17:53:08.503 INFO [TRANSIT] Connecting to the transporter... +0|lisk-ser | 2023-07-19 17:53:08 504: 2023-07-19T17:53:08.503 INFO [TRANSPORTER] Setting Redis transporter +0|lisk-ser | 2023-07-19 17:53:08 510: 2023-07-19T17:53:08.510 INFO [TRANSPORTER] Redis-sub client is connected. +0|lisk-ser | 2023-07-19 17:53:08 510: 2023-07-19T17:53:08.510 INFO [TRANSPORTER] Setting Redis transporter +0|lisk-ser | 2023-07-19 17:53:08 512: 2023-07-19T17:53:08.512 INFO [TRANSPORTER] Redis-pub client is connected. +0|lisk-ser | 2023-07-19 17:53:09 016: 2023-07-19T17:53:09.016 INFO [TEMP_SERVICE_GATEWAY] Waiting for service(s) 'indexer, connector'... +0|lisk-ser | 2023-07-19 17:53:09 018: 2023-07-19T17:53:09.018 INFO [REGISTRY] '$node' service is registered. +0|lisk-ser | 2023-07-19 17:53:09 018: 2023-07-19T17:53:09.018 INFO [$NODE] Service '$node' started. +0|lisk-ser | 2023-07-19 17:53:10 225: 2023-07-19T17:53:10.223 INFO [REGISTRY] Node 'XYZ.local-74790' connected. +0|lisk-ser | 2023-07-19 17:53:10 274: 2023-07-19T17:53:10.274 INFO [REGISTRY] Node 'XYZ.local-74787' connected. +0|lisk-ser | 2023-07-19 17:53:10 325: 2023-07-19T17:53:10.325 INFO [REGISTRY] Node 'XYZ.local-74798' connected. +0|lisk-ser | 2023-07-19 17:53:10 346: 2023-07-19T17:53:10.345 INFO [REGISTRY] Node 'XYZ.local-74772' connected. +0|lisk-ser | 2023-07-19 17:53:10 415: 2023-07-19T17:53:10.414 INFO [REGISTRY] Node 'XYZ.local-74804' connected. +0|lisk-ser | 2023-07-19 17:53:10 485: 2023-07-19T17:53:10.484 INFO [REGISTRY] Node 'XYZ.local-74795' connected. +0|lisk-ser | 2023-07-19 17:53:10 676: 2023-07-19T17:53:10.675 INFO [REGISTRY] Node 'XYZ.local-74779' connected. +---- +==== + +=== Flush +Remove all the logs of the PM2-managed processes defined in the specified config file. + +---- +pm2 flush ecosystem.config.js +---- + +.Response +[%collapsible] +==== +.Example output +---- +[PM2] Logs flushed +---- +==== + + +=== Stop +Stop PM2 managed Lisk Service instance. + +---- +pm2 stop ecosystem.config.js +---- + +.Response +[%collapsible] +==== +.Example output +[source,bash] +---- +[PM2] [lisk-service-blockchain-app-registry](1) ✓ +[PM2] [lisk-service-gateway](0) ✓ +[PM2] [lisk-service-blockchain-indexer](3) ✓ +[PM2] [lisk-service-blockchain-connector](2) ✓ +[PM2] [lisk-service-blockchain-coordinator](4) ✓ +[PM2] [lisk-service-fee-estimator](5) ✓ +[PM2] [lisk-service-transaction-statistics](6) ✓ +[PM2] [lisk-service-market](7) ✓ +[PM2] [lisk-service-export](8) ✓ +┌------------------------------------------------------------------------------------------------------------------------------------------------------------------------┐ +│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ +├------------------------------------------------------------------------------------------------------------------------------------------------------------------------┤ +│ 1 │ lisk-service-blockchain-app-registry │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 32 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 2 │ lisk-service-blockchain-connector │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 0 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 4 │ lisk-service-blockchain-coordinator │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 0 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 3 │ lisk-service-blockchain-indexer │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 32 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 8 │ lisk-service-export │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 5 │ lisk-service-fee-estimator │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 0 │ lisk-service-gateway │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 7 │ lisk-service-market │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 6 │ lisk-service-transaction-statistics │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +└------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ +---- +==== + + +=== Restart + +Restart Lisk Service via PM2. + +---- +pm2 restart ecosystem.config.js +---- + +.Response +[%collapsible] +==== +.Example output +[source,bash] +---- +[PM2] Applying action restartProcessId on app [lisk-service-gateway](ids: [ 0 ]) +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-app-registry](ids: [ 1 ]) +[PM2] [lisk-service-gateway](0) ✓ +[PM2] [lisk-service-blockchain-app-registry](1) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-connector](ids: [ 2 ]) +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-indexer](ids: [ 3 ]) +[PM2] [lisk-service-blockchain-indexer](3) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-coordinator](ids: [ 4 ]) +[PM2] [lisk-service-blockchain-connector](2) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-fee-estimator](ids: [ 5 ]) +[PM2] [lisk-service-blockchain-coordinator](4) ✓ +[PM2] [lisk-service-fee-estimator](5) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-transaction-statistics](ids: [ 6 ]) +[PM2] Applying action restartProcessId on app [lisk-service-market](ids: [ 7 ]) +[PM2] [lisk-service-transaction-statistics](6) ✓ +[PM2] [lisk-service-market](7) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-export](ids: [ 8 ]) +[PM2] [lisk-service-export](8) ✓ +┌----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┐ +│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ +├----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┤ +│ 1 │ lisk-service-blockchain-app-registry │ default │ 0.7.0-… │ fork │ 33328 │ 0s │ 16 │ online │ 0% │ 65.5mb │ XYZ │ disabled │ +│ 2 │ lisk-service-blockchain-connector │ default │ 0.7.0-… │ fork │ 33331 │ 0s │ 0 │ online │ 0% │ 63.8mb │ XYZ │ disabled │ +│ 4 │ lisk-service-blockchain-coordinator │ default │ 0.7.0-… │ fork │ 33341 │ 0s │ 0 │ online │ 0% │ 54.1mb │ XYZ │ disabled │ +│ 3 │ lisk-service-blockchain-indexer │ default │ 0.7.0-… │ fork │ 33338 │ 0s │ 16 │ online │ 0% │ 54.3mb │ XYZ │ disabled │ +│ 8 │ lisk-service-export │ default │ 0.7.0-… │ fork │ 33355 │ 0s │ 15 │ online │ 0% │ 14.1mb │ XYZ │ disabled │ +│ 5 │ lisk-service-fee-estimator │ default │ 0.7.0-… │ fork │ 33346 │ 0s │ 15 │ online │ 0% │ 46.9mb │ XYZ │ disabled │ +│ 0 │ lisk-service-gateway │ default │ 0.7.0-… │ fork │ 33326 │ 0s │ 15 │ online │ 0% │ 65.6mb │ XYZ │ disabled │ +│ 7 │ lisk-service-market │ default │ 0.7.0-… │ fork │ 33351 │ 0s │ 15 │ online │ 0% │ 36.9mb │ XYZ │ disabled │ +│ 6 │ lisk-service-transaction-statistics │ default │ 0.7.0-… │ fork │ 33348 │ 0s │ 15 │ online │ 0% │ 43.5mb │ XYZ │ disabled │ +└----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ +---- +==== + +=== Delete +Remove all processes from the PM2 list. + +---- +pm2 delete ecosystem.config.js +---- + + +.Response +[%collapsible] +==== +.Example output +---- +[PM2] [lisk-service-gateway](0) ✓ +[PM2] [lisk-service-blockchain-app-registry](1) ✓ +[PM2] [lisk-service-blockchain-indexer](3) ✓ +[PM2] [lisk-service-blockchain-connector](2) ✓ +[PM2] [lisk-service-blockchain-coordinator](4) ✓ +[PM2] [lisk-service-fee-estimator](5) ✓ +[PM2] [lisk-service-transaction-statistics](6) ✓ +[PM2] [lisk-service-market](7) ✓ +[PM2] [lisk-service-export](8) ✓ +┌----------------------------------------------------------------------------------------------------------------------------------------------┐ +│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ +└----------------------------------------------------------------------------------------------------------------------------------------------┘ +[PM2][WARN] Current process list is not synchronized with saved list. App lisk-service-gateway lisk-service-blockchain-app-registry lisk-service-blockchain-connector lisk-service-blockchain-indexer lisk-service-blockchain-coordinator lisk-service-fee-estimator lisk-service-transaction-statistics lisk-service-market lisk-service-export differs. Type 'pm2 save' to synchronize. +---- +==== + +== Resetting Lisk Service + +=== Clean all run-time files with dependencies + +---- +make clean-local +---- + +.Response +[%collapsible] +==== +.Example output +---- +rm -rf node_modules +cd ./framework && rm -rf node_modules +cd ./services/blockchain-app-registry && rm -rf node_modules +cd ./services/blockchain-connector && rm -rf node_modules +cd ./services/blockchain-coordinator && rm -rf node_modules +cd ./services/blockchain-indexer && rm -rf node_modules +cd ./services/transaction-statistics && rm -rf node_modules +cd ./services/fee-estimator && rm -rf node_modules +cd ./services/market && rm -rf node_modules +cd ./services/gateway && rm -rf node_modules +cd ./services/export && rm -rf node_modules +cd ./services/template && rm -rf node_modules +cd ./tests && rm -rf node_modules +---- +==== + +=== Install npm dependencies + +---- +make build-local +---- + +=== Reset the Lisk Service database + +To reset the database of Lisk Service, drop the respective MySQL and Redis databases. + +==== Drop the MySQL database + +. Stop Lisk Service ++ +---- +yarn stop +---- + +. Login to MySQL with the `lisk` user. ++ +---- +mysql -u lisk -ppassword +---- + +. Drop the database. ++ +---- +mysql> drop database lisk; +---- + +. Create a fresh database. ++ +---- +mysql> create database lisk; +---- + +. Quit MySQL. ++ +---- +mysql> quit; +---- + +NOTE: The process to re-index all the data commences after Lisk Service starts again following a database reset. The process can be rather time-consuming and could take several hours, depending on the length of the chain. + +==== Flush Redis DB + +Reset the databases for Redis after dropping the MySQL database: + +---- +redis-cli flushall +---- + +[NOTE] +==== +The `flushall` command truncates all existing Redis databases: + +> Deletes all the keys of all the existing databases, not just the current selected one. This command never fails. + +For more information, check the Redis documentation: {url_FLUSHALL}[FLUSHALL]. + +To flush only a particular database in Redis, execute the following command instead: + +---- +redis-cli -n flushdb +---- +==== + +You can start Lisk Service again with the <> command. From e82704ae3de3a2cadcd77a7b5f3f1c5affe4cb36 Mon Sep 17 00:00:00 2001 From: chris529 Date: Thu, 5 Oct 2023 14:42:04 +0200 Subject: [PATCH 02/15] update-in-source.adoc --- docs/antora/modules/ROOT/pages/management/source.adoc | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index f0ef762fa9..cbf28e5edb 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -9,12 +9,16 @@ Mona Bärenfänger Muhammad Talha > command. To learn more about PM2 log management please refer the {url_pm2_management}[PM2 logs documentation]. + + == Various PM2 commands === Start From 1f136aed2ee53da81c61f2eb32875b468a82bccd Mon Sep 17 00:00:00 2001 From: chris529 Date: Thu, 5 Oct 2023 14:47:53 +0200 Subject: [PATCH 03/15] update-in-source.adoc --- docs/antora/modules/ROOT/pages/management/source.adoc | 1 + 1 file changed, 1 insertion(+) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index cbf28e5edb..04b18122bf 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -18,6 +18,7 @@ Moreover, we'll also talk about the steps to reset a Lisk Service node. TIP: The process ID of each PM2-managed process can be seen by executing the <> command. To learn more about PM2 log management please refer the {url_pm2_management}[PM2 logs documentation]. +NOTE: To upgrade Lisk Service to a desired version, please check out the specific version with *`git checkout `* and follow the existing process. == Various PM2 commands From e78252058c426018e64d14f4527456edace3c499 Mon Sep 17 00:00:00 2001 From: chris529 Date: Thu, 5 Oct 2023 16:11:18 +0200 Subject: [PATCH 04/15] update-in-source.adoc --- .../update-existing-node/update-source.adoc | 361 ------------------ 1 file changed, 361 deletions(-) delete mode 100644 docs/antora/modules/ROOT/pages/update-existing-node/update-source.adoc diff --git a/docs/antora/modules/ROOT/pages/update-existing-node/update-source.adoc b/docs/antora/modules/ROOT/pages/update-existing-node/update-source.adoc deleted file mode 100644 index 34a40a8546..0000000000 --- a/docs/antora/modules/ROOT/pages/update-existing-node/update-source.adoc +++ /dev/null @@ -1,361 +0,0 @@ -= Update PM2 commands -Mona Bärenfänger Muhammad Talha chris braithwaite -:description: Describes how to manage Lisk Service v0.7.0 with PM2. -:toc: -:idseparator: - -:idprefix: -:imagesdir: ../assets/images -:source-language: bash -// External URLs -:url_pm2_docs: https://pm2.keymetrics.io/docs/usage/quick-start/ -:url_FLUSHALL: https://redis.io/commands/FLUSHALL - -On this page, you'll find the most relevant PM2 commands for running a source-based Lisk Service installation. -For more details about PM2, see {url_pm2_docs}[PM2 docs]. - -Moreover, we'll also talk about the steps to reset a Lisk Service node. - -== Various PM2 commands - -=== Start -Start Lisk Service. - ----- -pm2 start ecosystem.config.js ----- - -.Response -[%collapsible] -==== -.Example output ----- -[PM2] Applying action restartProcessId on app [lisk-service-gateway](ids: [ 0 ]) -[PM2] Applying action restartProcessId on app [lisk-service-blockchain-app-registry](ids: [ 1 ]) -[PM2] [lisk-service-gateway](0) ✓ -[PM2] [lisk-service-blockchain-app-registry](1) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-blockchain-connector](ids: [ 2 ]) -[PM2] [lisk-service-blockchain-connector](2) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-blockchain-indexer](ids: [ 3 ]) -[PM2] [lisk-service-blockchain-indexer](3) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-blockchain-coordinator](ids: [ 4 ]) -[PM2] [lisk-service-blockchain-coordinator](4) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-fee-estimator](ids: [ 5 ]) -[PM2] [lisk-service-fee-estimator](5) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-transaction-statistics](ids: [ 6 ]) -[PM2] [lisk-service-transaction-statistics](6) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-market](ids: [ 7 ]) -[PM2] [lisk-service-market](7) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-export](ids: [ 8 ]) -[PM2] [lisk-service-export](8) ✓ -┌----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┐ -│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ -├----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┤ -│ 1 │ lisk-service-blockchain-app-registry │ default │ 0.7.0-… │ fork │ 33328 │ 0s │ 16 │ online │ 0% │ 65.5mb │ XYZ │ disabled │ -│ 2 │ lisk-service-blockchain-connector │ default │ 0.7.0-… │ fork │ 33331 │ 0s │ 0 │ online │ 0% │ 63.8mb │ XYZ │ disabled │ -│ 4 │ lisk-service-blockchain-coordinator │ default │ 0.7.0-… │ fork │ 33341 │ 0s │ 0 │ online │ 0% │ 54.1mb │ XYZ │ disabled │ -│ 3 │ lisk-service-blockchain-indexer │ default │ 0.7.0-… │ fork │ 33338 │ 0s │ 16 │ online │ 0% │ 54.3mb │ XYZ │ disabled │ -│ 8 │ lisk-service-export │ default │ 0.7.0-… │ fork │ 33355 │ 0s │ 15 │ online │ 0% │ 14.1mb │ XYZ │ disabled │ -│ 5 │ lisk-service-fee-estimator │ default │ 0.7.0-… │ fork │ 33346 │ 0s │ 15 │ online │ 0% │ 46.9mb │ XYZ │ disabled │ -│ 0 │ lisk-service-gateway │ default │ 0.7.0-… │ fork │ 33326 │ 0s │ 15 │ online │ 0% │ 65.6mb │ XYZ │ disabled │ -│ 7 │ lisk-service-market │ default │ 0.7.0-… │ fork │ 33351 │ 0s │ 15 │ online │ 0% │ 36.9mb │ XYZ │ disabled │ -│ 6 │ lisk-service-transaction-statistics │ default │ 0.7.0-… │ fork │ 33348 │ 0s │ 15 │ online │ 0% │ 43.5mb │ XYZ │ disabled │ -└----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ ----- -==== - -=== List - -View the status of different microservices of Lisk Service in the list of PM2 processes: - ----- -pm2 list ----- - -.Response -[%collapsible] -==== -.Example output ----- -┌----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┐ -│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ -├----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┤ -│ 1 │ lisk-service-blockchain-app-registry │ default │ 0.7.0-… │ fork │ 33328 │ 0s │ 16 │ online │ 0% │ 65.5mb │ XYZ │ disabled │ -│ 2 │ lisk-service-blockchain-connector │ default │ 0.7.0-… │ fork │ 33331 │ 0s │ 0 │ online │ 0% │ 63.8mb │ XYZ │ disabled │ -│ 4 │ lisk-service-blockchain-coordinator │ default │ 0.7.0-… │ fork │ 33341 │ 0s │ 0 │ online │ 0% │ 54.1mb │ XYZ │ disabled │ -│ 3 │ lisk-service-blockchain-indexer │ default │ 0.7.0-… │ fork │ 33338 │ 0s │ 16 │ online │ 0% │ 54.3mb │ XYZ │ disabled │ -│ 8 │ lisk-service-export │ default │ 0.7.0-… │ fork │ 33355 │ 0s │ 15 │ online │ 0% │ 14.1mb │ XYZ │ disabled │ -│ 5 │ lisk-service-fee-estimator │ default │ 0.7.0-… │ fork │ 33346 │ 0s │ 15 │ online │ 0% │ 46.9mb │ XYZ │ disabled │ -│ 0 │ lisk-service-gateway │ default │ 0.7.0-… │ fork │ 33326 │ 0s │ 15 │ online │ 0% │ 65.6mb │ XYZ │ disabled │ -│ 7 │ lisk-service-market │ default │ 0.7.0-… │ fork │ 33351 │ 0s │ 15 │ online │ 0% │ 36.9mb │ XYZ │ disabled │ -│ 6 │ lisk-service-transaction-statistics │ default │ 0.7.0-… │ fork │ 33348 │ 0s │ 15 │ online │ 0% │ 43.5mb │ XYZ │ disabled │ -└----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ ----- -==== - -=== Logs -To check the logs for the different microservices of Lisk Service, use the command `pm2 logs PROCESS_NAME`, where `PROCESS_NAME` is the respective PM2-managed process that contains the logs you wish to view. - -Alternatively, it is also possible to check the logs for a specific PM2 process based on its process ID. -For example, `pm2 logs 0` can be used to check the Lisk Service Gateway logs. - -TIP: The process ID of each PM2-managed process can be seen by executing the <> command. - -For example, to see the logs for the Gateway microservice, execute the following command: - ----- -pm2 logs lisk-service-gateway ----- - -.Response -[%collapsible] -==== -.Example output ----- -0|lisk-ser | 2023-07-19 17:53:08 503: 2023-07-19T17:53:08.503 INFO [TRANSIT] Connecting to the transporter... -0|lisk-ser | 2023-07-19 17:53:08 504: 2023-07-19T17:53:08.503 INFO [TRANSPORTER] Setting Redis transporter -0|lisk-ser | 2023-07-19 17:53:08 510: 2023-07-19T17:53:08.510 INFO [TRANSPORTER] Redis-sub client is connected. -0|lisk-ser | 2023-07-19 17:53:08 510: 2023-07-19T17:53:08.510 INFO [TRANSPORTER] Setting Redis transporter -0|lisk-ser | 2023-07-19 17:53:08 512: 2023-07-19T17:53:08.512 INFO [TRANSPORTER] Redis-pub client is connected. -0|lisk-ser | 2023-07-19 17:53:09 016: 2023-07-19T17:53:09.016 INFO [TEMP_SERVICE_GATEWAY] Waiting for service(s) 'indexer, connector'... -0|lisk-ser | 2023-07-19 17:53:09 018: 2023-07-19T17:53:09.018 INFO [REGISTRY] '$node' service is registered. -0|lisk-ser | 2023-07-19 17:53:09 018: 2023-07-19T17:53:09.018 INFO [$NODE] Service '$node' started. -0|lisk-ser | 2023-07-19 17:53:10 225: 2023-07-19T17:53:10.223 INFO [REGISTRY] Node 'XYZ.local-74790' connected. -0|lisk-ser | 2023-07-19 17:53:10 274: 2023-07-19T17:53:10.274 INFO [REGISTRY] Node 'XYZ.local-74787' connected. -0|lisk-ser | 2023-07-19 17:53:10 325: 2023-07-19T17:53:10.325 INFO [REGISTRY] Node 'XYZ.local-74798' connected. -0|lisk-ser | 2023-07-19 17:53:10 346: 2023-07-19T17:53:10.345 INFO [REGISTRY] Node 'XYZ.local-74772' connected. -0|lisk-ser | 2023-07-19 17:53:10 415: 2023-07-19T17:53:10.414 INFO [REGISTRY] Node 'XYZ.local-74804' connected. -0|lisk-ser | 2023-07-19 17:53:10 485: 2023-07-19T17:53:10.484 INFO [REGISTRY] Node 'XYZ.local-74795' connected. -0|lisk-ser | 2023-07-19 17:53:10 676: 2023-07-19T17:53:10.675 INFO [REGISTRY] Node 'XYZ.local-74779' connected. ----- -==== - -=== Flush -Remove all the logs of the PM2-managed processes defined in the specified config file. - ----- -pm2 flush ecosystem.config.js ----- - -.Response -[%collapsible] -==== -.Example output ----- -[PM2] Logs flushed ----- -==== - - -=== Stop -Stop PM2 managed Lisk Service instance. - ----- -pm2 stop ecosystem.config.js ----- - -.Response -[%collapsible] -==== -.Example output -[source,bash] ----- -[PM2] [lisk-service-blockchain-app-registry](1) ✓ -[PM2] [lisk-service-gateway](0) ✓ -[PM2] [lisk-service-blockchain-indexer](3) ✓ -[PM2] [lisk-service-blockchain-connector](2) ✓ -[PM2] [lisk-service-blockchain-coordinator](4) ✓ -[PM2] [lisk-service-fee-estimator](5) ✓ -[PM2] [lisk-service-transaction-statistics](6) ✓ -[PM2] [lisk-service-market](7) ✓ -[PM2] [lisk-service-export](8) ✓ -┌------------------------------------------------------------------------------------------------------------------------------------------------------------------------┐ -│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ -├------------------------------------------------------------------------------------------------------------------------------------------------------------------------┤ -│ 1 │ lisk-service-blockchain-app-registry │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 32 │ stopped │ 0% │ 0b │ XYZ │ disabled │ -│ 2 │ lisk-service-blockchain-connector │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 0 │ stopped │ 0% │ 0b │ XYZ │ disabled │ -│ 4 │ lisk-service-blockchain-coordinator │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 0 │ stopped │ 0% │ 0b │ XYZ │ disabled │ -│ 3 │ lisk-service-blockchain-indexer │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 32 │ stopped │ 0% │ 0b │ XYZ │ disabled │ -│ 8 │ lisk-service-export │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ -│ 5 │ lisk-service-fee-estimator │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ -│ 0 │ lisk-service-gateway │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ -│ 7 │ lisk-service-market │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ -│ 6 │ lisk-service-transaction-statistics │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ -└------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ ----- -==== - - -=== Restart - -Restart Lisk Service via PM2. - ----- -pm2 restart ecosystem.config.js ----- - -.Response -[%collapsible] -==== -.Example output -[source,bash] ----- -[PM2] Applying action restartProcessId on app [lisk-service-gateway](ids: [ 0 ]) -[PM2] Applying action restartProcessId on app [lisk-service-blockchain-app-registry](ids: [ 1 ]) -[PM2] [lisk-service-gateway](0) ✓ -[PM2] [lisk-service-blockchain-app-registry](1) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-blockchain-connector](ids: [ 2 ]) -[PM2] Applying action restartProcessId on app [lisk-service-blockchain-indexer](ids: [ 3 ]) -[PM2] [lisk-service-blockchain-indexer](3) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-blockchain-coordinator](ids: [ 4 ]) -[PM2] [lisk-service-blockchain-connector](2) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-fee-estimator](ids: [ 5 ]) -[PM2] [lisk-service-blockchain-coordinator](4) ✓ -[PM2] [lisk-service-fee-estimator](5) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-transaction-statistics](ids: [ 6 ]) -[PM2] Applying action restartProcessId on app [lisk-service-market](ids: [ 7 ]) -[PM2] [lisk-service-transaction-statistics](6) ✓ -[PM2] [lisk-service-market](7) ✓ -[PM2] Applying action restartProcessId on app [lisk-service-export](ids: [ 8 ]) -[PM2] [lisk-service-export](8) ✓ -┌----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┐ -│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ -├----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┤ -│ 1 │ lisk-service-blockchain-app-registry │ default │ 0.7.0-… │ fork │ 33328 │ 0s │ 16 │ online │ 0% │ 65.5mb │ XYZ │ disabled │ -│ 2 │ lisk-service-blockchain-connector │ default │ 0.7.0-… │ fork │ 33331 │ 0s │ 0 │ online │ 0% │ 63.8mb │ XYZ │ disabled │ -│ 4 │ lisk-service-blockchain-coordinator │ default │ 0.7.0-… │ fork │ 33341 │ 0s │ 0 │ online │ 0% │ 54.1mb │ XYZ │ disabled │ -│ 3 │ lisk-service-blockchain-indexer │ default │ 0.7.0-… │ fork │ 33338 │ 0s │ 16 │ online │ 0% │ 54.3mb │ XYZ │ disabled │ -│ 8 │ lisk-service-export │ default │ 0.7.0-… │ fork │ 33355 │ 0s │ 15 │ online │ 0% │ 14.1mb │ XYZ │ disabled │ -│ 5 │ lisk-service-fee-estimator │ default │ 0.7.0-… │ fork │ 33346 │ 0s │ 15 │ online │ 0% │ 46.9mb │ XYZ │ disabled │ -│ 0 │ lisk-service-gateway │ default │ 0.7.0-… │ fork │ 33326 │ 0s │ 15 │ online │ 0% │ 65.6mb │ XYZ │ disabled │ -│ 7 │ lisk-service-market │ default │ 0.7.0-… │ fork │ 33351 │ 0s │ 15 │ online │ 0% │ 36.9mb │ XYZ │ disabled │ -│ 6 │ lisk-service-transaction-statistics │ default │ 0.7.0-… │ fork │ 33348 │ 0s │ 15 │ online │ 0% │ 43.5mb │ XYZ │ disabled │ -└----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ ----- -==== - -=== Delete -Remove all processes from the PM2 list. - ----- -pm2 delete ecosystem.config.js ----- - - -.Response -[%collapsible] -==== -.Example output ----- -[PM2] [lisk-service-gateway](0) ✓ -[PM2] [lisk-service-blockchain-app-registry](1) ✓ -[PM2] [lisk-service-blockchain-indexer](3) ✓ -[PM2] [lisk-service-blockchain-connector](2) ✓ -[PM2] [lisk-service-blockchain-coordinator](4) ✓ -[PM2] [lisk-service-fee-estimator](5) ✓ -[PM2] [lisk-service-transaction-statistics](6) ✓ -[PM2] [lisk-service-market](7) ✓ -[PM2] [lisk-service-export](8) ✓ -┌----------------------------------------------------------------------------------------------------------------------------------------------┐ -│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ -└----------------------------------------------------------------------------------------------------------------------------------------------┘ -[PM2][WARN] Current process list is not synchronized with saved list. App lisk-service-gateway lisk-service-blockchain-app-registry lisk-service-blockchain-connector lisk-service-blockchain-indexer lisk-service-blockchain-coordinator lisk-service-fee-estimator lisk-service-transaction-statistics lisk-service-market lisk-service-export differs. Type 'pm2 save' to synchronize. ----- -==== - -== Resetting Lisk Service - -=== Clean all run-time files with dependencies - ----- -make clean-local ----- - -.Response -[%collapsible] -==== -.Example output ----- -rm -rf node_modules -cd ./framework && rm -rf node_modules -cd ./services/blockchain-app-registry && rm -rf node_modules -cd ./services/blockchain-connector && rm -rf node_modules -cd ./services/blockchain-coordinator && rm -rf node_modules -cd ./services/blockchain-indexer && rm -rf node_modules -cd ./services/transaction-statistics && rm -rf node_modules -cd ./services/fee-estimator && rm -rf node_modules -cd ./services/market && rm -rf node_modules -cd ./services/gateway && rm -rf node_modules -cd ./services/export && rm -rf node_modules -cd ./services/template && rm -rf node_modules -cd ./tests && rm -rf node_modules ----- -==== - -=== Install npm dependencies - ----- -make build-local ----- - -=== Reset the Lisk Service database - -To reset the database of Lisk Service, drop the respective MySQL and Redis databases. - -==== Drop the MySQL database - -. Stop Lisk Service -+ ----- -yarn stop ----- - -. Login to MySQL with the `lisk` user. -+ ----- -mysql -u lisk -ppassword ----- - -. Drop the database. -+ ----- -mysql> drop database lisk; ----- - -. Create a fresh database. -+ ----- -mysql> create database lisk; ----- - -. Quit MySQL. -+ ----- -mysql> quit; ----- - -NOTE: The process to re-index all the data commences after Lisk Service starts again following a database reset. The process can be rather time-consuming and could take several hours, depending on the length of the chain. - -==== Flush Redis DB - -Reset the databases for Redis after dropping the MySQL database: - ----- -redis-cli flushall ----- - -[NOTE] -==== -The `flushall` command truncates all existing Redis databases: - -> Deletes all the keys of all the existing databases, not just the current selected one. This command never fails. - -For more information, check the Redis documentation: {url_FLUSHALL}[FLUSHALL]. - -To flush only a particular database in Redis, execute the following command instead: - ----- -redis-cli -n flushdb ----- -==== - -You can start Lisk Service again with the <> command. From eece577e2963fada683a1a5225fff4b483063366 Mon Sep 17 00:00:00 2001 From: chris529 Date: Thu, 5 Oct 2023 16:28:15 +0200 Subject: [PATCH 05/15] update-in-source.adoc --- docs/antora/modules/ROOT/pages/management/source.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index 04b18122bf..7196680a8a 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -18,7 +18,7 @@ Moreover, we'll also talk about the steps to reset a Lisk Service node. TIP: The process ID of each PM2-managed process can be seen by executing the <> command. To learn more about PM2 log management please refer the {url_pm2_management}[PM2 logs documentation]. -NOTE: To upgrade Lisk Service to a desired version, please check out the specific version with *`git checkout `* and follow the existing process. +NOTE: To upgrade Lisk Service to a desired version, please check out the specific version with *`git checkout `*, and follow the existing process. == Various PM2 commands From da0f0bd5765d279da39cdb4b5173ebc1b2509d5e Mon Sep 17 00:00:00 2001 From: chris529 Date: Fri, 13 Oct 2023 11:55:24 +0200 Subject: [PATCH 06/15] update in source.adoc --- docs/antora/modules/ROOT/pages/management/source.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index deca4ee4cc..d051a25204 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -18,7 +18,7 @@ Moreover, we'll also talk about the steps to reset a Lisk Service node. TIP: The process ID of each PM2-managed process can be seen by executing the <> command. To learn more about PM2 log management please refer the {url_pm2_management}[PM2 logs documentation]. -NOTE: To upgrade Lisk Service to a desired version, please check out the specific version with *`git checkout `*, and follow the existing process. +NOTE: To upgrade Lisk Service to a desired version, please check out the specific version with *`git checkout `*, and start Lisk Service as shown below: == Various PM2 commands From 4903212699633115fcc3f8b09b48916b3588e30d Mon Sep 17 00:00:00 2001 From: chris529 Date: Fri, 13 Oct 2023 12:00:45 +0200 Subject: [PATCH 07/15] update in source.adoc --- docs/antora/modules/ROOT/pages/management/source.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index d051a25204..d1dc4b9cea 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -18,7 +18,7 @@ Moreover, we'll also talk about the steps to reset a Lisk Service node. TIP: The process ID of each PM2-managed process can be seen by executing the <> command. To learn more about PM2 log management please refer the {url_pm2_management}[PM2 logs documentation]. -NOTE: To upgrade Lisk Service to a desired version, please check out the specific version with *`git checkout `*, and start Lisk Service as shown below: +NOTE: To upgrade Lisk Service to a desired version, please check out the specific version with *`git checkout `*, and then start Lisk Service as shown in the list of commands below. == Various PM2 commands From 5f2ae7cd999c7a3771dba9201d5ecde861c87b5d Mon Sep 17 00:00:00 2001 From: chris529 Date: Tue, 17 Oct 2023 10:25:15 +0200 Subject: [PATCH 08/15] update in source.adoc --- .../modules/ROOT/pages/management/source.adoc | 103 +++++++++++++++++- 1 file changed, 102 insertions(+), 1 deletion(-) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index d1dc4b9cea..c5db33a7bc 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -10,6 +10,7 @@ Mona Bärenfänger Muhammad Talha > command. To learn more about PM2 log management please refer the {url_pm2_management}[PM2 logs documentation]. -NOTE: To upgrade Lisk Service to a desired version, please check out the specific version with *`git checkout `*, and then start Lisk Service as shown in the list of commands below. == Various PM2 commands @@ -364,3 +364,104 @@ redis-cli -n flushdb ==== You can start Lisk Service again with the <> command. + + +== Upgrade Lisk Service + +To upgrade Lisk Service to a desired version, please follow the steps listed below. + +1. Stop the existing running version of Lisk Service with the command listed below. + +---- +pm2 stop ecosystem.config.js +---- + +.Response +[%collapsible] +==== +.Example output +[source,bash] +---- +[PM2] [lisk-service-blockchain-app-registry](1) ✓ +[PM2] [lisk-service-gateway](0) ✓ +[PM2] [lisk-service-blockchain-indexer](3) ✓ +[PM2] [lisk-service-blockchain-connector](2) ✓ +[PM2] [lisk-service-blockchain-coordinator](4) ✓ +[PM2] [lisk-service-fee-estimator](5) ✓ +[PM2] [lisk-service-transaction-statistics](6) ✓ +[PM2] [lisk-service-market](7) ✓ +[PM2] [lisk-service-export](8) ✓ +┌------------------------------------------------------------------------------------------------------------------------------------------------------------------------┐ +│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ +├------------------------------------------------------------------------------------------------------------------------------------------------------------------------┤ +│ 1 │ lisk-service-blockchain-app-registry │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 32 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 2 │ lisk-service-blockchain-connector │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 0 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 4 │ lisk-service-blockchain-coordinator │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 0 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 3 │ lisk-service-blockchain-indexer │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 32 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 8 │ lisk-service-export │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 5 │ lisk-service-fee-estimator │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 0 │ lisk-service-gateway │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 7 │ lisk-service-market │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +│ 6 │ lisk-service-transaction-statistics │ default │ 0.7.0-… │ fork │ 0 │ 0 │ 30 │ stopped │ 0% │ 0b │ XYZ │ disabled │ +└------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ +---- +==== + + +2. Checkout the specific version with *`git checkout `*. +---- +git checkout v0.7.0 +---- + +3. Update the npm dependencies by executing the following command. +---- +make build-local +---- + +3. Restart Lisk Service with the following command. + + +---- +pm2 start ecosystem.config.js +---- + +.Response +[%collapsible] +==== +.Example output +---- +[PM2] Applying action restartProcessId on app [lisk-service-gateway](ids: [ 0 ]) +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-app-registry](ids: [ 1 ]) +[PM2] [lisk-service-gateway](0) ✓ +[PM2] [lisk-service-blockchain-app-registry](1) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-connector](ids: [ 2 ]) +[PM2] [lisk-service-blockchain-connector](2) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-indexer](ids: [ 3 ]) +[PM2] [lisk-service-blockchain-indexer](3) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-blockchain-coordinator](ids: [ 4 ]) +[PM2] [lisk-service-blockchain-coordinator](4) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-fee-estimator](ids: [ 5 ]) +[PM2] [lisk-service-fee-estimator](5) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-transaction-statistics](ids: [ 6 ]) +[PM2] [lisk-service-transaction-statistics](6) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-market](ids: [ 7 ]) +[PM2] [lisk-service-market](7) ✓ +[PM2] Applying action restartProcessId on app [lisk-service-export](ids: [ 8 ]) +[PM2] [lisk-service-export](8) ✓ +┌----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┐ +│ id │ name │ namespace │ version │ mode │ pid │ uptime │ ↺ │ status │ cpu │ mem │ user │ watching │ +├----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┤ +│ 1 │ lisk-service-blockchain-app-registry │ default │ 0.7.0-… │ fork │ 33328 │ 0s │ 16 │ online │ 0% │ 65.5mb │ XYZ │ disabled │ +│ 2 │ lisk-service-blockchain-connector │ default │ 0.7.0-… │ fork │ 33331 │ 0s │ 0 │ online │ 0% │ 63.8mb │ XYZ │ disabled │ +│ 4 │ lisk-service-blockchain-coordinator │ default │ 0.7.0-… │ fork │ 33341 │ 0s │ 0 │ online │ 0% │ 54.1mb │ XYZ │ disabled │ +│ 3 │ lisk-service-blockchain-indexer │ default │ 0.7.0-… │ fork │ 33338 │ 0s │ 16 │ online │ 0% │ 54.3mb │ XYZ │ disabled │ +│ 8 │ lisk-service-export │ default │ 0.7.0-… │ fork │ 33355 │ 0s │ 15 │ online │ 0% │ 14.1mb │ XYZ │ disabled │ +│ 5 │ lisk-service-fee-estimator │ default │ 0.7.0-… │ fork │ 33346 │ 0s │ 15 │ online │ 0% │ 46.9mb │ XYZ │ disabled │ +│ 0 │ lisk-service-gateway │ default │ 0.7.0-… │ fork │ 33326 │ 0s │ 15 │ online │ 0% │ 65.6mb │ XYZ │ disabled │ +│ 7 │ lisk-service-market │ default │ 0.7.0-… │ fork │ 33351 │ 0s │ 15 │ online │ 0% │ 36.9mb │ XYZ │ disabled │ +│ 6 │ lisk-service-transaction-statistics │ default │ 0.7.0-… │ fork │ 33348 │ 0s │ 15 │ online │ 0% │ 43.5mb │ XYZ │ disabled │ +└----------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ +---- +==== + +NOTE: Please check the :url_rel...release notes for the relevant version to see if the existing databases need to be flushed. From e2d4dd8d1350ba882565a2d54e4e3cbd7d2d58eb Mon Sep 17 00:00:00 2001 From: chris529 Date: Tue, 17 Oct 2023 11:27:38 +0200 Subject: [PATCH 09/15] update in source.adoc --- .../modules/ROOT/pages/management/source.adoc | 16 +++++----------- 1 file changed, 5 insertions(+), 11 deletions(-) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index c5db33a7bc..0f14ed45f7 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -370,7 +370,7 @@ You can start Lisk Service again with the <> command. To upgrade Lisk Service to a desired version, please follow the steps listed below. -1. Stop the existing running version of Lisk Service with the command listed below. +1.Stop the existing running version of Lisk Service. ---- pm2 stop ecosystem.config.js @@ -406,21 +406,15 @@ pm2 stop ecosystem.config.js └------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ ---- ==== - - -2. Checkout the specific version with *`git checkout `*. +2.Checkout the version with *`git checkout `*. ---- git checkout v0.7.0 ---- - -3. Update the npm dependencies by executing the following command. +3.Update the npm dependencies by executing the following command. ---- make build-local ---- - -3. Restart Lisk Service with the following command. - - +4.Restart Lisk Service with the following command. ---- pm2 start ecosystem.config.js ---- @@ -464,4 +458,4 @@ pm2 start ecosystem.config.js ---- ==== -NOTE: Please check the :url_rel...release notes for the relevant version to see if the existing databases need to be flushed. +NOTE: Please check the {url_rel_notes}[release notes] for the relevant version to see if the existing databases need to be flushed. From 2126e73857ec4c4861864bdbbde5bcfcec2da830 Mon Sep 17 00:00:00 2001 From: chris529 Date: Tue, 17 Oct 2023 17:04:56 +0200 Subject: [PATCH 10/15] update in source.adoc --- .../modules/ROOT/pages/management/source.adoc | 20 ++++++++++++------- 1 file changed, 13 insertions(+), 7 deletions(-) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index 5f74a843cf..e5405c61c0 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -379,12 +379,12 @@ You can start Lisk Service again with the <> command. To upgrade Lisk Service to a desired version, please follow the steps listed below. -1.Stop the existing running version of Lisk Service. - +. Stop the existing running version of Lisk Service. ++ ---- pm2 stop ecosystem.config.js ---- - ++ .Response [%collapsible] ==== @@ -415,19 +415,25 @@ pm2 stop ecosystem.config.js └------------------------------------------------------------------------------------------------------------------------------------------------------------------------┘ ---- ==== -2.Checkout the version with *`git checkout `*. + +. Checkout the version with *`git checkout `*. ++ ---- git checkout v0.7.0 ---- -3.Update the npm dependencies by executing the following command. + +. Update the npm dependencies by executing the following command. ++ ---- make build-local ---- -4.Restart Lisk Service with the following command. + +. Restart Lisk Service with the following command. ++ ---- pm2 start ecosystem.config.js ---- - ++ .Response [%collapsible] ==== From 1cbda96ae26621c843c718712efbb864935998f5 Mon Sep 17 00:00:00 2001 From: chris529 Date: Wed, 18 Oct 2023 11:39:07 +0200 Subject: [PATCH 11/15] Update docs/antora/modules/ROOT/pages/management/source.adoc Co-authored-by: Sameer --- docs/antora/modules/ROOT/pages/management/source.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index e5405c61c0..19948bec11 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -377,7 +377,7 @@ You can start Lisk Service again with the <> command. == Upgrade Lisk Service -To upgrade Lisk Service to a desired version, please follow the steps listed below. +To upgrade Lisk Service to a desired version, please follow the steps listed below. To find all the tagged versions for Lisk Service, please check the available tags (https://github.com/LiskHQ/lisk-service/tags) on GitHub. . Stop the existing running version of Lisk Service. + From 469bc53b03f2db679c633a785cb08d351ce7affc Mon Sep 17 00:00:00 2001 From: chris529 Date: Wed, 18 Oct 2023 11:39:23 +0200 Subject: [PATCH 12/15] Update docs/antora/modules/ROOT/pages/management/source.adoc Co-authored-by: Sameer --- docs/antora/modules/ROOT/pages/management/source.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index 19948bec11..61cdc6d86f 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -473,4 +473,4 @@ pm2 start ecosystem.config.js ---- ==== -NOTE: Please check the {url_rel_notes}[release notes] for the relevant version to see if the existing databases need to be flushed. +NOTE: Please check the {url_rel_notes}[GitHub release notes] for the relevant version to verify if the existing databases need to be flushed. From 68fea3860d8cd7b6d977785d8b4dfcadf8dc17cd Mon Sep 17 00:00:00 2001 From: chris529 Date: Wed, 18 Oct 2023 11:50:48 +0200 Subject: [PATCH 13/15] update in source.adoc --- docs/antora/modules/ROOT/pages/management/source.adoc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index 61cdc6d86f..9d8eda0026 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -13,6 +13,8 @@ Mona Bärenfänger Muhammad Talha Date: Fri, 20 Oct 2023 11:57:04 +0200 Subject: [PATCH 14/15] Update docs/antora/modules/ROOT/pages/management/source.adoc Co-authored-by: Sameer --- docs/antora/modules/ROOT/pages/management/source.adoc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index 9d8eda0026..265f5bc6ba 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -11,9 +11,9 @@ Mona Bärenfänger Muhammad Talha Date: Fri, 20 Oct 2023 12:00:37 +0200 Subject: [PATCH 15/15] Update docs/antora/modules/ROOT/pages/management/source.adoc Co-authored-by: Sameer --- docs/antora/modules/ROOT/pages/management/source.adoc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/antora/modules/ROOT/pages/management/source.adoc b/docs/antora/modules/ROOT/pages/management/source.adoc index 265f5bc6ba..7d858d9cd7 100644 --- a/docs/antora/modules/ROOT/pages/management/source.adoc +++ b/docs/antora/modules/ROOT/pages/management/source.adoc @@ -379,7 +379,7 @@ You can start Lisk Service again with the <> command. == Upgrade Lisk Service -To upgrade Lisk Service to a desired version, please follow the steps listed below. To find all the tagged versions for Lisk Service, please check the available tags (https://github.com/LiskHQ/lisk-service/tags) on GitHub. +To upgrade Lisk Service to a desired version, please follow the steps listed below. To find all the tagged versions for Lisk Service, please check the {url_tags}[available tags] on GitHub. . Stop the existing running version of Lisk Service. +