hyperledger/fabric · error
illegal orderer config detected during consensus metadata va
Error message
illegal orderer config detected during consensus metadata validation: endpoints of org %s are missing
What it means
Raised during consensus metadata validation when the channel is being migrated to a BFT consensus type but one of the organizations in the new orderer config has no consensus endpoints (hosts) defined. BFT requires every org to expose orderer endpoints so nodes can form the committee.
Source
Thrown at orderer/consensus/etcdraft/chain.go:1474
// ValidateConsensusMetadata determines the validity of a
// ConsensusMetadata update during config updates on the channel.
func (c *Chain) ValidateConsensusMetadata(oldOrdererConfig, newOrdererConfig channelconfig.Orderer, newChannel bool) error {
if newOrdererConfig == nil {
c.logger.Panic("Programming Error: ValidateConsensusMetadata called with nil new channel config")
return nil
}
// metadata was not updated
if newOrdererConfig.ConsensusMetadata() == nil {
return nil
}
if newOrdererConfig.ConsensusType() != "etcdraft" {
if newOrdererConfig.ConsensusType() == "BFT" {
// This is a migration, so we have to validate the config change and make sure that endpoints per org are configured
for _, org := range newOrdererConfig.Organizations() {
if len(org.Endpoints()) == 0 {
return errors.Errorf("illegal orderer config detected during consensus metadata validation: endpoints of org %s are missing", org.Name())
}
}
return nil
} else {
c.logger.Panicf("illegal consensus type detected during consensus metadata validation: %s", newOrdererConfig.ConsensusType())
return errors.Errorf("illegal consensus type detected during consensus metadata validation: %s", newOrdererConfig.ConsensusType())
}
}
if oldOrdererConfig == nil {
c.logger.Panic("Programming Error: ValidateConsensusMetadata called with nil old channel config")
return nil
}
if oldOrdererConfig.ConsensusMetadata() == nil {
c.logger.Panic("Programming Error: ValidateConsensusMetadata called with nil old metadata")
return nilView on GitHub (pinned to 2736b63f8f)
Solutions
- Add OrdererEndpoints (host:port list) for every organization in the Orderer group of the new channel config.
- Re-apply the config update using configtxlator to inject the missing endpoints.
- Verify with configtxlator decode that each org's OrdererEndpoints is non-empty before resubmitting.
Example fix
// configtx.yaml / channel config
Organizations:
- Name: Org1
# before
OrdererEndpoints: []
# after
OrdererEndpoints:
- orderer1.org1.example.com:7050 Defensive patterns
Strategy: validation
Validate before calling
latestSeq := fetchCurrentConfigSequence(channel)
if msgLastValidationSeq < latestSeq {
// recompute the config update against latest config before submitting
updated, err := recomputeConfigUpdate(latestConfig, desiredChange)
if err != nil { return err }
msg = signConfigUpdate(updated, adminCerts)
} Try / catch
if strings.HasPrefix(err.Error(), "bad config message:") {
return rebuildAndResignConfigUpdate(channel, desiredChange)
} Prevention
- Always rebuild config updates from the latest config seq.
- Re-sign updates with current admin certificates.
- Dry-run changes via configtxlator compare.
- Avoid racing concurrent config updates.
When it happens
Trigger: A channel config update switches ConsensusType from etcdraft to BFT while an Organization() entry in Orderer.Config has an empty Endpoints() list in the new config.
Common situations: Admins preparing a consensus-type migration forget to add OrdererEndpoints for each org in the channel config; orgs added to the consenter set without endpoint configuration.
Related errors
- illegal consensus type detected during consensus metadata va
- Setup error: unsupported msp type %d
- cannot load client cert for consenter %s:%d: %s
- cannot load server cert for consenter %s:%d: %s
- field Config.ChannelGroup is nil
AI-assisted analysis of hyperledger/fabric@2736b63f8f (2026-09-04).
Data as JSON: /api/errors/f7f26c6c511bf74d.
Report an issue: GitHub.