代码之家  ›  专栏  ›  技术社区  ›  Michael Blanza

BITCOIND:从127.0.0.1尝试使用ThreadRPCServer错误的密码

  •  1
  • Michael Blanza  · 技术社区  · 10 年前

    我的Bitcoind服务器正在运行 Ubuntu 14.04 块数更新,运行良好。我的问题是,当我访问 Bitcoin RPC 使用这个 curl 命令

    curl --user user_bitcoin:pass_bitcoin --data-binary 
    '{"jsonrpc": "1.0", "id":"curltest", "method": "getinfo", 
    "params": [] }' -H 'content-type: text/plain;' http://127.0.0.1:8332/
    

    它不返回任何结果。当我检查调试时。日志显示:

    ThreadRPCServer incorrect password attempt from 127.0.0.1
    

    我的比特币。conf设置如下

    server=1
    daemon=1
    rpcuser=<username>
    rpcpassword=<password>
    
    2 回复  |  直到 10 年前
        1
  •  2
  •   Suraj Rao Raas Masood    7 年前

    我通过开始解决了这个问题 bitcoind 具体如下:

    $bitcoind -rpcuser=USERNAME -rpcpassword=PASSWORD
    

    我之前在启动时遇到错误,原因是:

    $bitcoind
    
        2
  •  -1
  •   Michael Blanza    10 年前

    我明白了…问题是 bitcoin.conf 文件位于根前提下,而 bitcoind 文件位于 ubuntu chown 更改所有者。

    这是我执行命令的方式

    sudo chown ubuntu:ubuntu [file..]

    我希望这能有所帮助。