-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
求助!接入fabric 部署系统合约的时候报错! #605
Comments
从错误信息来看是超时了,确认一下网络情况 |
您好!特别特别感谢回复,我今天又重新试了好几次,都没成功,现在报错信息多了 拒绝连接 麻烦您帮忙看一下这个该怎么办呀 # bash deploy_system_contract.sh -t Fabric1.4 -c chains/fabric -P [INFO] deploy_system_contract, type: Fabric1.4, chain: chains/fabric, deploy: true, contract: proxy WeCrossProxy has not been deployed to: [Org1, Org2] path: classpath:chains/fabric/chaincode/WeCrossProxy/ Install WeCrossProxy:1709215863 to Org1 ... WARNING: asyncCustomCommand install: Install chaincode query to endorser exception: java.lang.Exception: org.hyperledger.fabric.sdk.exception.TransactionException: org.hyperledger.fabric.sdk.exception.ProposalException: getConfigBlock for channel mychannel failed with peer peer1. Status FAILURE, details: Channel Channel{id: 12, name: mychannel} Sending proposal with transaction: 86f49284e10bfc89611436ab51cf5f9642b62eb574c21a1f485f2dc4a19ff60a to Peer{ id: 10, name: peer1, channelName: mychannel, url: grpcs://localhost:9051} failed because of: gRPC failure=Status{code=UNAVAILABLE, description=io exception, cause=io.netty.channel.AbstractChannel$AnnotatedConnectException: 拒绝连接: localhost/0:0:0:0:0:0:0:1:9051 Caused by: java.net.ConnectException: 拒绝连接 at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method) at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:716) at io.netty.channel.socket.nio.NioSocketChannel.doFinishConnect(NioSocketChannel.java:337) at io.netty.channel.nio.AbstractNioChannel$AbstractNioUnsafe.finishConnect(AbstractNioChannel.java:334) at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:710) at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:658) at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:584) at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:496) at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:995) at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) at java.lang.Thread.run(Thread.java:750) } path: classpath:chains/fabric/chaincode/WeCrossProxy/ Install WeCrossProxy:1709215863 to Org2 ... WARNING: asyncCustomCommand install: Install chaincode query to endorser exception: java.lang.Exception: org.hyperledger.fabric.sdk.exception.TransactionException: org.hyperledger.fabric.sdk.exception.ProposalException: getConfigBlock for channel mychannel failed with peer peer1. Status FAILURE, details: Channel Channel{id: 12, name: mychannel} Sending proposal with transaction: 550bbfc1fc225ac48f869c1f6d31d3fbe71950bc2004e0a6491bf28f8f74c51c to Peer{ id: 10, name: peer1, channelName: mychannel, url: grpcs://localhost:9051} failed because of: gRPC failure=Status{code=UNAVAILABLE, description=io exception, cause=io.netty.channel.AbstractChannel$AnnotatedConnectException: 拒绝连接: localhost/0:0:0:0:0:0:0:1:9051 Caused by: java.net.ConnectException: 拒绝连接 at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method) at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:716) at io.netty.channel.socket.nio.NioSocketChannel.doFinishConnect(NioSocketChannel.java:337) at io.netty.channel.nio.AbstractNioChannel$AbstractNioUnsafe.finishConnect(AbstractNioChannel.java:334) at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:710) at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:658) at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:584) at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:496) at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:995) at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) at java.lang.Thread.run(Thread.java:750) } Instantiating WeCrossProxy:1709215863 to [Org1, Org2] ... java.lang.Exception: ERROR: asyncCustomCommand instantiate error: Install chaincode query to endorser exception: java.lang.Exception: org.hyperledger.fabric.sdk.exception.TransactionException: org.hyperledger.fabric.sdk.exception.ProposalException: getConfigBlock for channel mychannel failed with peer peer1. Status FAILURE, details: Channel Channel{id: 12, name: mychannel} Sending proposal with transaction: 540ddf6a3289d51c9136ed687b2828d7f80e797fe47c85347e1b2349410334fe to Peer{ id: 10, name: peer1, channelName: mychannel, url: grpcs://localhost:9051} failed because of: gRPC failure=Status{code=UNAVAILABLE, description=io exception, cause=io.netty.channel.AbstractChannel$AnnotatedConnectException: 拒绝连接: localhost/0:0:0:0:0:0:0:1:9051 Caused by: java.net.ConnectException: 拒绝连接 at sun.nio.ch.SocketChannelImpl.checkConnect(Native Method) at sun.nio.ch.SocketChannelImpl.finishConnect(SocketChannelImpl.java:716) at io.netty.channel.socket.nio.NioSocketChannel.doFinishConnect(NioSocketChannel.java:337) at io.netty.channel.nio.AbstractNioChannel$AbstractNioUnsafe.finishConnect(AbstractNioChannel.java:334) at io.netty.channel.nio.NioEventLoop.processSelectedKey(NioEventLoop.java:710) at io.netty.channel.nio.NioEventLoop.processSelectedKeysOptimized(NioEventLoop.java:658) at io.netty.channel.nio.NioEventLoop.processSelectedKeys(NioEventLoop.java:584) at io.netty.channel.nio.NioEventLoop.run(NioEventLoop.java:496) at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:995) at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74) at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30) at java.lang.Thread.run(Thread.java:750) } |
感谢帮助!!我解决了!刚刚对比了发现拒绝访问的原因在于docker中的容器都没运行,把它们都启动,重新运行命令就好了!第一次超时估计就是网络原因嘞!! |
大家好,我这里遇到了如下问题。
Caused by: org.fisco.bcos.sdk.jni.common.JniException: /github/home/.hunter/_Base/5d8365a/ac2539c/17cc295/Build/bcos-boostssl/Source/bcos-boostssl/websocket/WsService.cpp(233): Throw in function void bcos::boostssl::ws::WsService::syncConnectToEndpoints(bcos::boostssl::ws::EndPointsPtr)
|
拒绝连接和-4006基本上是连接问题,检查一下stub和本地链节点网络上是否联通。若还有问题请提供环境信息、区块链节点版本。 |
您好,衷心感谢您的帮助,请问检查stub除了检查routers路由下面的插件plugin含有对应区块链的stub.jar包和配置插件 |
拒绝连接有可能是区块链节点没启动/不是监听这些端口/网络策略问题,stub.toml内配置的节点IP端口要和实际情况下的节点一致。 |
[common]
name = 'bcos3'
type = 'BCOS3_ECDSA_WASM' # BCOS3_ECDSA_EVM、BCOS3_ECDSA_WASM、BCOS3_GM_EVM>、BCOS3_GM_WASM
[chain]
groupId = 'group0' # default group0
chainId = 'chain0' # default chain0
[service]
caCert = 'ca.crt'
sslCert = 'sdk.crt'
sslKey = 'sdk.key'
gmCaCert = 'sm_ca.crt'
gmSslCert = 'sm_sdk.crt'
gmSslKey = 'sm_sdk.key'
gmEnSslCert = 'sm_ensdk.crt'
gmEnSslKey = 'sm_ensdk.key'
messageTimeout = 300000 # ms, default 60000ms
connectionsStr = ['127.0.0.1:20200','127.0.0.1:20201','127.0.0.1:20202','127.0.0.1:20203']
disableSsl = false 采取的是文档给的stub.toml,节点也是正常运行的,就是执行部署代理相关合约就拒绝连接等问题。 |
能否telnet 127.0.0.1 20200成功? |
可以成功的。 |
请提供详细的日志文件 |
您好,由于在工作。回复的时间可能会延长。 # 部署代理合约
bash deploy_system_contract.sh -t BCOS3_ECDSA_EVM -c chains/bcos3 -P 会出现如下异常:
之后,bcos3里面的节点会被关闭。
提供的日志目录位于:~/wecross-networks/routers-payment/127.0.0.1-8250-25500/logs/error.log和log/cpp_sdk_log_2024041019.21.log。见附件 |
从cpp sdk的日志来看,是可以握手成功,可能是部署合约的操作时节点出现了问题。提供一下chains/bcos3的配置文件,以及节点的日志。 |
plugin下面的插件为:bcos3-stub-1.3.1.jar [common]
name = 'bcos3'
type = 'BCOS3_ECDSA_WASM' # BCOS3_ECDSA_EVM、BCOS3_ECDSA_WASM、BCOS3_GM_EVM、BCOS3_GM_WASM
[chain]
groupId = 'group0' # default group0
chainId = 'chain0' # default chain0
[service]
caCert = 'ca.crt'
sslCert = 'sdk.crt'
sslKey = 'sdk.key'
gmCaCert = 'sm_ca.crt'
gmSslCert = 'sm_sdk.crt'
gmSslKey = 'sm_sdk.key'
gmEnSslCert = 'sm_ensdk.crt'
gmEnSslKey = 'sm_ensdk.key'
messageTimeout = 300000 # ms, default 60000ms
connectionsStr = ['127.0.0.1:20200','127.0.0.1:20201','127.0.0.1:20202','127.0.0.1:20203']
disableSsl = false
[[resources]]
# name cannot be repeated
name = 'HelloWeCross'
type = 'BCOS_CONTRACT'
contractAddress = '0x8827cca7f0f38b861b62dae6d711efe92a1e3602'
节点node0的日志文件见附件。 节点node0的配置文件如下: [p2p]
listen_ip=0.0.0.0
listen_port=30300
; ssl or sm ssl
sm_ssl=false
nodes_path=./
nodes_file=nodes.json
[certificate_blacklist]
; crl.0 should be nodeid, nodeid's length is 512
;crl.0=
[certificate_whitelist]
; cal.0 should be nodeid, nodeid's length is 512
;cal.0=
[rpc]
listen_ip=0.0.0.0
listen_port=20200
thread_count=4
; ssl or sm ssl
sm_ssl=false
; ssl connection switch, if disable the ssl connection, default: false
;disable_ssl=true
[cert]
; directory the certificates located in
ca_path=./conf
; the ca certificate file
ca_cert=ca.crt
; the node private key file
node_key=ssl.key
; the node certificate file
node_cert=ssl.crt
[security]
private_key_path=conf/node.pem
[storage_security]
; enable data disk encryption or not, default is false
enable=false
; url of the key center, in format of ip:port
;key_center_url=
;cipher_data_key=
[consensus]
; min block generation time(ms)
min_seal_time=500
[storage]
data_path=data
enable_cache=true
; The granularity of the storage page, in bytes, must not be less than 4096 Bytes, the default is 10240 Bytes (10KB)
key_page_size=10240
pd_ssl_ca_path=
pd_ssl_cert_path=
pd_ssl_key_path=
enable_archive=false
archive_ip=127.0.0.1
archive_port=
[txpool]
; size of the txpool, default is 15000
limit=15000
; txs notification threads num, default is 2
notify_worker_num=2
; txs verification threads num, default is the number of CPU cores
;verify_worker_num=2
; txs expiration time, in seconds, default is 10 minutes
txs_expiration_time = 600
[redis]
; redis server ip
;server_ip=127.0.0.1
; redis server port
;server_port=6379
; redis request timeout, unit ms
;request_timeout=3000
; redis connection pool size
;connection_pool_size=16
; redis password, default empty
;password=
; redis db, default 0th
;db=0
[flow_control]
; the switch for distributed rate limit
; enable_distributed_ratelimit=false
; rate limiter stat reporter interval, unit: ms
; stat_reporter_interval=60000
; the module that does not limit bandwidth
; list of all modules: raft,pbft,amop,block_sync,txs_sync,light_node,cons_txs_sync
;
; modules_without_bw_limit=raft,pbft
; restrict the outgoing bandwidth of the node
; both integer and decimal is support, unit: Mb
;
; total_outgoing_bw_limit=10
; restrict the outgoing bandwidth of the the connection
; both integer and decimal is support, unit: Mb
;
; conn_outgoing_bw_limit=2
;
; specify IP to limit bandwidth, format: conn_outgoing_bw_limit_x.x.x.x=n
; conn_outgoing_bw_limit_192.108.0.1=3
; conn_outgoing_bw_limit_192.108.0.2=3
; conn_outgoing_bw_limit_192.108.0.3=3
;
; default bandwidth limit for the group
; group_outgoing_bw_limit=2
;
; specify group to limit bandwidth, group_outgoing_bw_limit_groupName=n
; group_outgoing_bw_limit_group0=2
; group_outgoing_bw_limit_group1=2
; group_outgoing_bw_limit_group2=2
[log]
enable=true
; print the log to std::cout or not, default print to the log files
enable_console_output = false
log_path=./log
; info debug trace
level=info
; MB
max_log_file_size=1024
; rotate the log every hour
;enable_rotate_by_hour=true |
早上好呀,github的配置文件,节点配置文件,以及日志文件已发送。请查收哈!
…---- 回复的原邮件 ----
| 发件人 | ***@***.***> |
| 日期 | 2024年04月11日 10:29 |
| 收件人 | ***@***.***> |
| 抄送至 | ***@***.***>***@***.***> |
| 主题 | Re: [WeBankBlockchain/WeCross] 求助!接入fabric 部署系统合约的时候报错! (Issue #605) |
从cpp sdk的日志来看,是可以握手成功,可能是部署合约的操作时节点出现了问题。提供一下chains/bcos3的配置文件,以及节点的日志。
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you commented.Message ID: ***@***.***>
|
FISCO BCOS尝试使用最新的3.2.x版本,目前看是3.2.6,并把数据版本号升级到3.2.6 在控制台中操作: setSystemConfigByKey compatibility_version 3.2.6 |
求助求助!之前手动组网在8250和8251端口分别部署了两个跨链路由,前几天下载了一个demo,但是是在别的文件夹里面,最近几天想开启之前手动组网部署的跨链路由,8251总是失败,显示超时,但8250能成功开启,不管是先开8250后开8251,还是先开8251后开8250,8251一直不行,求助,现在8251启动不了和我之前下载的demo有关系吗?报错信息如下 |
请提供一下日志 |
请问是这个吗?8251-25501的error log |
是的 |
请问是这个吗Error log |
|
看起来是证书问题。确认一下fabric配置的证书是否正确。 |
从这九个文件的属性中看,最近的修改时间都是2月28日 |
是同一条fabric链吗?是不是另外的demo起来了不同的fabric实例? |
我就是按照手动组网的那个文档搭的fabric链,没有另外再搭,demo的fabric链在另外的一个文件夹里面,不在同一个路径上,会有影响嘛?在demo上我之前做了一个htlc资产转换的例子,我昨天试着用bash clear.sh把demo清了,但是执行了这个命令之后,docker全都没有了,也不太行 |
虽然是不同路径,但是都是用一个channel名,docker容器也是全局的。demo的clear脚本是会清理所有fabric容器的,所以要做区分。 |
哦哦哦原来如此,那请问现在还有方法能回到我最初手动组网搭的那个网络吗,如果我把demo清了,再重新按照手动组网搭建fabric链的操作覆盖一下,这样会不会之前部署的fabric上的资源也没了?
…---- 回复的原邮件 ----
| 发件人 | ***@***.***> |
| 日期 | 2024年04月22日 15:56 |
| 收件人 | ***@***.***> |
| 抄送至 | ***@***.***>***@***.***> |
| 主题 | Re: [WeBankBlockchain/WeCross] 求助!接入fabric 部署系统合约的时候报错! (Issue #605) |
从这九个文件的属性中看,最近的修改时间都是2月28日
是同一条fabric链吗?是不是另外的demo起来了不同的fabric实例?
我就是按照手动组网的那个文档搭的fabric链,没有另外再搭,demo的fabric链在另外的一个文件夹里面,不在同一个路径上,会有影响嘛?在demo上我之前做了一个htlc资产转换的例子,我昨天试着用bash clear.sh把demo清了,但是执行了这个命令之后,docker全都没有了,也不太行
虽然是不同路径,但是都是用一个channel名,docker容器也是全局的。demo的clear脚本是会清理所有fabric容器的,所以要做区分。
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
|
您好,按照您提供的解决办法。我执行 w@1:~/wecross-networks/routers-payment/127.0.0.1-8250-25500$ bash deploy_system_contract.sh -t BCOS3_ECDSA_EVM -c chains/bcos3 -P
[INFO] deploy_system_contract, type: BCOS3_ECDSA_EVM, chain: chains/bcos3, deploy: true, contract: proxy
Not found available log config(./clog.ini or ./conf/clog.ini), use the default configuration items
Deploy WeCrossProxy to chain chains/bcos3 ...
Failed, please check contract or account. Exception details:
java.lang.Exception: Failed to deploy proxy contract.
at com.webank.wecross.stub.bcos3.preparation.ProxyContract.deployContractAndLinkBFS(ProxyContract.java:231)
at com.webank.wecross.stub.bcos3.preparation.ProxyContract.deploy(ProxyContract.java:256)
at com.webank.wecross.stub.bcos3.preparation.ProxyContractDeployment.deploy(ProxyContractDeployment.java:121)
at com.webank.wecross.stub.bcos3.preparation.ProxyContractDeployment.handle2Args(ProxyContractDeployment.java:87)
at com.webank.wecross.stub.bcos3.preparation.ProxyContractDeployment.main(ProxyContractDeployment.java:60)
|
最新问题已发送 |
代理合约部署成功,修改了bcos节点的版本,之后查看目录下的代理合约的abi文件。将其删除之后部署出现了问题。随后,重新使用add_chain.sh生成配置插件,发现stub.toml里面没有resources配置项,不知道是否因为版本导致账户相关问题,还请指导
…---- 回复的原邮件 ----
| 发件人 | ***@***.***> |
| 日期 | 2024年04月22日 16:01 |
| 收件人 | ***@***.***> |
| 抄送至 | ***@***.***>***@***.***> |
| 主题 | Re: [WeBankBlockchain/WeCross] 求助!接入fabric 部署系统合约的时候报错! (Issue #605) |
哦哦哦原来如此,那请问现在还有方法能回到我最初手动组网搭的那个网络吗,如果我把demo清了,再重新按照手动组网搭建fabric链的操作覆盖一下,这样会不会之前部署的fabric上的资源也没了?
---- 回复的原邮件 ----
| 发件人 | ***@***.***> |
| 日期 | 2024年04月22日 15:56 |
| 收件人 | ***@***.***> |
| 抄送至 | ***@***.***>***@***.***> |
| 主题 | Re: [WeBankBlockchain/WeCross] 求助!接入fabric 部署系统合约的时候报错! (Issue #605) |
从这九个文件的属性中看,最近的修改时间都是2月28日
是同一条fabric链吗?是不是另外的demo起来了不同的fabric实例?
我就是按照手动组网的那个文档搭的fabric链,没有另外再搭,demo的fabric链在另外的一个文件夹里面,不在同一个路径上,会有影响嘛?在demo上我之前做了一个htlc资产转换的例子,我昨天试着用bash clear.sh把demo清了,但是执行了这个命令之后,docker全都没有了,也不太行
虽然是不同路径,但是都是用一个channel名,docker容器也是全局的。demo的clear脚本是会清理所有fabric容器的,所以要做区分。
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you authored the thread.Message ID: ***@***.***>
—
Reply to this email directly, view it on GitHub, or unsubscribe.
You are receiving this because you commented.Message ID: ***@***.***>
|
报错信息如图
求助这种情况应该怎么解决啊,谢谢!!
The text was updated successfully, but these errors were encountered: