{"record":{"id":"83e070fafd0b4c4a","repo":"hyperledger/fabric","slug":"failed-obtaining-orderer-config-from-bundle","errorCode":null,"errorMessage":"failed obtaining orderer config from bundle","messagePattern":"failed obtaining orderer config from bundle","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"orderer/common/cluster/util.go","lineNumber":335,"sourceCode":"\tif block == nil {\n\t\treturn nil, errors.New(\"nil block\")\n\t}\n\tenvelopeConfig, err := protoutil.ExtractEnvelope(block, 0)\n\tif err != nil {\n\t\treturn nil, err\n\t}\n\n\tbundle, err := channelconfig.NewBundleFromEnvelope(envelopeConfig, bccsp)\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"failed extracting bundle from envelope\")\n\t}\n\tmsps, err := bundle.MSPManager().GetMSPs()\n\tif err != nil {\n\t\treturn nil, errors.Wrap(err, \"failed obtaining MSPs from MSPManager\")\n\t}\n\tordererConfig, ok := bundle.OrdererConfig()\n\tif !ok {\n\t\treturn nil, errors.New(\"failed obtaining orderer config from bundle\")\n\t}\n\n\tmspIDsToCACerts := make(map[string][][]byte)\n\tvar aggregatedTLSCerts [][]byte\n\tfor _, org := range ordererConfig.Organizations() {\n\t\t// Validate that every orderer org has a corresponding MSP instance in the MSP Manager.\n\t\tmsp, exists := msps[org.MSPID()]\n\t\tif !exists {\n\t\t\treturn nil, errors.Errorf(\"no MSP found for MSP with ID of %s\", org.MSPID())\n\t\t}\n\n\t\t// Build a per org mapping of the TLS CA certs for this org,\n\t\t// and aggregate all TLS CA certs into aggregatedTLSCerts to be used later on.\n\t\tvar caCerts [][]byte\n\t\tcaCerts = append(caCerts, msp.GetTLSIntermediateCerts()...)\n\t\tcaCerts = append(caCerts, msp.GetTLSRootCerts()...)\n\t\tmspIDsToCACerts[org.MSPID()] = caCerts\n\t\taggregatedTLSCerts = append(aggregatedTLSCerts, caCerts...)","sourceCodeStart":317,"sourceCodeEnd":353,"githubUrl":"https://github.com/hyperledger/fabric/blob/2736b63f8fd5932511d56fe68b7039d15977f7f6/orderer/common/cluster/util.go#L317-L353","documentation":"After building the bundle, EndpointconfigFromConfigBlock calls bundle.OrdererConfig(). This returns ok=false when the channel configuration does not contain a valid Orderer config group, so the function cannot enumerate orderer organizations and their TLS CA certs.","triggerScenarios":"Passing a config block from a channel whose config has no Orderer group (e.g. an application channel block missing the Orderer section, or a non-config block mistakenly passed in), so bundle.OrdererConfig() returns false.","commonSituations":"Pointing an orderer's cluster/block-puller at the genesis block of the wrong channel type, channel created without orderer orgs, or passing a regular (non-config) block where a config block was expected.","solutions":["Verify the block passed is actually a config block (type_header type CONFIG) for the correct channel.","Regenerate the genesis/channel config ensuring the Orderer section with orderer organizations is present in configtx.yaml.","Check that the channel was created with a profile that includes Orderer: -> Organizations entries.","Ensure the orderer is joining the intended channel and not one configured by another network."],"exampleFix":null,"handlingStrategy":"validation","validationCode":"// Confirm block is a config block of the expected channel before use\nif !protoutil.IsConfigBlock(block) {\n    return errors.New(\"block is not a config block\")\n}","typeGuard":"func isConfigBlock(b *common.Block) bool {\n    return b != nil && b.Header != nil && protoutil.IsConfigBlock(b)\n}","tryCatchPattern":null,"preventionTips":["Always include the Orderer section with organizations in your configtx.yaml profile.","Use protoutil.IsConfigBlock before treating a block as config.","Keep genesis blocks per-channel and never mix networks."],"tags":["fabric","config-block","orderer-config"],"backgroundTag":"missing-orderer-config-section","analyzedSha":"2736b63f8fd5932511d56fe68b7039d15977f7f6","analyzedAt":"2026-09-04T08:52:36.465Z","contentChangedAt":"2026-09-04T08:52:36.465Z","schemaVersion":2},"datasetVersion":"2026-09-08T10:18:20.063Z"}