问题
I use composer deployed to the fabric network with five peers. Today when i try to update the fabric chaincode with composer bna file. but one peer return error:
Error: Peer localhost:13051 has rejected transaction '39ae7b9cf735ca56a7b9a20c60745206d94852a0a4f73d14cd6fd8813ef57566' with code MVCC_READ_CONFLICT
althrough the new dev* chaincode docker of this peer is generated an up. but,all the transaction will return:
EXPIRED CHAINCODE
so i check this peer's log, found it still use the older version chaincode.
so if there is somehow to update this peer' chaincode version? could bna chaincode generated by composer using node.js be use directly by fabric?
回答1:
What has happened is you have a state fork and as such peers are going to disagree (and they disagree on the version of chaincode to use). Fabric 1.4 (not sure which micro version) introduced commands to reset peers back to previous block numbers which you could try to use to reset your problem peer(s) back to a point where they were in agreement and let them pull the blocks from the orderer again. If not, then you will have to remove that problem peer(s) from your network and create new peers and join them to the channel.
来源:https://stackoverflow.com/questions/60884889/mvcc-read-conflict-error-when-update-the-fabric-chaincode-with-composer