2017-10-11 241 views
0

而註冊新用戶,我得到這個錯誤布-CA客戶端錯誤

2017/10/11 07:53:11 [DEBUG] Received request 
POST /api/v1/enroll 
Authorization: Basic YWRtaW46YWRtaW5wdw== 
{"caName":"","certificate_request":"-----BEGIN CERTIFICATE REQUEST-----\r\nMIHMMHICAQAwEDEOMAwGA1UEAwwFYWRtaW4wWTATBgcqhkjOPQIBBggqhkjOPQMB\r\nBwNCAASUWo/5gS9H/PSvsiNK2iGsWw0nv7tsVnGG+ZY3cWFJ3ANz6cNmd+lRLZS3\r\nBhHYD/FZhhqwBucMHFE1sB9SqqEnoAAwDAYIKoZIzj0EAwIFAANIADBFAiEAiHjk\r\ncyM3gzqYbLAFVz8kHahVXtAjEOb82q7jiP35Tm4CIAHQsotf2301RCBVQ6i5hb9i\r\nByHhofDyhEFbch7gJVVF\r\n-----END CERTIFICATE REQUEST-----\r\n"} 
2017/10/11 07:53:11 [DEBUG] Directing traffic to default CA 
2017/10/11 07:53:11 [DEBUG] DB: Getting identity admin 
2017/10/11 07:53:11 [DEBUG] Failed to get identity 'admin': sql: no rows in result set 

我有我自己的面料-CA-服務器config.yaml文件

identities: 
    - name: admin 
     pass: adminpw 
     type: client 
     affiliation: "" 
     maxenrollments: -1 
     attrs: 
      hf.Registrar.Roles: "client,user,peer,validator,auditor" 
      hf.Registrar.DelegateRoles: "client,user,validator,auditor" 
      hf.Revoker: true 
      hf.IntermediateCA: true 
      hf.GenCRL: true 
affiliations: 
    org1: 
     - department1 
     - department2 
    org2: 
     - department1 
     - department2 
    org3: 
     - department1 
     - department2 
    org4: 
     - department1 
     - department2 

```

我瀏覽.db文件我沒有任何表

+0

從內存中,我認爲服務器喜歡創建數據庫,然後填充它。這可能已經改變了,但我記得提交了一個問題,因爲並非所有用戶都有足夠的權限來創建數據庫(例如共享主機平臺上的用戶)。無論如何,你的問題是自我解釋 - 服務器數據庫尚未實例化,因此沒有管理員用戶。 – PassKit

回答

3

刪除面料-CA-server.db中發現任何數據文件和密鑰庫中重新啓動ca_Peers和它的工作

+0

嗨Darshu,我遇到了同樣的問題..你的意思是進入ca容器並運行'rm -rf/etc/hyperledger/fabric-ca-server/fabric-ca-server.db' .. 什麼你是指密鑰庫中的密鑰?它是'/ tmp/fabric_ *'的東西嗎? –