Error in last step of start.sh in lab 1.
Hi, This is my first post to this forum. I am working on Lab 1, LFS272.
I have completed all steps but receive an error in the final step of start.sh. Here are the specific error from start.sh followed by the full output of start.sh:
Error: proposal failed (err: rpc error: code = Unknown desc = error validating proposal: access denied: channel [] creator org unknown, creator is malformed)
Here is the full output of start.sh:
Set env vars
export CHANNEL_NAME=allarewelcome
docker compose -f docker-compose.yml down
[+] Running 4/4
✔ Container ca.org1.example.com R... 0.9s
✔ Container peer0.org1.example.com Removed 0.9s
✔ Container orderer.example.com R... 0.3s
✔ Network starter_basic Removed 0.5s
docker compose -f docker-compose.yml up -d ca.org1.example.com orderer.example.com peer0.org1.example.com cli
[+] Running 5/5
✔ Network starter_basic Created 0.3s
✔ Container ca.org1.example.com S... 14.7s
✔ Container orderer.example.com S... 13.8s
✔ Container peer0.org1.example.com Started 14.1s
✔ Container cli Started 16.7s
Wait for Hyperledger Fabric to start
In case of errors when running later commands, issue export FABRIC_START_TIMEOUT=
export FABRIC_START_TIMEOUT=15
sleep ${FABRIC_START_TIMEOUT}
Create the application channel
ORDERER_TLS_CA=docker exec cli env | grep ORDERER_TLS_CA | cut -d'=' -f2
docker exec cli peer channel create -o orderer.example.com:7050 -c $CHANNEL_NAME -f /etc/hyperledger/configtx/$CHANNEL_NAME.tx --tls --cafile $ORDERER_TLS_CA
2023-07-31 20:47:52.452 UTC 0001 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-07-31 20:47:52.605 UTC 0002 INFO [cli.common] readBlock -> Expect block, but got status: &{NOT_FOUND}
2023-07-31 20:47:52.633 UTC 0003 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-07-31 20:47:52.929 UTC 0004 INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-07-31 20:47:52.934 UTC 0005 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-07-31 20:47:53.137 UTC 0006 INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-07-31 20:47:53.146 UTC 0007 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-07-31 20:47:53.349 UTC 0008 INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-07-31 20:47:53.355 UTC 0009 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-07-31 20:47:53.557 UTC 000a INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-07-31 20:47:53.565 UTC 000b INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-07-31 20:47:53.767 UTC 000c INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-07-31 20:47:53.772 UTC 000d INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-07-31 20:47:53.975 UTC 000e INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-07-31 20:47:53.980 UTC 000f INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-07-31 20:47:54.184 UTC 0010 INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-07-31 20:47:54.200 UTC 0011 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-07-31 20:47:54.407 UTC 0012 INFO [cli.common] readBlock -> Received block: 0
Join peer0.org1.example.com to the channel
docker exec cli peer channel join -b $CHANNEL_NAME.block
2023-07-31 20:47:54.946 UTC 0001 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
Error: proposal failed (err: rpc error: code = Unknown desc = error validating proposal: access denied: channel [] creator org unknown, creator is malformed)
The error is only the last item. Note that all four containers were created, but appear to have not joined the channel 'allarewelcome'.
I am running Ubuntu 22.04 (not 18.04) and I am using Docker version 24.0.5, (not 19.03.13). Therefore, I modified lines 13 and 15 of start.sh to "docker compose" from "docker-compose" to reflect the shift from compose v1 (which has been deprecated) to compose v2. Other than that, the script is as originally written. I can't see how this would cause the error. Then again, I have no idea why the error occurs.
Thanks in advance for assistance.
Answers
-
Hello,
Welcome to the forum @dougd! Don't worry, your error isn't uncommon, and it's usually related to misconfigurations or inconsistencies in the certificates. Let's walk through a few potential issues:
Incorrect Certificate Authority (CA) Setup: Make sure that the certificates from the CA for the peers and orderer nodes are correctly configured. If the organization identities aren't correctly recognized by the Fabric network, you might see this type of error.
Network not Fully Bootstrapped: Ensure that your Hyperledger Fabric network is fully up and running before you try to execute commands. The peers and the orderer node may not have been fully initialized before the script tried to create and join the channel.
Correct CHANNEL_NAME Export: Check if the environment variable CHANNEL_NAME is correctly set. The error message suggests that the channel name is not recognized.
Certificate Path: Make sure the --cafile flag points to the correct path of the Orderer's TLS CA certificate file. The ORDERER_TLS_CA environment variable must contain the correct path to the certificate file.
User Identity Configuration: Check if the user MSP (Membership Service Provider) is correctly setup in the core.yaml file. The error message suggests an issue with the creator's identity.
Remember, it's essential that the configurations for your peers, orderer nodes, and organizations are all correct and consistent throughout your setup. Please review your setup, consider these points, and try again.
Regarding the Docker Compose version, the shift from "docker-compose" to "docker compose" should not cause any issues, as long as the Docker Compose file (docker-compose.yml) and commands are compatible with the version you are using.
If you're still encountering issues after this, please provide more information about your setup and configurations so we can help diagnose the problem more accurately.
Hope this helps, and let us know how it goes! Bobbi
0 -
Thank you Bobbi,
This is exactly what I was looking for. I don't have time today, but will definitely work through it tomorrow, Thursday, and will post the results in a comment.
Doug
0 -
Hi Bobbi,
Thanks again for your response, and for encouraging me to give it a try before coming back hat in hand. Well, here I am. :-)
The root challenge with your response is that I don't know how to do what you are asking to investigate. The way this course is structured, for Lab 1, it is just run a couple of scripts and don't worry about the details. We'll get to those. Well, I ain't got there yet cause I can't get past the last step in start.sh of Lab 1.
So, first I want to respond to your specific comments, then I'll present the detailed output.
Incorrect Certificate Authority (CA) Setup: Make sure that the certificates from the CA for the peers and orderer nodes are correctly configured. If the organization identities aren't correctly recognized by the Fabric network, you might see this type of error.
How do I do that? Since it is all with the generate.sh and start.sh scripts that are provided, I don't know how to know if the nodes are correctly configured. Again, since they are part of the scripts that have been provided, I expect they are OK.
Network not Fully Bootstrapped: Ensure that your Hyperledger Fabric network is fully up and running before you try to execute commands. The peers and the orderer node may not have been fully initialized before the script tried to create and join the channel.
Same comment. How do you tell if the nodes have been fully initialized. I will say that the four containers are set up and appear to be correct, but I don't know how to determine if they have been fully initialized.
Correct CHANNEL_NAME Export: Check if the environment variable CHANNEL_NAME is correctly set. The error message suggests that the channel name is not recognized.
From the output of start.sh below, it appears that allarewelcome is properly named.
Certificate Path: Make sure the --cafile flag points to the correct path of the Orderer's TLS CA certificate file. The ORDERER_TLS_CA environment variable must contain the correct path to the certificate file.
Same comment.
User Identity Configuration: Check if the user MSP (Membership Service Provider) is correctly setup in the core.yaml file. The error message suggests an issue with the creator's identity.
And finally, I can read the core.yaml file, but don't know what to look for to know if it is properly set up. Again, since this was a downloaded file, I'd be surprised if it is in error.
Next, here is the complete output. Note that the only modifications to the original start.sh script are: switch from docker-compose to docker compose (which seems to work as it should), and I added
"set -xtrap read debug"
to the top of the script so I could more closely observe what was happening. Here is the output from the script.
fabric@doug-VirtualBox:~/Desktop/lfs272-assets/networkFiles$ ./start.sh
- trap read debug
++ read
- set -ev
Set env vars
export CHANNEL_NAME=allarewelcome
read
++ read
export CHANNEL_NAME=allarewelcome
CHANNEL_NAME=allarewelcome
docker compose -f docker-compose.yml down
read
++ read
- docker compose -f docker-compose.yml down
[+] Running 5/5
✔ Container ca.org1.example.com Removed 12.5s
✔ Container cli Removed 3.1s
✔ Container peer0.org1.example.com Removed 2.4s
✔ Container orderer.example.com Removed 1.6s
✔ Network starter_basic Remo... 0.7s
docker compose -f docker-compose.yml up -d ca.org1.example.com orderer.example.com peer0.org1.example.com cli
read
++ read
- docker compose -f docker-compose.yml up -d ca.org1.example.com orderer.example.com peer0.org1.example.com cli
[+] Running 5/5
✔ Network starter_basic Crea... 0.4s
✔ Container orderer.example.com Started 5.7s
✔ Container ca.org1.example.com Started 5.7s
✔ Container peer0.org1.example.com Started 4.9s
✔ Container cli Started 6.4s
Wait for Hyperledger Fabric to start
In case of errors when running later commands, issue export FABRIC_START_TIMEOUT=
export FABRIC_START_TIMEOUT=15
read
++ read
export FABRIC_START_TIMEOUT=15
FABRIC_START_TIMEOUT=15
sleep ${FABRIC_START_TIMEOUT}
read
++ read
- sleep 15
Create the application channel
ORDERER_TLS_CA=
docker exec cli env | grep ORDERER_TLS_CA | cut -d'=' -f2
read
++ read
++ docker exec cli env
++ grep ORDERER_TLS_CA
++ cut -d= -f2
- ORDERER_TLS_CA=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem
docker exec cli peer channel create -o orderer.example.com:7050 -c $CHANNEL_NAME -f /etc/hyperledger/configtx/$CHANNEL_NAME.tx --tls --cafile $ORDERER_TLS_CA
read
++ read
- docker exec cli peer channel create -o orderer.example.com:7050 -c allarewelcome -f /etc/hyperledger/configtx/allarewelcome.tx --tls --cafile /opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com/msp/tlscacerts/tlsca.example.com-cert.pem
2023-08-15 22:31:00.532 UTC 0001 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-08-15 22:31:00.578 UTC 0002 INFO [cli.common] readBlock -> Expect block, but got status: &{NOT_FOUND}
2023-08-15 22:31:00.584 UTC 0003 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-08-15 22:31:01.086 UTC 0004 INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-08-15 22:31:01.102 UTC 0005 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-08-15 22:31:01.304 UTC 0006 INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-08-15 22:31:01.310 UTC 0007 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-08-15 22:31:01.514 UTC 0008 INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-08-15 22:31:01.520 UTC 0009 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-08-15 22:31:01.724 UTC 000a INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-08-15 22:31:01.737 UTC 000b INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-08-15 22:31:01.942 UTC 000c INFO [cli.common] readBlock -> Expect block, but got status: &{SERVICE_UNAVAILABLE}
2023-08-15 22:31:01.950 UTC 000d INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
2023-08-15 22:31:02.157 UTC 000e INFO [cli.common] readBlock -> Received block: 0
Join peer0.org1.example.com to the channel
docker exec cli peer channel join -b $CHANNEL_NAME.block
read
++ read
- docker exec cli peer channel join -b allarewelcome.block
2023-08-15 22:31:07.111 UTC 0001 INFO [channelCmd] InitCmdFactory -> Endorser and orderer connections initialized
Error: proposal failed (err: rpc error: code = Unknown desc = error validating proposal: access denied: channel [] creator org unknown, creator is malformed)
fabric@doug-VirtualBox:~/D
So, that's all I have. If you need something additional, I can't imagine what it would be since all I did was execute the two scripts that are provided as a part of Lab 1.
Really looking forward to getting past this so I can start learning the details of this wonderful set of products.
Thanks in advance for your guidance.
Doug
0 -
-
Hello @dougd and @jay846josh,
I understand the frustration that comes with encountering such errors, especially when following provided scripts in a learning environment like LFS272. Let's address the issue step-by-step to find a solution.
The error message Error: proposal failed (err: rpc error: code = Unknown desc = error validating proposal: access denied: channel [] creator org unknown, creator is malformed) typically indicates an issue with the way the Hyperledger Fabric network is recognizing the identity of the user or peer trying to execute the command. This could be due to a variety of reasons, including misconfiguration of MSP (Membership Service Provider) identities, incorrect setup of the network, or timing issues in the script execution.
Given that you're using provided scripts and not altering the code, let's consider a few areas:
Wait for Network Initialization: Ensure that all components of the Hyperledger Fabric network are fully initialized and operational before executing the start.sh script. The script might be running before all containers are ready. Increasing the FABRIC_START_TIMEOUT value might help.
Check MSP Configurations: Even if you're not altering the scripts, there can sometimes be issues with the MSP configurations in the provided materials. Verify that the MSPs for the peers and orderer are correctly set up in the network configurations.
Identity of the User Executing the Script: The error suggests an issue with the identity (creator org unknown, creator is malformed). Ensure that the identity trying to create the channel and join the peer to it has the correct permissions and is recognized by the network. This might involve checking the environment variables and the user context under which the start.sh script is running.
Certificate Authorities and TLS: Double-check that the Certificate Authorities (CAs) are correctly set up and running. The TLS certificates should be correctly generated and available for the orderer and peers.
Docker Compose Version: Although the shift from docker-compose to docker compose should not be an issue, verify that your Docker Compose version and configuration are compatible with the Hyperledger Fabric version you are using.
Please let me know if you have any luck with these suggestions, Bobbi
0
Categories
- All Categories
- 217 LFX Mentorship
- 217 LFX Mentorship: Linux Kernel
- 788 Linux Foundation IT Professional Programs
- 352 Cloud Engineer IT Professional Program
- 177 Advanced Cloud Engineer IT Professional Program
- 82 DevOps Engineer IT Professional Program
- 146 Cloud Native Developer IT Professional Program
- 137 Express Training Courses
- 137 Express Courses - Discussion Forum
- 6.1K Training Courses
- 46 LFC110 Class Forum - Discontinued
- 70 LFC131 Class Forum
- 42 LFD102 Class Forum
- 226 LFD103 Class Forum
- 18 LFD110 Class Forum
- 36 LFD121 Class Forum
- 18 LFD133 Class Forum
- 7 LFD134 Class Forum
- 18 LFD137 Class Forum
- 71 LFD201 Class Forum
- 4 LFD210 Class Forum
- 5 LFD210-CN Class Forum
- 2 LFD213 Class Forum - Discontinued
- 128 LFD232 Class Forum - Discontinued
- 2 LFD233 Class Forum
- 4 LFD237 Class Forum
- 24 LFD254 Class Forum
- 693 LFD259 Class Forum
- 111 LFD272 Class Forum
- 4 LFD272-JP クラス フォーラム
- 12 LFD273 Class Forum
- 144 LFS101 Class Forum
- 1 LFS111 Class Forum
- 3 LFS112 Class Forum
- 2 LFS116 Class Forum
- 4 LFS118 Class Forum
- 4 LFS142 Class Forum
- 5 LFS144 Class Forum
- 4 LFS145 Class Forum
- 2 LFS146 Class Forum
- 3 LFS147 Class Forum
- 1 LFS148 Class Forum
- 15 LFS151 Class Forum
- 2 LFS157 Class Forum
- 25 LFS158 Class Forum
- 7 LFS162 Class Forum
- 2 LFS166 Class Forum
- 4 LFS167 Class Forum
- 3 LFS170 Class Forum
- 2 LFS171 Class Forum
- 3 LFS178 Class Forum
- 3 LFS180 Class Forum
- 2 LFS182 Class Forum
- 5 LFS183 Class Forum
- 31 LFS200 Class Forum
- 737 LFS201 Class Forum - Discontinued
- 3 LFS201-JP クラス フォーラム
- 18 LFS203 Class Forum
- 130 LFS207 Class Forum
- 2 LFS207-DE-Klassenforum
- 1 LFS207-JP クラス フォーラム
- 302 LFS211 Class Forum
- 56 LFS216 Class Forum
- 52 LFS241 Class Forum
- 48 LFS242 Class Forum
- 38 LFS243 Class Forum
- 15 LFS244 Class Forum
- 2 LFS245 Class Forum
- LFS246 Class Forum
- 48 LFS250 Class Forum
- 2 LFS250-JP クラス フォーラム
- 1 LFS251 Class Forum
- 150 LFS253 Class Forum
- 1 LFS254 Class Forum
- 1 LFS255 Class Forum
- 7 LFS256 Class Forum
- 1 LFS257 Class Forum
- 1.2K LFS258 Class Forum
- 10 LFS258-JP クラス フォーラム
- 118 LFS260 Class Forum
- 159 LFS261 Class Forum
- 42 LFS262 Class Forum
- 82 LFS263 Class Forum - Discontinued
- 15 LFS264 Class Forum - Discontinued
- 11 LFS266 Class Forum - Discontinued
- 24 LFS267 Class Forum
- 22 LFS268 Class Forum
- 30 LFS269 Class Forum
- LFS270 Class Forum
- 202 LFS272 Class Forum
- 2 LFS272-JP クラス フォーラム
- 1 LFS274 Class Forum
- 4 LFS281 Class Forum
- 9 LFW111 Class Forum
- 259 LFW211 Class Forum
- 181 LFW212 Class Forum
- 13 SKF100 Class Forum
- 1 SKF200 Class Forum
- 1 SKF201 Class Forum
- 795 Hardware
- 199 Drivers
- 68 I/O Devices
- 37 Monitors
- 102 Multimedia
- 174 Networking
- 91 Printers & Scanners
- 85 Storage
- 758 Linux Distributions
- 82 Debian
- 67 Fedora
- 17 Linux Mint
- 13 Mageia
- 23 openSUSE
- 148 Red Hat Enterprise
- 31 Slackware
- 13 SUSE Enterprise
- 353 Ubuntu
- 468 Linux System Administration
- 39 Cloud Computing
- 71 Command Line/Scripting
- Github systems admin projects
- 93 Linux Security
- 78 Network Management
- 102 System Management
- 47 Web Management
- 63 Mobile Computing
- 18 Android
- 33 Development
- 1.2K New to Linux
- 1K Getting Started with Linux
- 370 Off Topic
- 114 Introductions
- 173 Small Talk
- 22 Study Material
- 805 Programming and Development
- 303 Kernel Development
- 484 Software Development
- 1.8K Software
- 261 Applications
- 183 Command Line
- 3 Compiling/Installing
- 987 Games
- 317 Installation
- 96 All In Program
- 96 All In Forum
Upcoming Training
-
August 20, 2018
Kubernetes Administration (LFS458)
-
August 20, 2018
Linux System Administration (LFS301)
-
August 27, 2018
Open Source Virtualization (LFS462)
-
August 27, 2018
Linux Kernel Debugging and Security (LFD440)