Bitcoin Forum

Bitcoin => Development & Technical Discussion => Topic started by: Ervin on May 05, 2014, 08:54:59 AM



Title: Bitcoind sendtoaddress dosen't work
Post by: Ervin on May 05, 2014, 08:54:59 AM
Hello everyone.

i have bitcoind installed on VPS debian server.
My site communicate with bitcoind via PHP RPC-JSON, it works great, i can check getinfo(), receving amount etc.
I would like to send coins to my blockchain wallet, but when i tried to call $bitcoind->sendtoaddress(amount,address,comment1,commen2), i got an 500 internal error.


Code:
Warning: fopen(http://...@127.0.0.1:8332/): failed to open stream: HTTP request failed! HTTP/1.1 500 Internal Server Error in D:\xampp\htdocs\bitcoind2\JsonRPCClient.php on line 141

Fatal error: Uncaught exception 'Exception' with message 'Unable to connect to http://myuser:mypwd@127.0.0.1:8332/' in D:\xampp\htdocs\bitcoind2\JsonRPCClient.php:149 Stack trace: #0 D:\xampp\htdocs\bitcoind2\Bitcoin.php(719): JsonRPCClient->__call('sendtoaddress', Array) #1 D:\xampp\htdocs\bitcoind2\Bitcoin.php(719): JsonRPCClient->sendtoaddress('0.0005', '14mARZ8YQpHdKXB...', 'aaaa', 'bbbb') #2 D:\xampp\htdocs\bitcoind2\BitcoinTest.php(279): Bitcoin->sendtoaddress('0.0005', '14mARZ8YQpHdKXB...', 'aaaa', 'bbbb') #3 D:\xampp\htdocs\bitcoind2\test.php(7): BitcoinTest->testSendtoaddress('0.0005', '14mARZ8YQpHdKXB...', 'aaaa', 'bbbb') #4 {main} thrown in D:\xampp\htdocs\bitcoind2\JsonRPCClient.php on line 149


I read some article over internet, maybe i have to unlock my bitcoind wallet before i would like to use sendtoaddress() ???



Title: Re: Bitcoind sendtoaddress dosen't work
Post by: erono on May 05, 2014, 08:59:29 AM
Hello everyone.

i have bitcoind installed on VPS debian server.
My site communicate with bitcoind via PHP RPC-JSON, it works great, i can check getinfo(), receving amount etc.
I would like to send coins to my blockchain wallet, but when i tried to call $bitcoind->sendtoaddress(amount,address,comment1,commen2), i got an 500 internal error.


Code:
Warning: fopen(http://...@127.0.0.1:8332/): failed to open stream: HTTP request failed! HTTP/1.1 500 Internal Server Error in D:\xampp\htdocs\bitcoind2\JsonRPCClient.php on line 141

Fatal error: Uncaught exception 'Exception' with message 'Unable to connect to http://myuser:mypwd@127.0.0.1:8332/' in D:\xampp\htdocs\bitcoind2\JsonRPCClient.php:149 Stack trace: #0 D:\xampp\htdocs\bitcoind2\Bitcoin.php(719): JsonRPCClient->__call('sendtoaddress', Array) #1 D:\xampp\htdocs\bitcoind2\Bitcoin.php(719): JsonRPCClient->sendtoaddress('0.0005', '14mARZ8YQpHdKXB...', 'aaaa', 'bbbb') #2 D:\xampp\htdocs\bitcoind2\BitcoinTest.php(279): Bitcoin->sendtoaddress('0.0005', '14mARZ8YQpHdKXB...', 'aaaa', 'bbbb') #3 D:\xampp\htdocs\bitcoind2\test.php(7): BitcoinTest->testSendtoaddress('0.0005', '14mARZ8YQpHdKXB...', 'aaaa', 'bbbb') #4 {main} thrown in D:\xampp\htdocs\bitcoind2\JsonRPCClient.php on line 149


I read some article over internet, maybe i have to unlock my bitcoind wallet before i would like to use sendtoaddress() ???


What is your Bitcoin-Qt / bitcoind released version?



Title: Re: Bitcoind sendtoaddress dosen't work
Post by: Ervin on May 05, 2014, 09:04:50 AM
Code:
    "version" : 90100,
    "protocolversion" : 70002,
    "walletversion" : 60000,
    "balance" : 0.00010000,
    "blocks" : 299187,
    "timeoffset" : 22,
    "connections" : 67,
    "proxy" : "",
    "difficulty" : 8000872135.96816349,
    "testnet" : false,
    "keypoololdest" : 1398316545,
    "keypoolsize" : 101,
    "paytxfee" : 0.00000000,
    "errors" : ""


Title: Re: Bitcoind sendtoaddress dosen't work
Post by: erono on May 05, 2014, 09:50:06 AM
Are you using version 0.9.0.1?

I am using version 0.9.0.1 as well but it crashes way too often for my taste.





Title: Re: Bitcoind sendtoaddress dosen't work
Post by: Ervin on May 05, 2014, 10:25:48 AM
yes