title: Error: Got unexpected status: BAD_REQUEST
body: <p>I believe I have an <code>orderer</code>, two <code>peer</code>'s and a <code>cli</code> running on Kubernetes.</p>
  
  <p>Trying to issue <code>peer</code> commands within <code>cli</code> results in errors.  </p>
  
  <p><strong>Update</strong>: I've tried running the same crypto-config under <code>docker-compose</code> and receive the same error from <code>peer channel create</code>. This suggests either something is incorrect with my <code>cli</code> command or with the crypto-config itself.</p>
  
  <p>I would appreciate some guidance on debugging steps that would help me.</p>
  
  <p>Probably related to the issues summarized in my earlier question:<br>
  <a href="https://stackoverflow.com/q/44118305/609290">Received AliveMessage from a peer with the same PKI-ID as myself</a></p>
  
  <p>Within <code>cli</code>:  </p>
  
  <pre><code>CORE_PEER_MSPCONFIGPATH=/opt/gopath/src/github.com/hyperledger/fabric/peer/crypto/ordererOrganizations/example.com/orderers/orderer.example.com CORE_PEER_LOCALMSPID="OrdererMSP" \
  peer channel create \
  --orderer orderer.default.svc.cluster.local:7050 \
  --chain ch01 \
  --file channel.170511.tx
  </code></pre>
  
  <p>Results in:  </p>
  
  <pre><code>2017-05-22 17:36:52.235 UTC [logging] InitFromViper -&gt; DEBU 001 Setting default logging level to DEBUG for command 'channel'
  2017-05-22 17:36:52.235 UTC [msp] GetLocalMSP -&gt; DEBU 002 Returning existing local MSP
  2017-05-22 17:36:52.236 UTC [msp] GetDefaultSigningIdentity -&gt; DEBU 003 Obtaining default signing identity
  Error: Got unexpected status: BAD_REQUEST
  Usage:
    peer channel create [flags]
  </code></pre>
  
  <p>and coincidentally on <code>orderer</code>:  </p>
  
  <pre><code>2017-05-22 17:36:52.326 UTC [orderer/main] Deliver -&gt; DEBU 11f Starting new Deliver handler
  2017-05-22 17:36:52.326 UTC [orderer/common/deliver] Handle -&gt; DEBU 120 Starting new deliver loop
  2017-05-22 17:36:52.326 UTC [orderer/common/deliver] Handle -&gt; DEBU 121 Attempting to read seek info message
  2017-05-22 17:36:52.332 UTC [orderer/main] Broadcast -&gt; DEBU 122 Starting new Broadcast handler
  2017-05-22 17:36:52.333 UTC [orderer/common/broadcast] Handle -&gt; DEBU 123 Preprocessing CONFIG_UPDATE
  2017-05-22 17:36:52.333 UTC [orderer/multichain] Process -&gt; DEBU 124 Processing channel creation request for channel ch01
  2017-05-22 17:36:52.333 UTC [msp] GetLocalMSP -&gt; DEBU 125 Returning existing local MSP
  2017-05-22 17:36:52.333 UTC [msp] GetDefaultSigningIdentity -&gt; DEBU 126 Obtaining default signing identity
  2017-05-22 17:36:52.333 UTC [msp] GetLocalMSP -&gt; DEBU 127 Returning existing local MSP
  2017-05-22 17:36:52.333 UTC [msp] GetDefaultSigningIdentity -&gt; DEBU 128 Obtaining default signing identity
  2017-05-22 17:36:52.333 UTC [msp] Sign -&gt; DEBU 129 Sign: plaintext: [[REDACTED]]...[[REDACTED]] 
  2017-05-22 17:36:52.333 UTC [msp] Sign -&gt; DEBU 12a Sign: digest: [[REDACTED]] 
  2017-05-22 17:36:52.333 UTC [msp] GetLocalMSP -&gt; DEBU 12b Returning existing local MSP
  2017-05-22 17:36:52.333 UTC [msp] GetDefaultSigningIdentity -&gt; DEBU 12c Obtaining default signing identity
  2017-05-22 17:36:52.333 UTC [msp] GetLocalMSP -&gt; DEBU 12d Returning existing local MSP
  2017-05-22 17:36:52.333 UTC [msp] GetDefaultSigningIdentity -&gt; DEBU 12e Obtaining default signing identity
  2017-05-22 17:36:52.333 UTC [msp] Sign -&gt; DEBU 12f Sign: plaintext: [[REDACTED]]...[[REDACTED]] 
  2017-05-22 17:36:52.333 UTC [msp] Sign -&gt; DEBU 130 Sign: digest: [[REDACTED]] 
  2017-05-22 17:36:52.334 UTC [orderer/common/broadcast] Handle -&gt; DEBU 131 Broadcast is filtering message of type 4 for channel testchainid
  2017-05-22 17:36:52.334 UTC [common/policies] GetPolicy -&gt; DEBU 132 Returning policy Writers for evaluation
  2017-05-22 17:36:52.334 UTC [cauthdsl] func1 -&gt; DEBU 133 Gate evaluation starts: (&amp;{N:1 policies:&lt;signed_by:0 &gt; })
  2017-05-22 17:36:52.334 UTC [cauthdsl] func2 -&gt; DEBU 134 Principal evaluation starts: (&amp;{%!s(int32=0)}) (used [%!s(bool=false)])
  2017-05-22 17:36:52.334 UTC [msp] newIdentity -&gt; DEBU 135 Creating identity instance for ID &amp;{OrdererMSP DEFAULT}
  2017-05-22 17:36:52.334 UTC [msp] Validate -&gt; INFO 136 MSP OrdererMSP validating identity
  2017-05-22 17:36:52.334 UTC [cauthdsl] func2 -&gt; DEBU 137 Principal evaluation fails: (&amp;{%!s(int32=0)})%!(EXTRA []bool=[false])
  2017-05-22 17:36:52.334 UTC [cauthdsl] func1 -&gt; DEBU 138 Gate evaluation fails: (&amp;{N:1 policies:&lt;signed_by:0 &gt; })
  2017-05-22 17:36:52.334 UTC [cauthdsl] func1 -&gt; DEBU 139 Gate evaluation starts: (&amp;{N:1 policies:&lt;signed_by:0 &gt; })
  2017-05-22 17:36:52.334 UTC [cauthdsl] func2 -&gt; DEBU 13a Principal evaluation starts: (&amp;{%!s(int32=0)}) (used [%!s(bool=false)])
  2017-05-22 17:36:52.334 UTC [msp] newIdentity -&gt; DEBU 13b Creating identity instance for ID &amp;{OrdererMSP DEFAULT}
  2017-05-22 17:36:52.334 UTC [cauthdsl] func2 -&gt; DEBU 13c Principal evaluation fails: (&amp;{%!s(int32=0)})%!(EXTRA []bool=[false])
  2017-05-22 17:36:52.334 UTC [cauthdsl] func1 -&gt; DEBU 13d Gate evaluation fails: (&amp;{N:1 policies:&lt;signed_by:0 &gt; })
  2017-05-22 17:36:52.334 UTC [cauthdsl] func1 -&gt; DEBU 13e Gate evaluation starts: (&amp;{N:1 policies:&lt;signed_by:0 &gt; })
  2017-05-22 17:36:52.334 UTC [cauthdsl] func2 -&gt; DEBU 13f Principal evaluation starts: (&amp;{%!s(int32=0)}) (used [%!s(bool=false)])
  2017-05-22 17:36:52.334 UTC [msp] newIdentity -&gt; DEBU 140 Creating identity instance for ID &amp;{OrdererMSP DEFAULT}
  2017-05-22 17:36:52.334 UTC [cauthdsl] func2 -&gt; DEBU 141 Principal evaluation fails: (&amp;{%!s(int32=0)})%!(EXTRA []bool=[false])
  2017-05-22 17:36:52.334 UTC [cauthdsl] func1 -&gt; DEBU 142 Gate evaluation fails: (&amp;{N:1 policies:&lt;signed_by:0 &gt; })
  2017-05-22 17:36:52.334 UTC [orderer/common/broadcast] Handle -&gt; WARN 143 Rejecting broadcast message because of filter error: Rejected by rule: *sigfilter.sigFilter
  2017-05-22 17:36:52.336 UTC [orderer/common/deliver] Handle -&gt; WARN 144 Error reading from stream: stream error: code = 1 desc = "context canceled"
  </code></pre>
  
  <p>crypto-config:  </p>
  
  <pre><code>OrdererOrgs:
    - Name: Orderer
      Domain: default.svc.cluster.local
      Specs:
        - Hostname: orderer
  PeerOrgs:
    - Name: Org1
      Domain: org1.svc.cluster.local
      Template:
        Count: 2
      Users:
        Count: 2
    - Name: Org2
      Domain: org2.svc.cluster.local
      Template:
        Count: 2
      Users:
        Count: 2
  </code></pre>