Bitcoin Forum

Bitcoin => Bitcoin Technical Support => Topic started by: McMurdo on November 28, 2019, 07:26:31 PM



Title: Open Port 8333 Necessary to Broadcast Transactions?
Post by: McMurdo on November 28, 2019, 07:26:31 PM
My btc core node (pruned) can receive transactions, but not send them. I've tried to send around a 1000 sats with over 3,000 sats in fees, to the testnet faucet address

n2eMqTT929pb1RDNuqEnxdaLau1rxy3efi
 
and when I type

$ bitcoin-cli listtransactions

I can see the transaction, but it has had zero confirmations for hours, and I when I enter the txid in a testnet block explorer, there are no results.

Do I need to open port 8333 on my router (i.e., have inbound connections) to be able to broadcast transactions?

Thank you.


Title: Re: Open Port 8333 Necessary to Broadcast Transactions?
Post by: ABCbits on November 28, 2019, 07:49:10 PM
Open Port 8333 is only necessary if you plan to contribute to Bitcoin Network or actually running a full node.


Title: Re: Open Port 8333 Necessary to Broadcast Transactions?
Post by: khaled0111 on November 28, 2019, 10:42:15 PM
Open Port 8333 is only necessary if you plan to contribute to Bitcoin Network or actually running a full node.
Besides, to accept incoming connections on testnet you have to open the default port 18333 not 8333.
@OP, You don't have to enable incoming connections to be able to broadcast a transaction.


Title: Re: Open Port 8333 Necessary to Broadcast Transactions?
Post by: BitMaxz on November 28, 2019, 10:47:36 PM
Did you run the bitcoin core to testnet? the sat you are sending is mainet BTC to testnet BTC?

try to check this video on how he set up and run the testnet bitcoin core without any issue. https://www.youtube.com/watch?v=MX_DHGJxoOc


Title: Re: Open Port 8333 Necessary to Broadcast Transactions?
Post by: McMurdo on November 29, 2019, 12:01:15 AM
Open Port 8333 is only necessary if you plan to contribute to Bitcoin Network or actually running a full node.
Besides, to accept incoming connections on testnet you have to open the default port 18333 not 8333.
@OP, You don't have to enable incoming connections to be able to broadcast a transaction.

Ok, that's good to know. Any idea what would cause my node to be able to receive tesnet transactions but not be able to propagate its own?

BitMaxz: I have core configuring to run in Testnet and it shows this when I run $ bitcoin-cli printtoconsole. These are indeed tesnet coins I'm trying to send to a testnet address.


Title: Re: Open Port 8333 Necessary to Broadcast Transactions?
Post by: ranochigo on November 29, 2019, 03:27:28 AM
Ok, that's good to know. Any idea what would cause my node to be able to receive tesnet transactions but not be able to propagate its own?
The problem most likely lies with your transaction than with your client. For some reason, your transaction might be non standard and thus it doesn't propagate well within the network. If you want to eliminate this possibility, use an online transaction broadcaster with your raw transaction for testnet and try if it works.


Title: Re: Open Port 8333 Necessary to Broadcast Transactions?
Post by: McMurdo on November 29, 2019, 02:33:33 PM
Ranochigo:

Just used an online testnet transaction broadcaster with the raw data, and it has propagated successfully. Any other ideas why my node couldn't do it on it's own?

Here's another symptom: when I tried to send to testnet bech32 addresses (staring in "tb") core tells me "error code -5, invalid address." even though  I created the address with testnet mycelium on my phone and am 100% certain I entered the address correctly into core.
 


Title: Re: Open Port 8333 Necessary to Broadcast Transactions?
Post by: BitMaxz on November 29, 2019, 03:41:00 PM
BitMaxz: I have core configuring to run in Testnet and it shows this when I run $ bitcoin-cli printtoconsole. These are indeed tesnet coins I'm trying to send to a testnet address.

Where did you get the testnet address that you trying to send from your testnet wallet to that testnet address?
Did you just generate a new testnet address on the same wallet?


Ranochigo:

Just used an online testnet transaction broadcaster with the raw data, and it has propagated successfully. Any other ideas why my node couldn't do it on it's own?
 

It seems that your core is not connected to online testnet that is why you need to broadcast the raw transaction.

Take a look at this sample bitcoin.conf setup below.

Code:
testnet=1
regtest=0
dnsseed=0
upnp=0
setgenerate=1
blocksonly=1

server=1

addnode=104.237.131.138
addnode=151.80.205.132
addnode=192.155.82.123
addnode=74.220.255.190
addnode=80.100.203.151

maxconnections=15
minrelaytxfee=0.0001
maxmempool=200
maxreceiverbuffer=2500
maxsendbuffer=500
dbcache=16000

rpcallowip=0.0.0.0/0
rpcuser=someuser
rpcpassword=somepass

You might need to add some online node just like the setup above.


Title: Re: Open Port 8333 Necessary to Broadcast Transactions?
Post by: McMurdo on November 30, 2019, 06:16:33 PM
Bitmax:
1. The testnet address I've been trying to get tBTC core to send to is my tBTC mycelium app. However, I've now found that both Wasabi Wallet, and an online testnet faucet also reject the bech32 testnet address created by my phone's mycelium tBTC app. (So that's on you, Mycelium).

2. I determined that my tBTC core fails to propagate if I use
$ sendtoaddress [address] [amout of tBTC]
but, if I use:
$ sendrawtransaction [raw_transaction]
then that propagates right away.
Interestingly, the same failure to propagate occurs if I use bitcoin-qt -testnet.

Any chance this is due to my Linux firewall settings?

My bitcoin.config has already been nearly identical to what you've recommended:

testnet=1

listen=1
server=1
proxy=127.0.0.1:9050

[test]
prune = 5000
regtest=0
dnsseed=0
upnp=0
setgenerate=1
blocksonly=1

addnode=104.237.131.138
addnode=151.80.205.132
addnode=192.155.82.123
addnode=74.220.255.190
addnode=80.100.203.151

maxconnections=15
minrelaytxfee=0.0001


Title: Re: Open Port 8333 Necessary to Broadcast Transactions?
Post by: McMurdo on December 03, 2019, 02:18:44 AM
ETFbitcoin:

I am able to propagate transactions when using sendrawtransaction, it's just the command sendtoaddress and bitcoin-qt never propagate. Disabled my firewall, same result.

At least I have a work around.