feitnomore / hyperledger-fabric-kubernetes Goto Github PK
View Code? Open in Web Editor NEWBlockchain Solution with Hyperledger Fabric + Hyperledger Explorer on Kubernetes
Blockchain Solution with Hyperledger Fabric + Hyperledger Explorer on Kubernetes
Error : role "root" does not exists while running ./createdb.sh
Executing SQL scripts...
psql: FATAL: role "root" does not exist
psql: FATAL: role "root" does not exist
Hi, I get this error running explorer on kubernetes, is there an issue with the configuration file?
Sync process is started for the network : [network-1] and client : [client-1]
<<<<<<<<<<<<<<<<<<<<<<<<<< Synchronizer Error >>>>>>>>>>>>>>>>>>
>>>Error : [ 'Failed to connect client peer, please check the configuration and peer status' ]<<<
<<<<<<<<<<<<<<<<<<<<<<< Closing client processor >>>>>>>>>>>>>>>>>>
>>>Received kill signal, shutting down gracefully<<<
<<<<<<<<<<<<<<<<<<<<<<< Closing explorer >>>>>>>>>>>>>>>>>>
>>>Closed out connections<<<
<<<<<<<<<<<<<<<<<<<<<<< Closing client processor >>>>>>>>>>>>>>>>>>>>>
thanks
When I run kubectl get node ,I am getting this:The connection to the server is lost localhost:8080 was refused - did you specify the right host or port?
how can I fix this
Chaincode Instantiate fails with failed to invoke chaincode name:"lscc" , error: timeout expired while starting chaincode rtrcc:1.0 for transaction.
I made a simplified model with one org one peer and one orderer.I have 2 k8s nodes
I am able to launch orderer and peer pods , create channel , fetch blocks , install chaincode.
But above error comes up during chain code instantiate.
Chaincode Image gets created in one of the nodes.
I can see docker container build on one of my nodes using docker ps -a but it gets removed quickly.
Instantiate hangs for about 10 minutes or more before throeing this error in CLI
Error: could not assemble transaction, err proposal response was not successful, error code 500,
msg timeout expired while starting chaincode rtrcc:1.0 for transaction
Peers Logs
stopInternal -> DEBU 2ecf kill container result id=nid1-peer0-org1-rtrcc-1.0 error="Container not running: nid1-peer0-org1-rtrcc-1.0"
[dockercontroller] stopInternal -> DEBU 2ed0 removing container id=nid1-peer0-org1-rtrcc-1.0
[dockercontroller] stopInternal -> DEBU 2ed1 remove container result id=nid1-peer0-org1-rtrcc-1.0 error=null
[container] unlockContainer -> DEBU 2ed2 container lock deleted(rtrcc-1.0)
[chaincode] Launch -> DEBU 2ed3 launch complete
[chaincode] Deregister -> DEBU 2ed4 deregister handler: rtrcc:1.0
[endorser] callChaincode -> INFO 2ed5 [rtrchannel01][647de024] Exit chaincode: name:"lscc" (537845ms)
[endorser] SimulateProposal -> ERRO 2ed6 [rtrchannel01][647de024] failed to invoke chaincode name:"lscc" , error: timeout expired while starting chaincode rtrcc:1.0 for transaction
Looks like the chain code containers is not able to reach k8s pods.
Hi, thanks for the detailed configuration steps, however I'm having some issues setting up Kafka. Are you running Kafka inside Kubernetes? If yes, would you mind sharing the config files? Thanks!
Hi,
Please help me . While creating the peer channel i am facing following issue:
root@fabric-tools:/fabric# peer channel create -o ${ORDERER_URL} -c ${CHANNEL_NAME} -f /fabric/${CHANNEL_NAME}.tx
2019-11-29 08:31:20.279 -02 [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized
2019-11-29 08:31:38.177 -02 [cli/common] readBlock -> INFO 002 Got status: &{NOT_FOUND}
2019-11-29 08:31:38.179 -02 [channelCmd] InitCmdFactory -> INFO 003 Endorser and orderer connections initialized
2019-11-29 08:31:38.859 -02 [cli/common] readBlock -> INFO 004 Got status: &{NOT_FOUND}
2019-11-29 08:31:38.865 -02 [channelCmd] InitCmdFactory -> INFO 005 Endorser and orderer connections initialized
2019-11-29 08:31:39.068 -02 [cli/common] readBlock -> INFO 006 Got status: &{NOT_FOUND}
2019-11-29 08:31:39.075 -02 [channelCmd] InitCmdFactory -> INFO 007 Endorser and orderer connections initialized
2019-11-29 08:31:39.281 -02 [cli/common] readBlock -> INFO 008 Got status: &{NOT_FOUND}
2019-11-29 08:31:39.283 -02 [channelCmd] InitCmdFactory -> INFO 009 Endorser and orderer connections initialized
2019-11-29 08:31:39.486 -02 [cli/common] readBlock -> INFO 00a Got status: &{NOT_FOUND}
2019-11-29 08:31:39.489 -02 [channelCmd] InitCmdFactory -> INFO 00b Endorser and orderer connections initialized
2019-11-29 08:31:39.693 -02 [cli/common] readBlock -> INFO 00c Got status: &{NOT_FOUND}
2019-11-29 08:31:39.697 -02 [channelCmd] InitCmdFactory -> INFO 00d Endorser and orderer connections initialized
2019-11-29 08:31:40.215 -02 [cli/common] readBlock -> INFO 00e Got status: &{NOT_FOUND}
2019-11-29 08:31:40.225 -02 [channelCmd] InitCmdFactory -> INFO 00f Endorser and orderer connections initialized
2019-11-29 08:31:40.433 -02 [cli/common] readBlock -> INFO 010 Got status: &{NOT_FOUND}
2019-11-29 08:31:40.442 -02 [channelCmd] InitCmdFactory -> INFO 011 Endorser and orderer connections initialized
2019-11-29 08:31:40.645 -02 [cli/common] readBlock -> INFO 012 Got status: &{NOT_FOUND}
2019-11-29 08:31:40.648 -02 [channelCmd] InitCmdFactory -> INFO 013 Endorser and orderer connections initialized
2019-11-29 08:31:40.850 -02 [cli/common] readBlock -> INFO 014 Got status: &{NOT_FOUND}
2019-11-29 08:31:40.853 -02 [channelCmd] InitCmdFactory -> INFO 015 Endorser and orderer connections initialized
2019-11-29 08:31:41.055 -02 [cli/common] readBlock -> INFO 016 Got status: &{NOT_FOUND}
2019-11-29 08:31:41.057 -02 [channelCmd] InitCmdFactory -> INFO 017 Endorser and orderer connections initialized
2019-11-29 08:31:41.258 -02 [cli/common] readBlock -> INFO 018 Got status: &{NOT_FOUND}
2019-11-29 08:31:41.260 -02 [channelCmd] InitCmdFactory -> INFO 019 Endorser and orderer connections initialized
2019-11-29 08:31:41.840 -02 [cli/common] readBlock -> INFO 01a Got status: &{NOT_FOUND}
2019-11-29 08:31:41.843 -02 [channelCmd] InitCmdFactory -> INFO 01b Endorser and orderer connections initialized
2019-11-29 08:31:42.048 -02 [cli/common] readBlock -> INFO 01c Got status: &{NOT_FOUND}
2019-11-29 08:31:42.050 -02 [channelCmd] InitCmdFactory -> INFO 01d Endorser and orderer connections initialized
2019-11-29 08:31:42.253 -02 [cli/common] readBlock -> INFO 01e Got status: &{NOT_FOUND}
2019-11-29 08:31:42.257 -02 [channelCmd] InitCmdFactory -> INFO 01f Endorser and orderer connections initialized
2019-11-29 08:31:42.460 -02 [cli/common] readBlock -> INFO 020 Got status: &{NOT_FOUND}
2019-11-29 08:31:42.462 -02 [channelCmd] InitCmdFactory -> INFO 021 Endorser and orderer connections initialized
2019-11-29 08:31:42.665 -02 [cli/common] readBlock -> INFO 022 Got status: &{NOT_FOUND}
2019-11-29 08:31:42.667 -02 [channelCmd] InitCmdFactory -> INFO 023 Endorser and orderer connections initialized
2019-11-29 08:31:42.908 -02 [cli/common] readBlock -> INFO 024 Got status: &{NOT_FOUND}
2019-11-29 08:31:42.912 -02 [channelCmd] InitCmdFactory -> INFO 025 Endorser and orderer connections initialized
Error: timeout waiting for channel creation
Thanks in advance
Hii,
C:\Users\Kale\Desktop\Hyperledger Fabric>kubectl logs blockchain-explorer-app-fcc5dd6f7-5ldpv
false 'ssl-certs' '/opt/explorer/ssl-certs'
D1213 12:28:01.320646516 6 env_linux.cc:71] Warning: insecure environment read function 'getenv' used
D1213 12:28:02.106781276 6 env_linux.cc:71] Warning: insecure environment read function 'getenv' used
******* Initialization started for hyperledger fabric platform ******, { 'first-network':
{ name: 'first-network',
profile: './connection-profile/first-network.json' } }
client_configs.name first-network client_configs.profile ./connection-profile/first-network.json
FabricUtils.createFabricClient
config.client.tlsEnable true
FabricConfig, this.config.channels mychannel
{ Error: ENOENT: no such file or directory, open '/fabric-path/fabric-samples/first-network/crypto-config/peerOrganizations/org1.example.com/users/[email protected]/msp/signcerts/[email protected]'
at Object.fs.openSync (fs.js:646:18)
at Object.fs.readFileSync (fs.js:551:33)
at FabricGateway._enrollUserIdentity (/opt/explorer/app/platform/fabric/gateway/FabricGateway.js:187:19)
at FabricGateway.initialize (/opt/explorer/app/platform/fabric/gateway/FabricGateway.js:116:28)
at
errno: -2,
code: 'ENOENT',
syscall: 'open',
path: '/fabric-path/fabric-samples/first-network/crypto-config/peerOrganizations/org1.example.com/users/[email protected]/msp/signcerts/[email protected]' }
********* call to initializeDetachClient **********
initializeDetachClient --> client_config { name: 'first-network',
profile: './connection-profile/first-network.json' } name first-network
initializeDetachClient, network config) { name: 'first-network',
version: '1.0.0',
license: 'Apache-2.0',
client:
{ tlsEnable: true,
adminUser: 'admin',
adminPassword: 'adminpw',
enableAuthentication: false,
organization: 'Org1',
connection: { timeout: [Object] } },
channels: { mychannel: { peers: [Object], connection: [Object] } },
organizations:
{ Org1MSP:
{ mspid: 'Org1MSP',
fullpath: true,
adminPrivateKey: [Object],
signedCert: [Object] } },
peers:
{ 'peer0.org1.example.com':
{ tlsCACerts: [Object],
url: 'grpcs://localhost:7051',
eventUrl: 'grpcs://localhost:7053',
grpcOptions: [Object] } } }
************************************* initializeDetachClient *************************************************
Error : Failed to connect client peer, please check the configuration and peer status
Info : Explorer will continue working with only DB data
************************************** initializeDetachClient ************************************************
FabricUtils.createDetachClient
initializeListener, client_name, client first-network { name: 'first-network',
profile: './connection-profile/first-network.json' }
Please open web browser to access ๏ผhttp://localhost:8080/
pid is 6
FabricConfig, this.config.channels mychannel
<<<<<<<<<<<<<<<<<<<<<<<<<< Explorer Error >>>>>>>>>>>>>>>>>>>>>
Error : [ 'Default client peer is down and no channel details available database' ]
Received kill signal, shutting down gracefully
<<<<<<<<<<<<<<<<<<<<<<<<<< Closing explorer >>>>>>>>>>>>>>>>>>>>>
Closed out connections
Thanks in advance
I used the api :here.
http://127.0.0.1:8080/api/register
{
"user": "string",
"password": "string",
"affiliation": "string",
"roles": "string"
}
and the err : 401 unauthorized.
Thank you in advance!
Following steps from README.md. I have encountered error at point 12.
Create a channel
root@fabric-tools:/fabric# ls Org1MSPanchors.tx Org3MSPanchors.tx channel1.tx configtx.yaml genesis.block Org2MSPanchors.tx Org4MSPanchors.tx config crypto-config root@fabric-tools:/fabric# export ORDERER_URL="blockchain-orderer:31010" root@fabric-tools:/fabric# export CORE_PEER_ADDRESSAUTODETECT="false" root@fabric-tools:/fabric# export CORE_PEER_NETWORKID="nid1" root@fabric-tools:/fabric# export CORE_PEER_LOCALMSPID="Org1MSP" /peerOrganizations/org1.example.com/peers/peer0.org1.example.com/msp/"pto-config root@fabric-tools:/fabric# export FABRIC_CFG_PATH="/etc/hyperledger/fabric" ME} -f /fabric/${CHANNEL_NAME}.tx annel create -o ${ORDERER_URL} -c ${CHANNEL_NA 2020-01-03 03:56:50.090 -02 [channelCmd] InitCmdFactory -> INFO 001 Endorser and orderer connections initialized Error: got unexpected status: SERVICE_UNAVAILABLE -- will not enqueue, consenter for this channel hasn't started yet root@fabric-tools:/fabric#
Do let me know how to resolve this, I am using kubectl and minikube in local.
Ubuntu 16.04
Thanking you in anticipation.
I am getting error while deploy hyperledger explorer on cluster as deployment
false 'ssl-certs' '/opt/explorer/ssl-certs'
postgres://hppoc:password@blockchain-explorer-db:5432/fabricexplorer
error when connecting to db: { Error: connect ECONNREFUSED 100.68.123.247:5432
at TCPConnectWrap.afterConnect [as oncomplete] (net.js:1191:14)
errno: 'ECONNREFUSED',
code: 'ECONNREFUSED',
syscall: 'connect',
address: '100.68.123.247',
port: 5432 }
******* Initialization started for hyperledger fabric platform ******, undefined
<<<<<<<<<<<<<<<<<<<<<<<<<< Explorer Error >>>>>>>>>>>>>>>>>>>>>
TypeError: Cannot read property 'size' of undefined
at Platform.initialize (/opt/explorer/app/platform/fabric/Platform.js:75:42)
at <anonymous>
at process._tickCallback (internal/process/next_tick.js:189:7)
error when connecting to db: TypeError: Cannot read property 'on' of undefined
at Timeout.handleDisconnect [as _onTimeout] (/opt/explorer/app/persistence/postgreSQL/PgService.js:68:16)
at ontimeout (timers.js:498:11)
at tryOnTimeout (timers.js:323:5)
at Timer.listOnTimeout (timers.js:290:5)
<<<<<<<<<<<<<<<<<<<<<<<<<< Explorer Error >>>>>>>>>>>>>>>>>>>>>
TypeError: "callback" argument must be a function
at setTimeout (timers.js:450:11)
at Timeout.handleDisconnect [as _onTimeout] (/opt/explorer/app/persistence/postgreSQL/PgService.js:85:5)
at ontimeout (timers.js:498:11)
at tryOnTimeout (timers.js:323:5)
at Timer.listOnTimeout (timers.js:290:5)
Received kill signal, shutting down gracefully
Closed out connections
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.