Uploaded image for project: 'Fabric'
  1. Fabric
  2. FAB-16435

Improve default configuration for gossip

    XMLWordPrintable

Details

    • Story
    • Status: Closed
    • Medium
    • Resolution: Done
    • None
    • v2.2.0
    • fabric-gossip

    Description

      Overview

      Some Fabric networks have seen issues with excessive gossip communications, memory usage, or grpc max message size.

      We have an opportunity to improve some of the default peer settings, for example I propose:

      CORE_PEER_GOSSIP_USELEADERELECTION = false 
      CORE_PEER_GOSSIP_ORGLEADER = true 
      CORE_PEER_GOSSIP_MAXBLOCKCOUNTTOSTORE = 10 
      CORE_PEER_GOSSIP_STATE_ENABLED = false
      CORE_PEER_GOSSIP_STATE_BLOCKBUFFERSIZE = 20  
      CORE_PEER_GOSSIP_STATE_BATCHSIZE = 10
      

      More details

      We have found that unless there are a large number of peers in an organization, it is more efficient to have peers pull blocks directly from orderer nodes, by using this configuration:

      CORE_PEER_GOSSIP_USELEADERELECTION = false 
      CORE_PEER_GOSSIP_ORGLEADER = true 
      CORE_PEER_GOSSIP_STATE_ENABLED = false
      

      If there are a large number of channels or large block sizes, reduce the size of these configurations from default of 100 to improve memory usage (the latter setting is not needed if CORE_PEER_GOSSIP_STATE_ENABLED is false):

      CORE_PEER_GOSSIP_MAXBLOCKCOUNTTOSTORE = 10 
      CORE_PEER_GOSSIP_STATE_BLOCKBUFFERSIZE = 20  
      

      And if the block sizes are so large that you risk hitting grpc 100MB limit, reduce this setting (again, not needed if CORE_PEER_GOSSIP_STATE_ENABLED is false):

      CORE_PEER_GOSSIP_STATE_BATCHSIZE = 10
      

      The CORE_PEER_GOSSIP_STATE_* settings were added in v1.4.1 and above.

      These are proposed tactical improvements, while longer term improvements are identified in FAB-15317.

      Attachments

        Issue Links

          Activity

            People

              denyeart David Enyeart
              denyeart David Enyeart
              Votes:
              0 Vote for this issue
              Watchers:
              5 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: