Bitcoin Forum
November 06, 2024, 11:28:16 PM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Can a node import mempool RPC if IBD was not completed?  (Read 126 times)
ParaBoi (OP)
Newbie
*
Offline Offline

Activity: 14
Merit: 4


View Profile
September 03, 2023, 10:14:21 AM
 #1

I read more about mempool during my recent investigation, however I ultimately opted to conduct an experiment using the mainnet mempool. Unfortunately, the node must complete IBD (initial block download) up to the most recent chaintip before it can fill your mempool. But my main concern right now is whether or not my experiment will succeed. If so, how can I obtain some answers? I know it will be very difficult based on my prior experience, but I'm wondering whether there's a method to use the importmempool RPC (remote procedure call), which acts as an interface with a blockchain.
LoyceV
Legendary
*
Offline Offline

Activity: 3486
Merit: 17637


Thick-Skinned Gang Leader and Golden Feather 2021


View Profile WWW
September 03, 2023, 11:24:00 AM
 #2

I'm wondering whether there's a method to use the importmempool RPC (remote procedure call), which acts as an interface with a blockchain.
What are you trying to accomplish? You can't verify anything in an imported mempool without an up-to-date blockchain. I think you're going to have to wait for Bitcoin Core to complete syncing.

▄▄███████████████████▄▄
▄█████████▀█████████████▄
███████████▄▐▀▄██████████
███████▀▀███████▀▀███████
██████▀███▄▄████████████
█████████▐█████████▐█████
█████████▐█████████▐█████
██████████▀███▀███▄██████
████████████████▄▄███████
███████████▄▄▄███████████
█████████████████████████
▀█████▄▄████████████████▀
▀▀███████████████████▀▀
Peach
BTC bitcoin
Buy and Sell
Bitcoin P2P
.
.
▄▄███████▄▄
▄████████
██████▄
▄██
█████████████████▄
▄███████
██████████████▄
███████████████████████
█████████████████████████
████████████████████████
█████████████████████████
▀███████████████████████▀
▀█████████████████████▀
▀██████████████████▀
▀███████████████▀
▀▀███████▀▀

▀▀▀▀███▀▀▀▀
EUROPE | AFRICA
LATIN AMERICA
▄▀▀▀











▀▄▄▄


███████▄█
███████▀
██▄▄▄▄▄░▄▄▄▄▄
████████████▀
▐███████████▌
▐███████████▌
████████████▄
██████████████
███▀███▀▀███▀
.
Download on the
App Store
▀▀▀▄











▄▄▄▀
▄▀▀▀











▀▄▄▄


▄██▄
██████▄
█████████▄
████████████▄
███████████████
████████████▀
█████████▀
██████▀
▀██▀
.
GET IT ON
Google Play
▀▀▀▄











▄▄▄▀
DaveF
Legendary
*
Offline Offline

Activity: 3654
Merit: 6660


Crypto Swap Exchange


View Profile WWW
September 03, 2023, 12:11:53 PM
Merited by vapourminer (1)
 #3

I read more about mempool during my recent investigation, however I ultimately opted to conduct an experiment using the mainnet mempool. Unfortunately, the node must complete IBD (initial block download) up to the most recent chaintip before it can fill your mempool. But my main concern right now is whether or not my experiment will succeed. If so, how can I obtain some answers? I know it will be very difficult based on my prior experience, but I'm wondering whether there's a method to use the importmempool RPC (remote procedure call), which acts as an interface with a blockchain.

If it's just for experiment sake, use Testnet or Signet instead. I just checked my node and found out testnet blockchain has size ~30.9GB, while Signet blockchain has size ~830MB. If it's still too much, i guess you should write script which connect to someone's else full node and ask for transaction on it's mempool.

Never checked, but don't some of the block explorers have API calls for this?

The issue is going to be with the mempool being well over 900MB that a lot of places / nodes are going to be dropping different transactions depending on their settings. I they have the default 300MB you may get a different answer then if they have it set to 512MB and that may be different then 1024MB.

So unless you know what they are doing querying one will only get what they have in theirs.

-Dave

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
nc50lc
Legendary
*
Offline Offline

Activity: 2590
Merit: 6343


Self-proclaimed Genius


View Profile
September 03, 2023, 01:28:04 PM
 #4

-snip-
but I'm wondering whether there's a method to use the importmempool RPC (remote procedure call), which acts as an interface with a blockchain.
I'm not aware of any "importmempool" command in Bitcoin Core, perhaps you're looking at some other Bitcoin node implementation?

If so, please specify;
While you're at it, please provide more information about your "experiment" so that users can give you more fitting answers.

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
BlackHatCoiner
Legendary
*
Offline Offline

Activity: 1694
Merit: 8324


Bitcoin is a royal fork


View Profile WWW
September 03, 2023, 02:24:50 PM
Merited by ABCbits (1), nc50lc (1)
 #5

Normally, your node won't download any unconfirmed transactions until reaching the chain tip, as it can't verify the validity of those transactions. If you want to know the current mempool of a random node, then just trust a block explorer?

I'm not aware of any "importmempool" command in Bitcoin Core, perhaps you're looking at some other Bitcoin node implementation?
It has been requested, as you can see in this Bitcoin Core PR review, but it does a different thing; it loads transactions into your node's mempool given a mempool.dat.

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
nc50lc
Legendary
*
Offline Offline

Activity: 2590
Merit: 6343


Self-proclaimed Genius


View Profile
September 04, 2023, 04:34:06 AM
 #6

It has been requested, as you can see in this Bitcoin Core PR review, but it does a different thing; it loads transactions into your node's mempool given a mempool.dat.
Thanks, I see that it's just merged 3 weeks ago which will be included in the next release.
I'm surprised that OP is using the dev build.

█▀▀▀











█▄▄▄
▀▀▀▀▀▀▀▀▀▀▀
e
▄▄▄▄▄▄▄▄▄▄▄
█████████████
████████████▄███
██▐███████▄█████▀
█████████▄████▀
███▐████▄███▀
████▐██████▀
█████▀█████
███████████▄
████████████▄
██▄█████▀█████▄
▄█████████▀█████▀
███████████▀██▀
████▀█████████
▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀▀
c.h.
▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄▄
▀▀▀█











▄▄▄█
▄██████▄▄▄
█████████████▄▄
███████████████
███████████████
███████████████
███████████████
███░░█████████
███▌▐█████████
█████████████
███████████▀
██████████▀
████████▀
▀██▀▀
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!