Docker based deployment fails with provision.sh error
Failed to deploy docker based testnet.
- Pull latest code (here)
-
make runcauses below error. It seemsprovision.shdoesn't work correctly. Script keeps showing this log.
g2m_btp_moonbeam | waiting for an other BTP to finish provisioning settings...
g2m_btp_icon | 2021-10-29 09:17:42 API/INIT: RPC methods not decorated: debug_traceBlockByHash, debug_traceBlockByNumber, debug_traceTransaction
g2m_btp_icon | 2021-10-29 09:17:42 METADATA: Unknown types found, no types for AssetRegistrarMetadata, AssetType, AuthorId, BlockV0, Collator2, CollatorSnapshot, CurrencyId, ExitQ, InflationInfo, Nominator2, NominatorAdded, OrderedSet, ParachainBondConfig, RegistrationInfo, RelayChainAccountId, RewardInfo, RoundInfo, VestingBlockNumber
g2m_btp_icon | relay genesis hash: 0xb0a8d493285c2df73290dfb7e61f870f17b41801197a149ca93654499ea3dafe
g2m_btp_icon | relay chain name: "Kusama"
g2m_btp_icon | para genesis hash: 0xde0ba5802ad6fc3758e5d18ba847c910ab94702359a76de94b18940de486d33a
g2m_btp_icon | para chain name: "Moonbase Development Testnet"
g2m_btp_icon | Get metadata of relay chain...
g2m_btp_moonbeam | waiting for an other BTP to finish provisioning settings...
g2m_btp_icon | Get metadata of para chain...
g2m_btp_moonbeam | waiting for an other BTP to finish provisioning settings...
g2m_btp_icon | Done in 28.68s.
g2m_btp_icon | parachain height:0x41 block_hash:0xb9ee93e624dacd599df0ac8bc19bec3da2a3ab818bc63158e6df854aae54f23c
g2m_btp_icon | "0x9ee2c58efe222364b8a761050a90ccfef185d3f3f4d2fdf33941ed67ee8da26a"
g2m_btp_icon | /entrypoint.sh: /btpsimple/scripts/provision.sh: line 97: --param: not found
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_moonbeam | waiting for an other BTP to finish provisioning settings...
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
g2m_btp_moonbeam | waiting for an other BTP to finish provisioning settings...
g2m_btp_icon | Usage: goloop rpc txresult HASH [flags]
g2m_btp_icon | Error: accepts 1 arg(s), received 0
@tiendq I've opened a PR to fix this issue.
@trmaphi When running docker-compose, I got this error.

Is there a new change on the contracts?
Is there a new change on the contracts?
I guess there are changes in contracts, as far as I know they has spent at least last 2 weeks to fix several issues with Moonbeam's changes.
Hiya was just wondering if this has been fixed as i seem to be having the same issue. When i try to run "make tansfer_icx" which runs this command "docker-compose exec btp_icon sh /btpsimple/scripts/transfer_icx.sh". All i seem to be getting back is "Provisioning not done yet". All of this happening while the g2m_btp_moonbeam it just keeps outputting:
g2m_btp_moonbeam | waiting for an other BTP to finish provisioning settings...
g2m_btp_icon | Error: jsonrpc: code: -31002, message: Pending, data:
Hiya was just wondering if this has been fixed as i seem to be having the same issue. When i try to run "make tansfer_icx" which runs this command "docker-compose exec btp_icon sh /btpsimple/scripts/transfer_icx.sh". All i seem to be getting back is "Provisioning not done yet". All of this happening while the g2m_btp_moonbeam it just keeps outputting:
g2m_btp_moonbeam | waiting for an other BTP to finish provisioning settings... g2m_btp_icon | Error: jsonrpc: code: -31002, message: Pending, data:
waiting for an other BTP to finish provisioning settings often takes at most 20 minutes. If not, there is something wrong.
In the time starting docker-compose if the got any message like g2m_btp_icon | Error: jsonrpc: code: -31002, message: Pending, data: It means the BTP server is frozen. You have to re-run the docker-compose by command clean then start again.
This problem happens often if you use a MacBook. I suggest using an ubuntu pc instead.
Hiya i am using a ubuntu machine to run this example :
"Distributor ID: Ubuntu Description: Ubuntu 20.04.3 LTS Release: 20.04 Codename: focal"
I was just wondering how to re run the docker-compose clean command you are talking off, as in order to get the BTP up and running all i do is run the command "make run". I assume that i need to change the makefile to include the clean command when we do the run.
No, Don't do that. Clean is clean. Run is run. When developing, sometimes I just want to stop and run. Cleaning will make deployment restart from zero. It is a waste of time.
Ok i understood your message @canhlinh i get that there is no point of me doing a clean. Still seem to be having the same issue even when waiting after 20 mins , as @tiendq suggested. I have attached a file which has the logs to g2m_btp_icon showing it gets jsonrpc : code -31002, after trying to deploy the kusmaDecoder. Also something else that looks a bit weird is when trying to exit out of the application, i get a read time out for g2m_goloop. Please do take a look at the error file i have linked down below. error.txt
I've took a look onto your file. It's the same problem.
g2m_btp_icon | Error: jsonrpc: code: -31002, message: Pending, data: <nil>
g2m_btp_moonbeam | waiting for an other BTP to finish provisioning settings...
g2m_btp_icon | Error: jsonrpc: code: -31002, message: Pending, data: <nil>
Goloop got frozen once more. This error will never occur. If you're working on a powerful computer. I'm not sure why this is happening on a low-profile PC.
Maybe i should increase docker cpu and the ram that is currently using from my machine? Below i have listed all of the containers and there stats : g2m_btp_moonbeam 0.00% 480KiB / 15.33GiB 0.00% 7.62kB / 0B 0B / 0B g2m_btp_icon 0.00% 801.7MiB / 15.33GiB 5.11% 201MB / 4.24MB 54.4MB / 1.22GB 12 g2m_goloop 0.31% 176.7MiB / 15.33GiB 1.13% 141kB / 6.17kB 4.24MB / 9.19MB 38 g2m_moonbeam 6.00% 215.1MiB / 15.33GiB 1.37% 1.49MB / 3.34MB 3.29MB / 606kB 48
If you are using Ubuntu. There is no CPU limitation for running docker.
Only a limitation here is the power of your CPU.
Look at my CPU, i still got this problem when running Goloop.
But when running in a cloud VPS with higher CPU power. I never got this issue.
All containers are working fine. But Goloop is not able to mine new blocks. I don't know why. You can check it by make calling some API to Goloop container.
I just try to run the docker-compose. I still work on my PC. I deployed them in WSL ubuntu.
So correct me if i am wrong @canhlinh you understand the issue i seem to be having, and when you run the docker-compose on your own machine you seem to get the same issue as me. However when you deploy them in WSL ubuntu it works? CPU info btw : Intel(R) Core(TM) i7-10510U CPU @ 1.80GHz
@Effort-Less No, On my PC this error comes out not usually. Even on both ubuntu and WSL
I think the issue here is your PC is weak. it's a laptop.

Haha. Definitely, your CPU isn't powerful enough to execute Goloop. When Goloop is processing a complex function in a smart-contract, it will be frozen.
Let try to spam Goloop with some complex function in smart-contract ( SCORE). You will see it.
Maybe i am wrong but i am not sure if this is the case that my CPU isn't powerful enough to execute the Goloop, the first reason being that a colleague of mine is able to run it on a identical machine. Also i am able to run the btp/docker-compose/goloop2goloop project by building it and then running the "make run-test-scenario", Which seems to work fine. I appreciate your help @canhlinh in trying to get this sorted.
@Effort-Less I don't know why but I'm sure it requires a huge hardware resource to run BTP in docker. For your reference, this is configure of our test machine (EC2 instance) which I was able to run BTP for long time in the past:
Intel(R) Xeon(R) Platinum 8124M CPU @ 3.00GHz 8 cores 32 GB RAM