Bitcoin Forum
October 18, 2017, 08:06:22 AM *
News: Latest stable version of Bitcoin Core: 0.15.0.1  [Torrent]. (New!)
 
   Home   Help Search Donate Login Register  
Pages: [1]
  Print  
Author Topic: How to allow the Bitcoind Server to listen to Port 8332 ?  (Read 346 times)
chegmarco
Jr. Member
*
Offline Offline

Activity: 47


View Profile
May 04, 2017, 11:53:10 AM
 #1

How do I make the Bitcoind server listen to or link to the 8332 port of my Linux distribution via "netstat"? Because I noticed that this is because the Bitcoin does not listen to 8332 as I get the error below:

Quote
Warning: fopen(http://...@127.0.0.1:8332/): failed to open stream: HTTP request failed! HTTP/1.0 401 Unauthorized in /home/cheg/Downloads/piwallet/jsonRPCClient.php on line 133

Fatal error: Uncaught exception 'Exception' with message 'Unable to connect to http://cheg:chego1@127.0.0.1:8332/' in /home/cheg/Downloads/piwallet/jsonRPCClient.php:141 Stack trace: #0 /home/cheg/Downloads/piwallet/classes/Client.php(17): jsonRPCClient->__call('getbalance', Array) #1 /home/cheg/Downloads/piwallet/classes/Client.php(17): jsonRPCClient->getbalance('zelles(chegadmi...', 6) #2 /home/cheg/Downloads/piwallet/index.php(22): Client->getBalance('chegadmin') #3 {main} thrown in /home/cheg/Downloads/piwallet/jsonRPCClient.php on line 141

So help me link the "Bitcoind" to 8332 with Netstat please.
1508313982
Hero Member
*
Offline Offline

Posts: 1508313982

View Profile Personal Message (Offline)

Ignore
1508313982
Reply with quote  #2

1508313982
Report to moderator
1508313982
Hero Member
*
Offline Offline

Posts: 1508313982

View Profile Personal Message (Offline)

Ignore
1508313982
Reply with quote  #2

1508313982
Report to moderator
1508313982
Hero Member
*
Offline Offline

Posts: 1508313982

View Profile Personal Message (Offline)

Ignore
1508313982
Reply with quote  #2

1508313982
Report to moderator
Advertised sites are not endorsed by the Bitcoin Forum. They may be unsafe, untrustworthy, or illegal in your jurisdiction. Advertise here.
bitfawkes
Full Member
***
Offline Offline

Activity: 168

Would you be willing to buy a sealed bonnet car?


View Profile
May 04, 2017, 04:02:34 PM
 #2

How do I make the Bitcoind server listen to or link to the 8332 port of my Linux distribution via "netstat"? Because I noticed that this is because the Bitcoin does not listen to 8332 as I get the error below:

Quote
Warning: fopen(http://...@127.0.0.1:8332/): failed to open stream: HTTP request failed! HTTP/1.0 401 Unauthorized in /home/cheg/Downloads/piwallet/jsonRPCClient.php on line 133

Fatal error: Uncaught exception 'Exception' with message 'Unable to connect to http://cheg:chego1@127.0.0.1:8332/' in /home/cheg/Downloads/piwallet/jsonRPCClient.php:141 Stack trace: #0 /home/cheg/Downloads/piwallet/classes/Client.php(17): jsonRPCClient->__call('getbalance', Array) #1 /home/cheg/Downloads/piwallet/classes/Client.php(17): jsonRPCClient->getbalance('zelles(chegadmi...', 6) #2 /home/cheg/Downloads/piwallet/index.php(22): Client->getBalance('chegadmin') #3 {main} thrown in /home/cheg/Downloads/piwallet/jsonRPCClient.php on line 141

So help me link the "Bitcoind" to 8332 with Netstat please.
I'm not sure to full understand your problem but if you put this row of code in /home/user/.bitcoin/bitcoin.conf it should works as you want

Code:
rpcport=8332
daemon=1

goditela Wink

Sometimes people who no one imagined could do certain things, those who do things that no one can imagine.
chegmarco
Jr. Member
*
Offline Offline

Activity: 47


View Profile
May 04, 2017, 04:40:58 PM
 #3

How do I make the Bitcoind server listen to or link to the 8332 port of my Linux distribution via "netstat"? Because I noticed that this is because the Bitcoin does not listen to 8332 as I get the error below:

Quote
Warning: fopen(http://...@127.0.0.1:8332/): failed to open stream: HTTP request failed! HTTP/1.0 401 Unauthorized in /home/cheg/Downloads/piwallet/jsonRPCClient.php on line 133

Fatal error: Uncaught exception 'Exception' with message 'Unable to connect to http://cheg:chego1@127.0.0.1:8332/' in /home/cheg/Downloads/piwallet/jsonRPCClient.php:141 Stack trace: #0 /home/cheg/Downloads/piwallet/classes/Client.php(17): jsonRPCClient->__call('getbalance', Array) #1 /home/cheg/Downloads/piwallet/classes/Client.php(17): jsonRPCClient->getbalance('zelles(chegadmi...', 6) #2 /home/cheg/Downloads/piwallet/index.php(22): Client->getBalance('chegadmin') #3 {main} thrown in /home/cheg/Downloads/piwallet/jsonRPCClient.php on line 141

So help me link the "Bitcoind" to 8332 with Netstat please.
I'm not sure to full understand your problem but if you put this row of code in /home/user/.bitcoin/bitcoin.conf it should works as you want

Code:
rpcport=8332
daemon=1

goditela Wink

Thanks for your answer but I would like to know if you tried with rpcport=8332 ? And it worked ?
achow101
Moderator
Legendary
*
Offline Offline

Activity: 1190


17kKQppUsngUiByDsce4JXoZEjjpvX9bpR


View Profile WWW
May 04, 2017, 05:15:42 PM
 #4

The fact that you are getting an HTTP 401 error from connecting to port 8332 means that something (probably bitcoind) is listening on that port and can understand http. Thus bitcoind the issue is likely not related to bitcoind not connecting to the port but rather that you have configured it incorrectly.

You will get a HTTP 401 Unauthorized error if you do not have the "authorization" header or if the username/password in your auth header is incorrect. For the latter case, if you look in the debug.log file for Bitcoin Core, you will see a line like this:
Code:
ThreadRPCServer incorrect password attempt from 127.0.0.1
for each attempt at connecting.

Make sure that you are actually sending the username and password correctly and that what you set as username and password is the same thing as you have set in your bitcoin.conf file.

          ▄█████▄
        ▄█████████▄
      ▄████▀   ▀████▄
    ▄████▀   ▄ ▄█▀████▄
  ▄████▀   ▄███▀   ▀████▄
▄████▀   ▄███▀   ▄   ▀████▄
█████   ███▀   ▄███   █████
▀████▄   ▀██▄▄███▀   ▄████▀
  ▀████▄   ▀███▀   ▄████▀
    ▀████▄       ▄████▀
      ▀████▄   ▄████▀
        ▀███  ████▀
          ▀█▄███▀
.
|
.
|
          ▄█████▄
        ▄█████████▄
      ▄████▀   ▀████▄
    ▄████▀   ▄ ▄█▀████▄
  ▄████▀   ▄███▀   ▀████▄
▄████▀   ▄███▀   ▄   ▀████▄
█████   ███▀   ▄███   █████
▀████▄   ▀██▄▄███▀   ▄████▀
  ▀████▄   ▀███▀   ▄████▀
    ▀████▄       ▄████▀
      ▀████▄   ▄████▀
        ▀███  ████▀
          ▀█▄███▀
unthy
Pages: [1]
  Print  
 
Jump to:  

Sponsored by , a Bitcoin-accepting VPN.
Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!