Need some help with lab 8, can't get past first step
After working on Lab 7 for a while and running through it multiple times, I moved on to Lab 8. As far as I can tell everything in the network should be set up correctly, I had one isssue in Lab 7 where I couldn't do the Chaincode instantiate/upgrade from Org2, I can only do it from Org1.
Anyhow, when I go into Lab 8, first step is to Open the configtx.yaml file, and append this to the profiles section:
OrgTwoChannel:
Consortium: SampleConsortium
Application:
<<: *ApplicationDefaults
Organizations:
- *Org2
AllAreWelcomeTwo:
Consortium: SampleConsortium
Application:
<<: *ApplicationDefaults
Organizations:
- *Org1
- *Org2
The next step is to run ../bin/configtxgen -profile OrgTwoChannel -outputCreateChannelTx ./config/OrgTwoChannel.tx -channelID orgtwochannel
I immediately get an error for configtxgen that I have invalid keys. Note that I can no longer run any configtxgen commands they all result in the same error message. If I edit configtx.yaml file and remove the content from Lab 8, it goes back to working and I can run basic configtxgen commands again.
This is the output when I try to run it with the Lab 8 edits.
student@ubuntu:~/Desktop/fabric-samples/startFiles$ ../bin/configtxgen -profile OrgTwoChannel -outputCreateChannelTx ./config/OrgTwoChannel.tx -channelID orgtwochannel
2020-05-31 14:24:23.788 EDT [common.tools.configtxgen] main -> INFO 001 Loading configuration
2020-05-31 14:24:23.791 EDT [common.tools.configtxgen.localconfig] Load -> PANI 002 Error unmarshaling config into struct: 1 error(s) decoding:
'' has invalid keys: allarewelcometwo, orgtwochannel
2020-05-31 14:24:23.791 EDT [common.tools.configtxgen] func1 -> PANI 003 Error unmarshaling config into struct: 1 error(s) decoding:'' has invalid keys: allarewelcometwo, orgtwochannel
panic: Error unmarshaling config into struct: 1 error(s) decoding:'' has invalid keys: allarewelcometwo, orgtwochannel [recovered]
panic: Error unmarshaling config into struct: 1 error(s) decoding:'' has invalid keys: allarewelcometwo, orgtwochannel
goroutine 1 [running]:
github.com/hyperledger/fabric/vendor/go.uber.org/zap/zapcore.(CheckedEntry).Write(0xc000121970, 0x0, 0x0, 0x0)
/w/workspace/fabric-release-jobs-x86_64/gopath/src/github.com/hyperledger/fabric/vendor/go.uber.org/zap/zapcore/entry.go:229 +0x515
github.com/hyperledger/fabric/vendor/go.uber.org/zap.(SugaredLogger).log(0xc0000b2248, 0xc00046d804, 0xc000378240, 0x82, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
/w/workspace/fabric-release-jobs-x86_64/gopath/src/github.com/hyperledger/fabric/vendor/go.uber.org/zap/sugar.go:234 +0xf6
github.com/hyperledger/fabric/vendor/go.uber.org/zap.(SugaredLogger).Panicf(0xc0000b2248, 0xc000378240, 0x82, 0x0, 0x0, 0x0)
/w/workspace/fabric-release-jobs-x86_64/gopath/src/github.com/hyperledger/fabric/vendor/go.uber.org/zap/sugar.go:159 +0x79
github.com/hyperledger/fabric/common/flogging.(FabricLogger).Panic(0xc0000b2250, 0xc00046d938, 0x1, 0x1)
/w/workspace/fabric-release-jobs-x86_64/gopath/src/github.com/hyperledger/fabric/common/flogging/zap.go:73 +0x75
main.main.func1()
/w/workspace/fabric-release-jobs-x86_64/gopath/src/github.com/hyperledger/fabric/common/tools/configtxgen/main.go:250 +0x1a9
panic(0xd4fc40, 0xc000471ce0)
/opt/go/go1.11.1.linux.amd64/src/runtime/panic.go:513 +0x1b9
github.com/hyperledger/fabric/vendor/go.uber.org/zap/zapcore.(CheckedEntry).Write(0xc000121970, 0x0, 0x0, 0x0)
/w/workspace/fabric-release-jobs-x86_64/gopath/src/github.com/hyperledger/fabric/vendor/go.uber.org/zap/zapcore/entry.go:229 +0x515
github.com/hyperledger/fabric/vendor/go.uber.org/zap.(SugaredLogger).log(0xc0000b2228, 0xc00046dc04, 0xc000378090, 0x82, 0x0, 0x0, 0x0, 0x0, 0x0, 0x0)
/w/workspace/fabric-release-jobs-x86_64/gopath/src/github.com/hyperledger/fabric/vendor/go.uber.org/zap/sugar.go:234 +0xf6
github.com/hyperledger/fabric/vendor/go.uber.org/zap.(SugaredLogger).Panicf(0xc0000b2228, 0xc000378090, 0x82, 0x0, 0x0, 0x0)
/w/workspace/fabric-release-jobs-x86_64/gopath/src/github.com/hyperledger/fabric/vendor/go.uber.org/zap/sugar.go:159 +0x79
github.com/hyperledger/fabric/common/flogging.(FabricLogger).Panic(0xc0000b2230, 0xc00046dd98, 0x2, 0x2)
/w/workspace/fabric-release-jobs-x86_64/gopath/src/github.com/hyperledger/fabric/common/flogging/zap.go:73 +0x75
github.com/hyperledger/fabric/common/tools/configtxgen/localconfig.Load(0x7fffda6f61d3, 0xd, 0x0, 0x0, 0x0, 0xc000458540)
/w/workspace/fabric-release-jobs-x86_64/gopath/src/github.com/hyperledger/fabric/common/tools/configtxgen/localconfig/config.go:282 +0x580
main.main()
/w/workspace/fabric-release-jobs-x86_64/gopath/src/github.com/hyperledger/fabric/common/tools/configtxgen/main.go:261 +0xb2f
student@ubuntu:~/Desktop/fabric-samples/startFiles$
Has anyone run into this or have a suggestion how to resolve?
Note that I even tried to remove all references to Org2, assuming that was the issue but I still had a problem. I updated configtx.yaml and added just the following.
AllAreWelcomeTwo:
Consortium: SampleConsortium
Application:
<<: *ApplicationDefaults
Organizations:
- *Org1
Then I ran ../bin/configtxgen -profile AllAreWelcomeTwo -outputCreateChannelTx ./config/AllAreWelcomeTwo.tx -channelID allarewelcometwo
and I got the same error. So it appears any edit to configtx.yaml has resulted in an issue.
As a last ditch effort I thought perhaps it had something to do with editing the file so I threw a hail Mary and did a chmod 777 configtx.yaml
No luck....
Comments
-
Are you sure your indentation is correct?
0 -
@LogarithmicTC said:
Are you sure your indentation is correct?@garycris ,
Hi, as @LogarithmicTC points out be sure to be presice in your YAML-file, as the position of all characters need to be perfect. It might also be an earlier error in what you did in Lab7 or previous labs that is generating this error.Since it says you have invalid keys I would assume maybe you did not update the key numbers in your config file? You might have generated new keys during previous labs.
I just ran trough the Lab8, without any issues. But I have to say, when I learned Fabric myself I encountered many errors similar to you. The best help is to tear down the network, and go over it again. Every time I did this, I saw the mistake I did, I got more comfortable with the commands, and most importantly, I understood why the error messages had occured.
If you still want to continue from where you are in Lab 8, these two suggestions might help you:
- Check that you run configtxgen from the same path you have configtx.yaml
- It could be a version mismatch. Check that your version of binaries match the configuration files
0 -
I had to teardown the network again. Eventually got past it. Thanks
1
Categories
- All Categories
- 176 LFX Mentorship
- 176 LFX Mentorship: Linux Kernel
- 750 Linux Foundation IT Professional Programs
- 373 Cloud Engineer IT Professional Program
- 169 Advanced Cloud Engineer IT Professional Program
- 74 DevOps IT Professional Program - Discontinued
- 4 DevOps & GitOps IT Professional Program
- 99 Cloud Native Developer IT Professional Program
- 7.6K Training Courses & Learning Paths
- 1 AI & ML Training
- 1 Blockchain & Decentralized Identity Training
- 3 Cloud & Containers Training
- 1 Cybersecurity Training
- 1 DevOps & Site-Reliability Training
- 1 Linux Kernel Development Training
- 1 Networking Training
- 1 Open Source Best Practice Training
- 1 System Administration Training
- 1 System Engineering Training
- 1 Web & Application Development Training
- 792 Hardware
- 202 Drivers
- 68 I/O Devices
- 37 Monitors
- 95 Multimedia
- 173 Networking
- 91 Printers & Scanners
- 87 Storage
- 768 Linux Distributions
- 81 Debian
- 67 Fedora
- 22 Linux Mint
- 13 Mageia
- 24 openSUSE
- 150 Red Hat Enterprise
- 31 Slackware
- 13 SUSE Enterprise
- 356 Ubuntu
- 465 Linux System Administration
- 31 Cloud Computing
- 73 Command Line/Scripting
- Github systems admin projects
- 98 Linux Security
- 78 Network Management
- 101 System Management
- 46 Web Management
- 106 Mobile Computing
- 18 Android
- 73 Development
- 1.2K New to Linux
- 1K Getting Started with Linux
- 392 Off Topic
- 121 Introductions
- 181 Small Talk
- 29 Study Material
- 949 Programming and Development
- 310 Kernel Development
- 621 Software Development
- 982 Software
- 374 Applications
- 182 Command Line
- 5 Compiling/Installing
- 68 Games
- 317 Installation
- Archived
- 2 LFD140 Class 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)