Tools, FAQ, Tutorials:
Watch Peer Container Log
How to watch the log file of Peer Container Log?
✍: FYIcenter.com
You can follow this tutorial to watch the log file of a peer container:
1. Set up a new terminal on the hosting system to follow the log file of the "peer0.org1.example.com" container:
$ docker logs --tail 10 -f peer0.org1.example.com [gossip.comm] func1 -> WARN 2e5e9 peer1.org2.example.com:7051, \ PKIid:30999a1ad969be31510d17761c78eaed1a21d163353a63226dd95d807076b1df isn't responsive: EOF [gossip.discovery] expireDeadMembers -> WARN 2e5ea Entering \ [30999a1ad969be31510d17761c78eaed1a21d163353a63226dd95d807076b1df] [gossip.discovery] expireDeadMembers -> WARN 2e5eb Closing connection to Endpoint: peer1.org2.example.com:7051, InternalEndpoint: , \ PKI-ID: 30999a1ad969be31510d17761c78eaed1a21d163353a63226dd95d807076b1df, Metadata: [gossip.discovery] expireDeadMembers -> WARN 2e5ec Exiting ... [gossip.comm] func1 -> WARN 2e601 peer1.org2.example.com:7051, \ PKIid:30999a1ad969be31510d17761c78eaed1a21d163353a63226dd95d807076b1df isn't responsive: EOF [gossip.discovery] expireDeadMembers -> WARN 2e602 Entering \ [30999a1ad969be31510d17761c78eaed1a21d163353a63226dd95d807076b1df] [gossip.discovery] expireDeadMembers -> WARN 2e603 Closing connection to Endpoint: peer1.org2.example.com:7051, InternalEndpoint: , \ PKI-ID: 30999a1ad969be31510d17761c78eaed1a21d163353a63226dd95d807076b1df, Metadata: [gossip.discovery] expireDeadMembers -> WARN 2e604 Exiting
You may notice that the last log messages keep coming up. It seems to say that the "peer1.org2.example.com" is dead member in the network.
2. Use another terminal to query the chaincode:
$ docker exec -it cli bash
bash-4.4# peer chaincode query -C mychannel -n mycc -c '{"Args":["query","a"]}'
90
Two new messages printed on the peer log window, one warning and one information:
[endorser] callChaincode -> INFO 2e84e [mychannel][8b392ade] Entry chaincode: name:"mycc" [endorser] callChaincode -> INFO 2e84f [mychannel][8b392ade] Exit chaincode: name:"mycc" (9ms) [comm.grpc.server] 1 -> INFO 2e850 unary call completed grpc.service=protos.Endorser \ grpc.method=ProcessProposal grpc.peer_address=192.168.1.7:35616 \ grpc.code=OK grpc.call_duration=10.295092ms
⇒ Peer Containers Not Joined to Channel
⇐ Watch "orderer" Container Log
2020-07-07, ∼1943🔥, 0💬
Popular Posts:
How to add request body examples to my Azure API operation to make it more user friendly? If you hav...
How to use urllib.parse.urlencode() function to encode HTTP POST data? My form data has special char...
How to register and get an application ID from Azure AD? The first step to use Azure AD is to regist...
What is Azure API Management Publisher Dashboard? Azure API Management Publisher Dashboard is an Azu...
How to run PowerShell Commands in Dockerfile to change Windows Docker images? When building a new Wi...