Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

Already on GitHub? Sign in to your account

RPC not working #1331

Closed
kirkmicz opened this Issue Jul 13, 2016 · 1 comment

Comments

Projects
None yet
2 participants

kirkmicz commented Jul 13, 2016 edited

Location: https://bitcoin.org/en/developer-examples#regtest-mode

After I follow all the instructions listed I noticed that my bitcoin.conf is not really working. Here's my bitcoin.conf :

server = 1
daemon = 1
rpcuser = someusername
rpcpassword = somepassword
rpcport = 5005
rpcconnect = 127.0.0.1

When I execute netstat -lnt nothings listen to port 5005

tcp          0      0 127.0.0.1:8332          0.0.0.0:*               LISTEN
tcp6        0      0 ::1:8332                :::*                    LISTEN

Since the default port for RPC is 8332 I tried

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

But nothings happen. In the debug.log it says:
ThreadRPCServer incorrect password attempt from 127.0.0.1

BTW my bitcoin.conf is located where the bitcoind is installed. Can someone help me to get rid of this?

THanks :)

I figure it out.. The problem is that the bitcoin.conf file is under the root premises while the bitcoind files is on the ubuntu premises. So all we need to do is use chown to change owner.

sudo chown ubuntu:ubuntu [file..]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment