Skip to main content
Share Your Experience: Take the 2024 Developer Survey

Questions tagged [block]

The components of the blockchain and a data structure that collects transactions.

48 questions with no upvoted or accepted answers
Filter by
Sorted by
Tagged with
2 votes
0 answers
44 views

Difference between pprev and pskip pointers in the CBlockIndex class?

In the Bitcoin Core there is class called CBlockIndex which as its name appears is the implementation of blocks. This class has two variable that for me they looks the same: class CBlockIndex { public:...
Amir reza Riahi's user avatar
2 votes
0 answers
56 views

Transaction validation cost

what relation is between transaction size or a number of input and validation cost? for example, It's o(n) or o(n^2)?
Maha's user avatar
  • 41
2 votes
0 answers
51 views

Is there a way to get stats about fees paid (highest, lowest, average) in a specific block?

I'd prefer to get the stats from my full node via bitcoin-cli, but if that's not possible some API would do the job too...
Joe's user avatar
  • 21
2 votes
1 answer
208 views

Different balances in API block explorers for BTC

BTC.com block explorer shows bigger balance than for example Insight or Blockchair. For example: https://btc.com/1FLDCfr9iG7n6bAdGsqBXmhaLgC4aSze72 https://insight.bitpay.com/address/...
wallebach's user avatar
2 votes
0 answers
109 views

The blockchain lookup speed in a local machine

How to determine the exact required time (seconds, milliseconds) to find a particular block when searching within a local blockchain using address? Is there any way to make a benchmark to study the ...
Noureddine's user avatar
2 votes
0 answers
89 views

Source for accurate block timestamps?

Is there a source of historical data which assigns a relatively consistent and accurate timestamp to each block? This might take the form of a server having precisely logged when they first heard ...
Arthur B's user avatar
  • 121
2 votes
0 answers
68 views

Which function is called to mine a block, broadcast the newly mined block & receive a newly mined block?

I am trying to understand the control flow and handling of transactions in the memory pool.
somesh's user avatar
  • 457
2 votes
0 answers
664 views

How to determine how many coins have been mined regardless of block count in main.cpp

Been working my way trough the main.cpp trying to see where this value is grabbed if at all. I need a way to check how many coins have been mined regardless of block count. For example if every ...
user12970's user avatar
1 vote
0 answers
30 views

Should I stop bitcoind when backing up chainstate/ and blocks/ directories?

This is how one might back up their Bitcoin Core data directories in order to save time on syncing in the future: #!/usr/bin/bash local_d=/root/btc_db rsync -av --delete chainstate "$local_d&...
John Smith's user avatar
1 vote
0 answers
50 views

How can I collate blocks in blk*.dat files and rev*.dat files?

According to this answer, blocks in blk*.dat files and rev*.dat files don't necessarily appear in the same order, nor are either files necessarily in monotonic order, and blocks not part of the active ...
Vojtěch Strnad's user avatar
1 vote
1 answer
73 views

Wrong hashes for blocks when parsing from blk

Hello I'm using a python script to actually retrieve information from a blk file and to read data. import datetime # Read block ! file = open("REDACTED\blocks\\blk00000.dat", 'rb') ...
LuckyAutomata's user avatar
1 vote
0 answers
51 views

Pseudocode for Bitcoin's P2P block propagation

I am going through Bitcoin's block propagation method at https://developer.bitcoin.org/devguide/p2p_network.html Are you aware of any pseudocode available on how blocks are propagated during the ...
satya's user avatar
  • 171
1 vote
0 answers
65 views

DB Structure for bitcoin blocks

https://github.com/blockchain-etl/bitcoin-etl#schema I found a library to parse the block data in json format. I want to parse that json and put it into a db to then use that for calculating balances. ...
UnknownHex64's user avatar
1 vote
0 answers
684 views

Pruning Blockstore has been running for days

After activating the core (Testnet - Pruned) with the command bitcoin-qt i received the following error: Corrupt Block Database I restarted the synchronization always using the Pruned mode. The core ...
MaXbeMan's user avatar
  • 125
1 vote
0 answers
104 views

Fork rate range in terms of network security

I am really new to bitcoin and am trying to understand the basics. Fork rate/Orphan rate is a measure of network security. The higher the fork rate, the more compromised the system. Also fork rate ...
AAKASH IYER's user avatar
1 vote
0 answers
29 views

Blockchain, correction of blocks

How do a malicious nodes correct their blockchain if they have it wrong? If they don’t want to fix it, what happens then?
Juan's user avatar
  • 96
1 vote
0 answers
411 views

Estimated number of hashes

This is not a duplicate of previous, similar questions I've read on StackExchange, since none of those questions, nor the answers, go into the difficulty theory, as espoused on the Bitcoin Wiki. ...
glowkeeper's user avatar
1 vote
0 answers
29 views

What needs to be done inorder to change difficulty?

I'm trying for a while to reduce difficulty of main network to do some experiments on transactions and maybe simulate some possible attacks.I came up to change nBits field in chainparams.cpp but it ...
chameleon123's user avatar
1 vote
0 answers
96 views

Segwit and block size limit

I'am learning about Bitcoin and I didn't understand something. Maybe someone could clarify. I [think] I understood what Segwit does (increases block size, solves malleability and works better with ...
Dany D's user avatar
  • 11
1 vote
0 answers
169 views

Bitcoin mining specification to write own mining application

Where can I find the design specifications to write my own mining application for mining bitcoin. More I read I find there are number of implementations and some pools only work with specific mining ...
nQuant's user avatar
  • 11
1 vote
0 answers
506 views

BitcoinCore walletnotify before blocknotify?

I want to use bitcoind's walletnotify and blocknotify features. The question is: Is blocknotify script always triggered after walletnotify script? Imagine, I have an unconfirmed transaction in my ...
Yevhen's user avatar
  • 173
1 vote
0 answers
72 views

Reorganize chain

BitcoinJ: Is is possible to get somehow transactions from ReorganizeListener in block chain? I'm able to get list of new blocks which are represented by StoredBlock but from StoredBlock I can't get ...
Dragomirus's user avatar
1 vote
0 answers
104 views

Why do transactions get verified before it is clear that the block header is valid?

When I researched for the answer on What happens in detail, when Bitcoin Core verifies a block during synchronization?, I noticed something: According to the Wiki-Entry on Protocol rules some of the ...
Murch's user avatar
  • 75.7k
1 vote
0 answers
968 views

(Bither) how can i send my bitcoins?

i downloaded Bither as my virtual wallet and added bitcoins in a Hot Wallet Address. But when i try to send bitcoins, i can't. i fill the address, the amount of bitcoins and i type my password but ...
grepast's user avatar
  • 11
1 vote
0 answers
170 views

How to check Bitcoind block chain download progress level without blockchain explorer?

so my problem isn't with bitcoin particularly but with a dying altcoin, I have the same problem as here. But can't use a blockchain explorer site, since there doesn't exist one. Is there any way to ...
crisader's user avatar
1 vote
0 answers
134 views

Submitted blocks get rejected on Litecoin testnet

I'm trying to submit blocks to the Litecoin Testnet, however everything gets rejected. I got my raw value as ...
Evelie's user avatar
  • 121
0 votes
0 answers
32 views

what is expectedFees and expectedWeight in a block and why its changing frequently?

what is expectedFees and expectedWeight in a block and why its changing frequently ? https://mempool.space/api/v1/block/00000000000000000001c680ee86b8eaa43c94ac9012f4d2dcbfa9f45beadf06 when i last ...
N.dhanush raj's user avatar
0 votes
0 answers
40 views

High end electrum servers directly reading blk.dat files

These days, high end electrum servers directly read blk.dat files straight from Bitcoin Core's blocks folder in the process of creating their initial internal indexes. I guess they also do in the ...
RooSoft's user avatar
  • 157
0 votes
0 answers
30 views

NodeJS code to deobfuscate chainstate data

I am currently working on a Blockchain trading platform for a company and I want to have all the unspent output saved to a local database by reading the contents of chainstate folder but I couldn't ...
Topman's user avatar
  • 11
0 votes
0 answers
36 views

How to display {block number} instead {date value} on Wordpress posts?

Ideally, the goal is to show the block number (ie: 782667) instead of the date value (ie: 26 March 2023 4:44PM CT) on all wordpress posts and pages that currently display it. There's maybe a script we ...
SuperAtic's user avatar
  • 131
0 votes
0 answers
192 views

How do I run the invalidateblock command on bitcoind?

For a particular need I need to restart with the chain from a specific previous block. I thought about using the invalidateblock command, but it's a bitcoin-cli command and if I run it on bitcoind it ...
Minatorecoin's user avatar
0 votes
0 answers
40 views

use java to scan all the block

I am trying to scan all the bitcoin data on my workstation with java to get some high level statistic data. I parsed all the transactions with bitcoinJ, but I encountered a problem, the Transaction ...
Carpemer's user avatar
  • 301
0 votes
0 answers
53 views

Start mining without the need to downlod the 360gb blockchain

I am new to bitcoin mining but at least i understand the mathematics behind - the sha256 and finding nonce, i am a junior back-end developer. recently i have being interested in bitcoin mining, as way ...
D. Sikilai's user avatar
0 votes
1 answer
869 views

Struggling to Decode Raw Hex Data of a Block

I am trying to Decode the Raw hex data of a Coinbase Block to check my understanding of the DS but I am facing some difficulties in decoding marked by a ? below: Q1. Can someone please check the ...
J.Doe's user avatar
  • 127
0 votes
0 answers
42 views

Can transactions be held for a long time without being processed?

I am learning a little bit about the bitcoin technology and I have some basic questions about its p2p and transaction processing. First imagine that a bitcoin transaction has included a fee (maybe a ...
Ivan's user avatar
  • 101
0 votes
0 answers
45 views

Get/Calculate Address

I'm currently using a program that analyses the block files. It splits all the stuff into multiple .csv files. Is there any method I can do to get the addresses & amount sent/received from tx_in ...
Wheezer64_0xff's user avatar
0 votes
0 answers
107 views

What's up with the block size of block# 295182?

I found an anomaly in the block size data: block 295182. This one seems to have a way higher payload. What happened there? Or is this there something wrong with my parsing? This file block does ...
Bitcoingraffiti's user avatar
0 votes
0 answers
243 views

Upgrading - OLD PC - Wallet v0.8.1-beta and qt v4.8.3

Can you advise me on upgrading my wallet and bitcoin software. Are there files I should save before upgrading? what should I upgrade to? Other basic questions. I have a number of bitcoin files in my ...
OLDPC's user avatar
  • 1
0 votes
0 answers
120 views

What does the version number in the blockheader represent

While looking up how a block get mined I stumbled over the version number in the header - which is used to "keep track of changes to the protocol". But even in the last 5 blocks of the chain (at the ...
Dalian's user avatar
  • 1
0 votes
0 answers
541 views

lnd service fails frequently

I have bitcoind and lnd set up on my Raspberry Pi according to the guide here. Everything works great for the most part, and my node is up and running. I've been able to open a channel with another ...
Donnie Thomas's user avatar
0 votes
0 answers
346 views

How generate a hex string for a block

I have written this code to create and submit a new minned block to the bitcoin network: unsigned long magic_number = 0xD9B4BEF9; unsigned long block_size = 89 + (strlen(coinbase_transaction)-1) +...
Kleber Mota's user avatar
0 votes
2 answers
135 views

What is the format of a Bitcoin block body?

To my understanding, the miners solve the nonce to get a valid block header based on the difficulty target. In the header, you have the Merkle root, which is generated from the transactions included ...
Edile's user avatar
  • 1
0 votes
1 answer
77 views

Peer-to-peer - informations about downloading

I would like to know how the software downloads the blockchain. If the bytes write throught the socket and wait until it's written. And If the software asks 16 blocks to each peer in which you're ...
Loopite's user avatar
  • 301
0 votes
1 answer
151 views

Tool to build a relational db from .dat block files

No need to elaborate too much. I'd like to build a real SQL db starting from the directory blocks. Is there any tool out there? I work on a mac and I'd prefer something cross OS if possible.
Davide C's user avatar
  • 234
-1 votes
1 answer
38 views

How to prevent nodes from creating only small blocks to earn fee?

I read What are the minimum sizes for transactions and blocks in Bitcoin? that there is no min limit - just a max limit of 128MB - for a block. For example if a miner always takes a single ...
DoJo's user avatar
  • 1
-1 votes
1 answer
28 views

Pertaining to slushpool mining . What is the most lucrative way to vote ? Or does it matter

What is the most lucrative way to vote on slushpool? Or does it matter
Greg's user avatar
  • 1
-4 votes
1 answer
68 views

decentralized cryto currency without block time

Block time or delay is often a problem in Bitcoin. Then would it be possible to develop a decentralized cryto currency with zero delay/block time? Any reference will be appreciated.
180118's user avatar
  • 101
-4 votes
1 answer
148 views

what this parameters do end what i need put on them in blockchain ver2

/** What block version to use for new blocks (pre versionbits) */ static const int32_t VERSIONBITS_LAST_OLD_BLOCK_VERSION = 4; /** What bits to set in version for versionbits blocks */ static const ...
tseries's user avatar
  • 205