bcosorg / bcos

BCOS平台(Be Credible, Open & Secure)
GNU General Public License v3.0
872 stars 286 forks source link

查看网络状况 #36

Open luoyaa opened 7 years ago

luoyaa commented 7 years ago

babel-node monitor.js

admin_peers 返回解析失败![object Object] 已连接节点数:0

这是什么原因啊?

toxotguo commented 7 years ago

@18710006370 这个输出代表的含义是当前节点没有连上其他节点。如果网络中只有当前这个节点,则是正常的。

zhige2003 commented 6 years ago

有相同的问题,是在阿里云同一主机上启动了两个节点,核查了config.json和node.json配置文件都是一致的,请大神帮忙看看。

toxotguo commented 6 years ago

@zhige2003 请把两个节点的config.json 和genesis.json 和babel-node tool.js NodeAction all的执行结果贴上来看看。

zhige2003 commented 6 years ago

@toxotguo node-0的config.json { "sealEngine": "PBFT", "systemproxyaddress":"0xa4f9211d4f5ead26e9d3e8b8bf28eed5fd070fdd", "listenip":"127.0.0.1", "rpcport":"35500", "p2pport":"53300", "wallet":"/nodedata/keys.info", "keystoredir":"/nodedata/keystore/", "datadir":"/nodedata/", "vm":"interpreter", "networkid":"123456", "logverbosity":"8", "coverlog":"OFF", "eventlog":"ON", "logconf":"/nodedata/log.conf", "params": { "accountStartNonce": "0x0", "maximumExtraDataSize": "0x0", "tieBreakingGas": false, "blockReward": "0x0", "networkID" : "0x0" }, "NodeextraInfo":[ { "Nodeid":"6c58fcb2ed908627d51b3b81a6ffffe668e6a1e1e7f4eeeebab3d4dd3de7faf932eeca9af0e2915202d09583fcad5569bec40f1e7422b8eaa7b9024a39312992", "Nodedesc": "node0", "Agencyinfo": "node0", "Peerip": "127.0.0.1", "Identitytype": 1, "Port":53300, "Idx":0 } ] }

node-0的genesis.json { "nonce": "0x0", "difficulty": "0x0", "mixhash": "0x0", "coinbase": "0x0", "timestamp": "0x0", "parentHash": "0x0", "extraData": "0x0", "gasLimit": "0x13880000000000", "god":"0x4d23de3297034cdd4a58db35f659a9b61fc7577b", "alloc": {}, "initMinerNodes":["6c58fcb2ed908627d51b3b81a6ffffe668e6a1e1e7f4eeeebab3d4dd3de7faf932eeca9af0e2915202d09583fcad5569bec40f1e7422b8eaa7b9024a39312992"] }

node-1的config.json { "sealEngine": "PBFT", "systemproxyaddress":"0xa4f9211d4f5ead26e9d3e8b8bf28eed5fd070fdd", "listenip":"127.0.0.1", "rpcport":"35501", "p2pport":"53301", "wallet":"/nodedata/keys.info", "keystoredir":"/nodedata/keystore/", "datadir":"/nodedata/", "vm":"interpreter", "networkid":"123456", "logverbosity":"8", "coverlog":"OFF", "eventlog":"ON", "logconf":"/nodedata/log.conf", "params": { "accountStartNonce": "0x0", "maximumExtraDataSize": "0x0", "tieBreakingGas": false, "blockReward": "0x0", "networkID" : "0x0" }, "NodeextraInfo":[ { "Nodeid":"6c58fcb2ed908627d51b3b81a6ffffe668e6a1e1e7f4eeeebab3d4dd3de7faf932eeca9af0e2915202d09583fcad5569bec40f1e7422b8eaa7b9024a39312992", "Nodedesc": "node0", "Agencyinfo": "node0", "Peerip": "127.0.0.1", "Identitytype": 1, "Port":53300, "Idx":0 }, { "Nodeid":"5d5be6b9c976f1d780c33946712ee3cb5fbeaf3d991aa592c68131bb35fdae8d2981369aa8775ed00fa55085415bbdbd22a760cf7b2ffdeda97cd9274b42a8d2", "Nodedesc": "node1", "Agencyinfo": "node1", "Peerip": "127.0.0.1", "Identitytype": 1, "Port":53301, "Idx":1 } ] }

node-1的genesis.json { "nonce": "0x0", "difficulty": "0x0", "mixhash": "0x0", "coinbase": "0x0", "timestamp": "0x0", "parentHash": "0x0", "extraData": "0x0", "gasLimit": "0x13880000000000", "god":"0x4d23de3297034cdd4a58db35f659a9b61fc7577b", "alloc": {}, "initMinerNodes":["6c58fcb2ed908627d51b3b81a6ffffe668e6a1e1e7f4eeeebab3d4dd3de7faf932eeca9af0e2915202d09583fcad5569bec40f1e7422b8eaa7b9024a39312992"] }

babel-node tool.js NodeAction all的结果 RPC=http://127.0.0.1:35500 Ouputpath=./output/ { HttpProvider: 'http://127.0.0.1:35500', Ouputpath: './output/', privKey: '7d373eb4872368bb51d7ac083ac4752bca9ecb70066df43457500528faeea8f3', account: '0xec23de21751378995fe87691f1c2e6c895cfa07b' } Soc File :NodeAction Func :all 系统合约地址0xa4f9211d4f5ead26e9d3e8b8bf28eed5fd070fdd NodeAction合约地址0xe7778129b597fea8d9aa923f4fff32a699d59d23 NodeIdsLength= 2 ----------node 0--------- id=6c58fcb2ed908627d51b3b81a6ffffe668e6a1e1e7f4eeeebab3d4dd3de7faf932eeca9af0e2915202d09583fcad5569bec40f1e7422b8eaa7b9024a39312992 ip=127.0.0.1 port=53300 category=1 desc=node0 CAhash= agencyinfo=node0 blocknumber=142729 Idx=0 ----------node 1--------- id=5d5be6b9c976f1d780c33946712ee3cb5fbeaf3d991aa592c68131bb35fdae8d2981369aa8775ed00fa55085415bbdbd22a760cf7b2ffdeda97cd9274b42a8d2 ip=127.0.0.1 port=53301 category=1 desc=node1 CAhash= agencyinfo=node1 blocknumber=142773 Idx=1

原始邮件 发件人:toxotguonotifications@github.com 收件人:bcosorg/bcosbcos@noreply.github.com 抄送:zhige2003liguangyu_126@126.com; Mentionmention@noreply.github.com 发送时间:2018年3月4日(周日) 11:10 主题:Re: [bcosorg/bcos] 查看网络状况 (#36)

@zhige2003 请把两个节点的config.json 和genesis.json 和babel-node tool.js NodeAction all的执行结果贴上来看看。 — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

zhige2003 commented 6 years ago

我是在阿里云主机上进行安装,发现个现象,端口都启动到了ipv6地址上,这个是在bcos上面可以指定到ipv4上么?

原始邮件 发件人:liguangyu_126liguangyu_126@126.com 收件人:bcosorg/bcosbcos@noreply.github.com; bcosorg/bcosreply@reply.github.com 抄送:Mentionmention@noreply.github.com 发送时间:2018年3月4日(周日) 21:25 主题:Re: [bcosorg/bcos] 查看网络状况 (#36)

node-0的config.json { "sealEngine": "PBFT", "systemproxyaddress":"0xa4f9211d4f5ead26e9d3e8b8bf28eed5fd070fdd", "listenip":"127.0.0.1", "rpcport":"35500", "p2pport":"53300", "wallet":"/nodedata/keys.info", "keystoredir":"/nodedata/keystore/", "datadir":"/nodedata/", "vm":"interpreter", "networkid":"123456", "logverbosity":"8", "coverlog":"OFF", "eventlog":"ON", "logconf":"/nodedata/log.conf", "params": { "accountStartNonce": "0x0", "maximumExtraDataSize": "0x0", "tieBreakingGas": false, "blockReward": "0x0", "networkID" : "0x0" }, "NodeextraInfo":[ { "Nodeid":"6c58fcb2ed908627d51b3b81a6ffffe668e6a1e1e7f4eeeebab3d4dd3de7faf932eeca9af0e2915202d09583fcad5569bec40f1e7422b8eaa7b9024a39312992", "Nodedesc": "node0", "Agencyinfo": "node0", "Peerip": "127.0.0.1", "Identitytype": 1, "Port":53300, "Idx":0 } ] }

node-0的genesis.json { "nonce": "0x0", "difficulty": "0x0", "mixhash": "0x0", "coinbase": "0x0", "timestamp": "0x0", "parentHash": "0x0", "extraData": "0x0", "gasLimit": "0x13880000000000", "god":"0x4d23de3297034cdd4a58db35f659a9b61fc7577b", "alloc": {}, "initMinerNodes":["6c58fcb2ed908627d51b3b81a6ffffe668e6a1e1e7f4eeeebab3d4dd3de7faf932eeca9af0e2915202d09583fcad5569bec40f1e7422b8eaa7b9024a39312992"] }

node-1的config.json { "sealEngine": "PBFT", "systemproxyaddress":"0xa4f9211d4f5ead26e9d3e8b8bf28eed5fd070fdd", "listenip":"127.0.0.1", "rpcport":"35501", "p2pport":"53301", "wallet":"/nodedata/keys.info", "keystoredir":"/nodedata/keystore/", "datadir":"/nodedata/", "vm":"interpreter", "networkid":"123456", "logverbosity":"8", "coverlog":"OFF", "eventlog":"ON", "logconf":"/nodedata/log.conf", "params": { "accountStartNonce": "0x0", "maximumExtraDataSize": "0x0", "tieBreakingGas": false, "blockReward": "0x0", "networkID" : "0x0" }, "NodeextraInfo":[ { "Nodeid":"6c58fcb2ed908627d51b3b81a6ffffe668e6a1e1e7f4eeeebab3d4dd3de7faf932eeca9af0e2915202d09583fcad5569bec40f1e7422b8eaa7b9024a39312992", "Nodedesc": "node0", "Agencyinfo": "node0", "Peerip": "127.0.0.1", "Identitytype": 1, "Port":53300, "Idx":0 }, { "Nodeid":"5d5be6b9c976f1d780c33946712ee3cb5fbeaf3d991aa592c68131bb35fdae8d2981369aa8775ed00fa55085415bbdbd22a760cf7b2ffdeda97cd9274b42a8d2", "Nodedesc": "node1", "Agencyinfo": "node1", "Peerip": "127.0.0.1", "Identitytype": 1, "Port":53301, "Idx":1 } ] }

node-1的genesis.json { "nonce": "0x0", "difficulty": "0x0", "mixhash": "0x0", "coinbase": "0x0", "timestamp": "0x0", "parentHash": "0x0", "extraData": "0x0", "gasLimit": "0x13880000000000", "god":"0x4d23de3297034cdd4a58db35f659a9b61fc7577b", "alloc": {}, "initMinerNodes":["6c58fcb2ed908627d51b3b81a6ffffe668e6a1e1e7f4eeeebab3d4dd3de7faf932eeca9af0e2915202d09583fcad5569bec40f1e7422b8eaa7b9024a39312992"] }

babel-node tool.js NodeAction all的结果 RPC=http://127.0.0.1:35500 Ouputpath=./output/ { HttpProvider: 'http://127.0.0.1:35500', Ouputpath: './output/', privKey: '7d373eb4872368bb51d7ac083ac4752bca9ecb70066df43457500528faeea8f3', account: '0xec23de21751378995fe87691f1c2e6c895cfa07b' } Soc File :NodeAction Func :all 系统合约地址0xa4f9211d4f5ead26e9d3e8b8bf28eed5fd070fdd NodeAction合约地址0xe7778129b597fea8d9aa923f4fff32a699d59d23 NodeIdsLength= 2 ----------node 0--------- id=6c58fcb2ed908627d51b3b81a6ffffe668e6a1e1e7f4eeeebab3d4dd3de7faf932eeca9af0e2915202d09583fcad5569bec40f1e7422b8eaa7b9024a39312992 ip=127.0.0.1 port=53300 category=1 desc=node0 CAhash= agencyinfo=node0 blocknumber=142729 Idx=0 ----------node 1--------- id=5d5be6b9c976f1d780c33946712ee3cb5fbeaf3d991aa592c68131bb35fdae8d2981369aa8775ed00fa55085415bbdbd22a760cf7b2ffdeda97cd9274b42a8d2 ip=127.0.0.1 port=53301 category=1 desc=node1 CAhash= agencyinfo=node1 blocknumber=142773 Idx=1

原始邮件 发件人:toxotguonotifications@github.com 收件人:bcosorg/bcosbcos@noreply.github.com 抄送:zhige2003liguangyu_126@126.com; Mentionmention@noreply.github.com 发送时间:2018年3月4日(周日) 11:10 主题:Re: [bcosorg/bcos] 查看网络状况 (#36)

@zhige2003 请把两个节点的config.json 和genesis.json 和babel-node tool.js NodeAction all的执行结果贴上来看看。 — You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

zhige2003 commented 6 years ago

bcos平台是否可以只监听ipv4的端口?目前我启动之后,p2p端口都监听到ipv6端口了。

zhige2003 commented 6 years ago

@toxotguo 您是否看出来什么原因?