ethereum - 无法连接到远程 geth:等待管道 '\\.\pipe\geth.ipc' 可用时超时
问题描述
我运行这个命令geth attach ipc:\.\pipe\geth.ipc显示这种类型的消息
Unable to attach to remote geth: Timed out waiting for pipe '\\.\pipe\geth.ipc' to come available
请你给我建议。我,是新手。
解决方案
在运行 geth 节点本身时,指定 ipcpath。它将在单个窗口中为您打开 geth 节点、ipc 和 javascript 控制台。试试下面的命令。
geth --datadir ../../private-network/node1 \
--networkid 2061 \(it should be same, if you are running multiple nodes)
--port 30304 \ (should be different for every nodes)
--nodiscover \
--rpc \
--rpcaddr 127.0.0.1 \
--rpcport 8504 \ (should be different for every nodes)
--ipcpath ../../private-network/node1/geth.ipc \
--mine --minerthreads 1 --gasprice "10000" \
--etherbase 0xf628e41f3ca68341e9857102d4b3040aa418d763 \ (your coinbase account address)
--verbosity 3 console
给定脚本的一个示例。
geth --datadir=D:/Blockchain_Tech/node1 --networkid 2061 --port 30305 --nodiscover --rpc --rpcaddr 127.0.0.1 --rpcport 8505 --ipcpath=D:/Blockchain_Tech/node1/geth.ipc --mine --minerthreads 1 --gasprice "10000" --etherbase 0x58ef18d5667552b4c0524b9a78cbf9493d2bd74a --verbosity 3 console
注意:- 此脚本适用于 MS-Windows。
推荐阅读
- c++ - 如何在运行时在 C++ 对象数组中动态追加新对象并打印它们
- java - 如何在equals()中可扩展地考虑空值?
- javascript - Elasticsearch javascript 文件无法加载
- mysql - 在 mySQL 中将返回值格式化为小数点后 2 位
- go - 如何修改未知类型结构中的字段?
- javascript - 词法作用域和 JavaScript 的 `this` 有什么关系?
- javascript - 伪经典继承相对于函数继承(工厂函数)有哪些技术优势?
- python - 为棋盘游戏的 Keras 模型生成适当的输出层
- spring - 在配置中有关于 DispatcherServletPath 的错误
- python - flask-sqlalchemy 查询具有不同值的多行