启动 Hyperledger Explorer 时出现问题
Issue in starting up Hyperledger Explorer
我已经创建了一个多点网络。
我创建了 3 个组织 StancOrg
、StancOrgA
、StancOrgB
。这是 configtx.yaml 文件。
Organizations:
- &StancOrg
Name: StancOrgMSP
ID: StancOrgMSP
MSPDir: crypto-config/peerOrganizations/peerStanc.com/msp
AnchorPeers:
- Host: HOSTA.peerStanc.com
Port: 7051
- &StancOrgA
Name: StancOrgAMSP
ID: StancOrgAMSP
MSPDir: crypto-config/peerOrganizations/peerStancA.com/msp
AnchorPeers:
- Host: HOSTA.peerStancA.com
Port: 7051
- &StancOrgB
Name: StancOrgBMSP
ID: StancOrgBMSP
MSPDir: crypto-config/peerOrganizations/peerStancB.com/msp
AnchorPeers:
- Host: HOSTA.peerStancB.com
Port: 7051
- &OrdererOrg
Name: StancOrderer
ID: StancOrdererMSP
MSPDir: crypto-config/ordererOrganizations/StancOrdr.com/msp
Capabilities:
Global: &ChannelCapabilities
V1_1: true
Orderer: &OrdererCapabilities
V1_1: true
Application: &ApplicationCapabilities
V1_2: true
Application: &ApplicationDefaults
Organizations:
Orderer: &OrdererDefaults
OrdererType: solo
Addresses:
- StancOrderer.StancOrdr.com:7050
BatchTimeout: 0.1s
BatchSize:
MaxMessageCount: 10
AbsoluteMaxBytes: 99 MB
PreferredMaxBytes: 512 KB
Kafka:
Brokers:
- 127.0.0.1:9092
Organizations:
Profiles:
我在我的网络上创建了一个 masterchannel
。
我正在尝试为创建的结构网络设置 Hyperledger Explorer。
我还根据创建的结构网络更新了 config.json。
{
"network-configs": {
"network-1": {
"version": "1.0",
"clients": {
"client-1": {
"tlsEnable": false,
"organization": "StancOrgMSP",
"channel": "masterchannel",
"credentialStore": {
"path": "./tmp/credentialStore_Org1/credential",
"cryptoStore": {
"path": "./tmp/credentialStore_Org1/crypto"
}
}
}
},
"channels": {
"masterchannel": {
"peers": {
"HOSTA.peerStanc.com": {}
},
"connection": {
"timeout": {
"peer": {
"endorser": "6000",
"eventHub": "6000",
"eventReg": "6000"
}
}
}
}
},
"organizations": {
"StancOrgMSP": {
"mspid": "StancOrgMSP",
"fullpath": false,
"adminPrivateKey": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/peerOrganizations/peerStanc.com/users/Admin@peerStanc.com/msp/keystore"
},
"signedCert": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/peerOrganizations/peerStanc.com/users/Admin@peerStanc.com/msp/signcerts"
}
},
"StancOrgAMSP": {
"mspid": "StancOrgAMSP",
"adminPrivateKey": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/peerOrganizations/peerStancA.com/users/Admin@peerStanc.com/msp/keystore"
}
},
"StancOrgBMSP": {
"mspid": "StancOrgBMSP",
"adminPrivateKey": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/peerOrganizations/peerStancB.com/users/Admin@peerStanc.com/msp/keystore"
}
},
"StancOrdererMSP": {
"mspid": "StancOrdererMSP",
"adminPrivateKey": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/ordererOrganizations/StancOrdr.com/users/Admin@StancOrdr.com/msp/keystore"
}
}
},
"peers": {
"HOSTA.peerStanc.com": {
"tlsCACerts": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/peerOrganizations/peerStanc.com/peers/HOSTA.peerStanc.com/tls/ca.crt"
},
"url": "grpc://localhost:7051",
"eventUrl": "grpc://localhost:7053",
"grpcOptions": {
"ssl-target-name-override": "HOSTA.peerStanc.com"
}
},
"HOSTA.peerStancA.com": {
"url": "grpc://localhost:8051"
},
"HOSTA.peerStancB.com": {
"url": "grpc://localhost:9051"
}
},
"orderers": {
"StancOrderer.StancOrdr.com": {
"url": "grpc://localhost:7050"
}
}
},
"network-2": {}
},
"configtxgenToolPath": "~/Documents/Application/bin",
"license": "Apache-2.0"
}
我成功了build.But它无法启动资源管理器应用程序。
我得到以下错误。
postgres://hppoc:password@127.0.0.1:5432/fabricexplorer
**************************************************************************************
Error : Failed to connect client peer, please check the configuration and peer status
Info : Explorer will continue working with only DB data
**************************************************************************************
(node:10952) DeprecationWarning: grpc.load: Use the @grpc/proto-loader module with grpc.loadPackageDefinition instead
<<<<<<<<<<<<<<<<<<<<<<<<<< Explorer Error >>>>>>>>>>>>>>>>>>>>>
Error : [ 'Default client peer is down and no channel details available database' ]
Received kill signal, shutting down gracefully
Closed out connections
我提供的 tls 为 false 并更新了 grpc。网络也在指定端口上。
感谢帮助。
应使用完整路径 /home/user/yourPath
而非快捷方式 ~/yourPath
设置路径。
无论如何,请记住始终检查应用程序日志,而不仅仅是控制台,因为有时它们会显示更多信息。
我发现这是一个npm包的问题,你最好修改blockchain-explorer下的package.json,把^换成~来下载小版本包。
我已经创建了一个多点网络。
我创建了 3 个组织 StancOrg
、StancOrgA
、StancOrgB
。这是 configtx.yaml 文件。
Organizations:
- &StancOrg
Name: StancOrgMSP
ID: StancOrgMSP
MSPDir: crypto-config/peerOrganizations/peerStanc.com/msp
AnchorPeers:
- Host: HOSTA.peerStanc.com
Port: 7051
- &StancOrgA
Name: StancOrgAMSP
ID: StancOrgAMSP
MSPDir: crypto-config/peerOrganizations/peerStancA.com/msp
AnchorPeers:
- Host: HOSTA.peerStancA.com
Port: 7051
- &StancOrgB
Name: StancOrgBMSP
ID: StancOrgBMSP
MSPDir: crypto-config/peerOrganizations/peerStancB.com/msp
AnchorPeers:
- Host: HOSTA.peerStancB.com
Port: 7051
- &OrdererOrg
Name: StancOrderer
ID: StancOrdererMSP
MSPDir: crypto-config/ordererOrganizations/StancOrdr.com/msp
Capabilities:
Global: &ChannelCapabilities
V1_1: true
Orderer: &OrdererCapabilities
V1_1: true
Application: &ApplicationCapabilities
V1_2: true
Application: &ApplicationDefaults
Organizations:
Orderer: &OrdererDefaults
OrdererType: solo
Addresses:
- StancOrderer.StancOrdr.com:7050
BatchTimeout: 0.1s
BatchSize:
MaxMessageCount: 10
AbsoluteMaxBytes: 99 MB
PreferredMaxBytes: 512 KB
Kafka:
Brokers:
- 127.0.0.1:9092
Organizations:
Profiles:
我在我的网络上创建了一个 masterchannel
。
我正在尝试为创建的结构网络设置 Hyperledger Explorer。 我还根据创建的结构网络更新了 config.json。
{
"network-configs": {
"network-1": {
"version": "1.0",
"clients": {
"client-1": {
"tlsEnable": false,
"organization": "StancOrgMSP",
"channel": "masterchannel",
"credentialStore": {
"path": "./tmp/credentialStore_Org1/credential",
"cryptoStore": {
"path": "./tmp/credentialStore_Org1/crypto"
}
}
}
},
"channels": {
"masterchannel": {
"peers": {
"HOSTA.peerStanc.com": {}
},
"connection": {
"timeout": {
"peer": {
"endorser": "6000",
"eventHub": "6000",
"eventReg": "6000"
}
}
}
}
},
"organizations": {
"StancOrgMSP": {
"mspid": "StancOrgMSP",
"fullpath": false,
"adminPrivateKey": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/peerOrganizations/peerStanc.com/users/Admin@peerStanc.com/msp/keystore"
},
"signedCert": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/peerOrganizations/peerStanc.com/users/Admin@peerStanc.com/msp/signcerts"
}
},
"StancOrgAMSP": {
"mspid": "StancOrgAMSP",
"adminPrivateKey": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/peerOrganizations/peerStancA.com/users/Admin@peerStanc.com/msp/keystore"
}
},
"StancOrgBMSP": {
"mspid": "StancOrgBMSP",
"adminPrivateKey": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/peerOrganizations/peerStancB.com/users/Admin@peerStanc.com/msp/keystore"
}
},
"StancOrdererMSP": {
"mspid": "StancOrdererMSP",
"adminPrivateKey": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/ordererOrganizations/StancOrdr.com/users/Admin@StancOrdr.com/msp/keystore"
}
}
},
"peers": {
"HOSTA.peerStanc.com": {
"tlsCACerts": {
"path": "~/Documents/Application/fabric-multipeer/crypto-config/peerOrganizations/peerStanc.com/peers/HOSTA.peerStanc.com/tls/ca.crt"
},
"url": "grpc://localhost:7051",
"eventUrl": "grpc://localhost:7053",
"grpcOptions": {
"ssl-target-name-override": "HOSTA.peerStanc.com"
}
},
"HOSTA.peerStancA.com": {
"url": "grpc://localhost:8051"
},
"HOSTA.peerStancB.com": {
"url": "grpc://localhost:9051"
}
},
"orderers": {
"StancOrderer.StancOrdr.com": {
"url": "grpc://localhost:7050"
}
}
},
"network-2": {}
},
"configtxgenToolPath": "~/Documents/Application/bin",
"license": "Apache-2.0"
}
我成功了build.But它无法启动资源管理器应用程序。
我得到以下错误。
postgres://hppoc:password@127.0.0.1:5432/fabricexplorer
**************************************************************************************
Error : Failed to connect client peer, please check the configuration and peer status
Info : Explorer will continue working with only DB data
**************************************************************************************
(node:10952) DeprecationWarning: grpc.load: Use the @grpc/proto-loader module with grpc.loadPackageDefinition instead
<<<<<<<<<<<<<<<<<<<<<<<<<< Explorer Error >>>>>>>>>>>>>>>>>>>>>
Error : [ 'Default client peer is down and no channel details available database' ]
Received kill signal, shutting down gracefully
Closed out connections
我提供的 tls 为 false 并更新了 grpc。网络也在指定端口上。
感谢帮助。
应使用完整路径 /home/user/yourPath
而非快捷方式 ~/yourPath
设置路径。
无论如何,请记住始终检查应用程序日志,而不仅仅是控制台,因为有时它们会显示更多信息。
我发现这是一个npm包的问题,你最好修改blockchain-explorer下的package.json,把^换成~来下载小版本包。