fabric-samples
fabric-samples copied to clipboard
Error: "After 5 attempts, peer0.org1 has failed to join channel 'mychannel'"
OS: Linux 6.1.11-arch1-1 x86_64 Docker version 23.0.1, build a5ee5b1dfc
run:
$ ./fabcar/startFabric.sh javascript
result:
Channel 'mychannel' created
Joining org1 peer to the channel...
Using organization 1
+ peer channel join -b ./channel-artifacts/mychannel.block
+ res=1
+ peer channel join -b ./channel-artifacts/mychannel.block
+ res=1
+ peer channel join -b ./channel-artifacts/mychannel.block
+ res=1
+ peer channel join -b ./channel-artifacts/mychannel.block
+ res=1
2023-02-13 17:00:15.727 +05 0001 ERRO [comm.tls] ClientHandshake -> Client TLS handshake failed after 207.71µs with error: EOF remoteaddress=[::1]:7051
2023-02-13 17:00:16.728 +05 0002 ERRO [comm.tls] ClientHandshake -> Client TLS handshake failed after 247.081µs with error: EOF remoteaddress=[::1]:7051
2023-02-13 17:00:18.158 +05 0003 ERRO [comm.tls] ClientHandshake -> Client TLS handshake failed after 234.759µs with error: EOF remoteaddress=[::1]:7051
Error: error getting endorser client for channel: endorser client failed to connect to localhost:7051: failed to create new connection: context deadline exceeded
After 5 attempts, peer0.org1 has failed to join channel 'mychannel'
If you delete everything and download it again, then everything starts working until the first reboot.
After you shut down the network using the network.sh down
, make sure the container volumes are also removed. You can try running docker volume rm $(docker volume ls -q) -f
(this will remove all the volumes, be cautious)
Suggested way to remove docker containers doesn't work. I fixed the problem by editing the line in startFabric.sh
./network.sh up createChannel -ca #-s couchdb
./network.sh down
is having issue on removing the container's volumes. Volume removing command with the volume names, use the command prefixed with compose_
instead of docker_
. Just change it to work properly.