kshitijyelpale / blockchain-hyperledger-fabric-electronic-patient-records

GNU General Public License v3.0
49 stars 42 forks source link

Failed to create a channel #61

Open FatmaBH opened 2 years ago

FatmaBH commented 2 years ago

When executing this command './network.sh createChannel -c hospitalchannel' to create a channel, I got this error:

Error: got unexpected status: BAD_REQUEST -- error applying config update to existing channel 'hospitalchannel': error authorizing update: error validating ReadSet: proposed update requires that key [Group] /Channel/Application be at version 0, but it is currently at version 2 Channel creation failed Create channel failed

where should I fix capabilities to the levels appropriate to that release?

sjathin commented 2 years ago

Can you please give more info about what commands you executed before?

FatmaBH commented 2 years ago

Thank you for your reply. I solved that issue, I removed the docker containers then re-executed the command './network.sh createChannel -c hospitalchannel' and it works fine. Now I have another issue with npm start. When I execute the command npm start at the app/server directory I got the following issue: [FabricCAClientService.js]: Failed to enroll hosp1admin] error:%o message=Calling enroll endpoint failed with error [Error: connect ECONNREFUSED 127.0.0.1:7054] The problem is that I didn't find the FabricCAClientService.js file so I can debug the error.

sjathin commented 2 years ago

Have you executed npm install in two directories? 1. app/server 2. app/patient-asset-transfer?

And also in a few systems the port numbers are blocked by the firewall. Could you check if this is not the case.

FatmaBH commented 2 years ago

Hi Jathin,

Thank you for your reply. Indeed! I executed npm install in app/server and app/patient-asset-transfer Also I disabled the firewall and checked that the ports 7054 and 8054 are not used by other processes.

Thank you for your time,

sjathin commented 2 years ago

I see, is there anything else mentioned in the log when you get this error?

A-H-M-E-D-93 commented 2 years ago

same error i am facing ?

Estabrag commented 1 year ago

Hello, I have the same issue. I tried to solve it as FatmaBH did but there is no difference. the complete error message
[channelCmd] InitCmdFactory -> Endorser and orderer connections initialized Error: got unexpected status: BAD_REQUEST -- error applying config update to existing channel 'hospitalchannel': error authorizing update: error validating ReadSet: proposed update requires that key [Group] /Channel/Application be at version 0, but it is currently at version 1 Channel creation failed Create channel failed I realized that this thing happened after I have installed docker desktop on ubuntu so what shall i do?