Hi DAML team,
I am trying to run DAML on fabric on my system, I am following the link :- GitHub - digital-asset/daml-on-fabric: Enabling DAML applications to run on Hyperledger Fabric
My system specs :-
docker-compose - docker-compose version 1.27.4, build 40524192
docker - Docker version 19.03.13, build 4484c46d9d
java - java version "11.0.9" 2020-10-20 LTS
Java(TM) SE Runtime Environment 18.9 (build 11.0.9+7-LTS)
Java HotSpot(TM) 64-Bit Server VM 18.9 (build 11.0.9+7-LTS, mixed mode)
DAML - 1.12.0 (default SDK version for new projects)
Fabric tools - hyperledger/fabric-tools:2.2
Now after generating the crypto material and starting fabric. I run the command -
sbt "run --port 6865 --role provision"
After this this error pops up
May 12, 2021 2:32:03 PM org.hyperledger.fabric.sdk.Channel sendProposalToPeers
SEVERE: Channel Channel{id: 15, name: } sending proposal with transaction 3c3695876ffa73a615a8a13c2bdbfc1f97f25e6b578599bf3de8eb17b3dca584 to Peer{ id: 2, name: peer0, channelName: mainchannel, url: grpcs://localhost:10051} failed because of timeout(60000 milliseconds) expiration
java.util.concurrent.TimeoutException
at java.base/java.util.concurrent.CompletableFuture.timedGet(CompletableFuture.java:1886)
at java.base/java.util.concurrent.CompletableFuture.get(CompletableFuture.java:2021)
at org.hyperledger.fabric.sdk.Channel.sendProposalToPeers(Channel.java:4942)
at org.hyperledger.fabric.sdk.Channel.sendLifecycleInstallProposal(Channel.java:3787)
at org.hyperledger.fabric.sdk.HFClient.sendLifecycleInstallChaincodeRequest(HFClient.java:546)
at com.daml.FabricContext.lifecycleInstallChaincode(FabricContext.java:313)
at com.daml.FabricContext.runChannel(FabricContext.java:244)
at com.daml.FabricContext.initNetworkConfiguration(FabricContext.java:169)
at com.daml.FabricContext.<init>(FabricContext.java:103)
at com.daml.DAMLKVConnector.<init>(DAMLKVConnector.java:74)
at com.daml.DAMLKVConnector.get(DAMLKVConnector.java:30)
at com.daml.DamlOnFabricServer$.delayedEndpoint$com$daml$DamlOnFabricServer$1(DamlOnFabricServer.scala:65)
at com.daml.DamlOnFabricServer$delayedInit$body.apply(DamlOnFabricServer.scala:48)
at scala.Function0.apply$mcV$sp(Function0.scala:39)
at scala.Function0.apply$mcV$sp$(Function0.scala:39)
at scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:17)
at scala.App.$anonfun$main$1$adapted(App.scala:80)
at scala.collection.immutable.List.foreach(List.scala:392)
at scala.App.main(App.scala:80)
at scala.App.main$(App.scala:78)
at com.daml.DamlOnFabricServer$.main(DamlOnFabricServer.scala:48)
at com.daml.DamlOnFabricServer.main(DamlOnFabricServer.scala)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at sbt.Run.invokeMain(Run.scala:115)
at sbt.Run.execute$1(Run.scala:79)
at sbt.Run.$anonfun$runWithLoader$4(Run.scala:92)
at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:23)
at sbt.util.InterfaceUtil$$anon$1.get(InterfaceUtil.scala:10)
at sbt.TrapExit$App.run(TrapExit.scala:257)
at java.base/java.lang.Thread.run(Thread.java:834)
Caught an exception running Channel mainchannel
org.hyperledger.fabric.sdk.exception.ProposalException: Status of install proposal did not ret ok for Peer{ id: 2, name: peer0, channelName: mainchannel, url: grpcs://localhost:10051}, FAILURE
at org.hyperledger.fabric.sdk.LifecycleInstallChaincodeProposalResponse.getPackageId(LifecycleInstallChaincodeProposalResponse.java:36)
at com.daml.FabricContext.lifecycleInstallChaincode(FabricContext.java:319)
at com.daml.FabricContext.runChannel(FabricContext.java:244)
at com.daml.FabricContext.initNetworkConfiguration(FabricContext.java:169)
at com.daml.FabricContext.<init>(FabricContext.java:103)
at com.daml.DAMLKVConnector.<init>(DAMLKVConnector.java:74)
at com.daml.DAMLKVConnector.get(DAMLKVConnector.java:30)
at com.daml.DamlOnFabricServer$.delayedEndpoint$com$daml$DamlOnFabricServer$1(DamlOnFabricServer.scala:65)
at com.daml.DamlOnFabricServer$delayedInit$body.apply(DamlOnFabricServer.scala:48)
at scala.Function0.apply$mcV$sp(Function0.scala:39)
at scala.Function0.apply$mcV$sp$(Function0.scala:39)
at scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:17)
at scala.App.$anonfun$main$1$adapted(App.scala:80)
at scala.collection.immutable.List.foreach(List.scala:392)
at scala.App.main(App.scala:80)
at scala.App.main$(App.scala:78)
at com.daml.DamlOnFabricServer$.main(DamlOnFabricServer.scala:48)
at com.daml.DamlOnFabricServer.main(DamlOnFabricServer.scala)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.base/java.lang.reflect.Method.invoke(Method.java:566)
at sbt.Run.invokeMain(Run.scala:115)
at sbt.Run.execute$1(Run.scala:79)
at sbt.Run.$anonfun$runWithLoader$4(Run.scala:92)
at scala.runtime.java8.JFunction0$mcV$sp.apply(JFunction0$mcV$sp.java:23)
at sbt.util.InterfaceUtil$$anon$1.get(InterfaceUtil.scala:10)
at sbt.TrapExit$App.run(TrapExit.scala:257)
at java.base/java.lang.Thread.run(Thread.java:834)
Admin@org1.example.com private key: /home/user/Fabric/daml_on_fabric_new/daml-on-fabric/src/test/fixture/tmp/data/crypto-config/peerOrganizations/org1.example.com/users/Admin@org1.example.com/msp/keystore/priv_sk
Admin@org1.example.com sign cert: /home/user/Fabric/daml_on_fabric_new/daml-on-fabric/src/test/fixture/tmp/data/crypto-config/peerOrganizations/org1.example.com/users/Admin@org1.example.com/msp/signcerts/Admin@org1.example.com-cert.pem
Admin@org2.example.com private key: /home/user/Fabric/daml_on_fabric_new/daml-on-fabric/src/test/fixture/tmp/data/crypto-config/peerOrganizations/org2.example.com/users/Admin@org2.example.com/msp/keystore/priv_sk
Admin@org2.example.com sign cert: /home/user/Fabric/daml_on_fabric_new/daml-on-fabric/src/test/fixture/tmp/data/crypto-config/peerOrganizations/org2.example.com/users/Admin@org2.example.com/msp/signcerts/Admin@org2.example.com-cert.pem
That's all folks!
Admin@org1.example.com private key: /home/user/Fabric/daml_on_fabric_new/daml-on-fabric/src/test/fixture/tmp/data/crypto-config/peerOrganizations/org1.example.com/users/Admin@org1.example.com/msp/keystore/priv_sk
Admin@org1.example.com sign cert: /home/user/Fabric/daml_on_fabric_new/daml-on-fabric/src/test/fixture/tmp/data/crypto-config/peerOrganizations/org1.example.com/users/Admin@org1.example.com/msp/signcerts/Admin@org1.example.com-cert.pem
[error] (run-main-0) com.daml.FabricContextException: response {
[error] status: 500
[error] message: "make sure the chaincode daml_on_fabric has been successfully defined on channel mainchannel and try again: chaincode daml_on_fabric not found"
[error] }
[error] com.daml.FabricContextException: response {
[error] status: 500
[error] message: "make sure the chaincode daml_on_fabric has been successfully defined on channel mainchannel and try again: chaincode daml_on_fabric not found"
[error] }
[error]
[error] at com.daml.FabricContext.queryChaincode(FabricContext.java:578)
[error] at com.daml.FabricContext.queryChaincode(FabricContext.java:558)
[error] at com.daml.FabricContext.queryChaincode(FabricContext.java:554)
[error] at com.daml.DAMLKVConnector.getLedgerId(DAMLKVConnector.java:316)
[error] at com.daml.DAMLKVConnector.<init>(DAMLKVConnector.java:90)
[error] at com.daml.DAMLKVConnector.get(DAMLKVConnector.java:30)
[error] at com.daml.DamlOnFabricServer$.delayedEndpoint$com$daml$DamlOnFabricServer$1(DamlOnFabricServer.scala:65)
[error] at com.daml.DamlOnFabricServer$delayedInit$body.apply(DamlOnFabricServer.scala:48)
[error] at scala.Function0.apply$mcV$sp(Function0.scala:39)
[error] at scala.Function0.apply$mcV$sp$(Function0.scala:39)
[error] at scala.runtime.AbstractFunction0.apply$mcV$sp(AbstractFunction0.scala:17)
[error] at scala.App.$anonfun$main$1$adapted(App.scala:80)
[error] at scala.collection.immutable.List.foreach(List.scala:392)
[error] at scala.App.main(App.scala:80)
[error] at scala.App.main$(App.scala:78)
[error] at com.daml.DamlOnFabricServer$.main(DamlOnFabricServer.scala:48)
[error] at com.daml.DamlOnFabricServer.main(DamlOnFabricServer.scala)
[error] at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
[error] at java.base/jdk.internal.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
[error] at java.base/jdk.internal.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
[error] at java.base/java.lang.reflect.Method.invoke(Method.java:566)
[error] stack trace is suppressed; run last Compile / bgRun for the full output
May 12, 2021 2:32:03 PM org.hyperledger.fabric.sdk.Channel getNextEvent
WARNING: java.lang.InterruptedException
May 12, 2021 2:32:03 PM org.hyperledger.fabric.sdk.Channel lambda$startEventQue$13
WARNING: GOT null block event.
[error] Nonzero exit code: 1
[error] (Compile / run) Nonzero exit code: 1
[error] Total time: 87 s (01:27), completed 12-May-2021, 2:32:03 PM
I researched about this :- daml_on_fabric chaincode can not installed · Issue #31 · digital-asset/daml-on-fabric · GitHub
I am not using a mac system, I am using ubuntu 18.04 .
Please help, as this issue pops up frequently.
Thanks