RPC command sendfrom is giving Transaction too large error

0

I made discord bot for fun with tips, soak and rains of altcoin. When I try to send large amount through the same bot. It is giving me "Transaction too large" error. I found the reason here: transaction creation failed

I need help with solving this issue. Can someone help me?

Thanks in advance

Madhu Crypto

Posted 2018-09-26T21:15:08.127

Reputation: 23

Answers

0

Transaction too large

This is referring to the transaction size in bytes, not Bitcoin.

You need to send the Bitcoin in smaller chunks to yourself, or sweep the dust, as they say. This is because a transaction is made up of unspent outputs (UTXO) and since you are sending a large amount, you will likely have many small UTXO from all of the tips you're trying to spend. This increases the size of the transaction in bytes.

Bitcoin core will return that error if the transaction weight is greater than MAX_STANDARD_TX_WEIGHT, which as of v0.16.3 is 400,000, which also happens to be the maximum size of 1 block.

What is tx weight?

Transaction weight is defined as Base transaction size * 3 + Total transaction size (ie. the same method as calculating Block weight from Base size and Total size).

Virtual transaction size is defined as Transaction weight / 4 (rounded up to the next integer).

Base transaction size is the size of the transaction serialised with the witness data stripped.

Total transaction size is the transaction size in bytes serialized as described in BIP144, including base data and witness data. See BIP 141

JBaczuk

Posted 2018-09-26T21:15:08.127

Reputation: 6 172

Thank you JBaczuk, What is the solution? Should I stop sending small amounts as tips?Madhu Crypto 2018-09-27T13:15:47.517

Or you can sweep the dust so your inputs aren't so small before you send a larger tx. Are you receiving small tips on the address you're trying to send from?JBaczuk 2018-09-27T13:23:45.340

Yes, I am getting small tips... how can I sweep all dust? Do I need to install new wallet or any other way?Madhu Crypto 2018-09-29T02:11:38.540

Just send some back to yourselfJBaczuk 2018-09-29T04:06:06.130

Can I use move instead of sendFrom for the transaction of small tips? Will move create dust and block me from large amount tx?Madhu Crypto 2018-09-29T13:52:39.370

move is a deprecated account feature, which is being removed in v0.18.0 and is confusing. It will not solve the problem of trying to spend many small outputs since it doesn't create any transactions. You really need to make a few transactions to yourself to consolidate the many utxo from all the tips.JBaczuk 2018-09-29T13:54:36.823