Author

Topic: Error opening block database (Read 217 times)

newbie
Activity: 3
Merit: 8
March 07, 2022, 01:23:45 PM
#9
@DeltalBravoZulu if you installed the Bitcoin Core application with the default way, using below command should do it.

Code:
/Applications/Bitcoin-Qt.app/Contents/MacOS/Bitcoin-Qt --reindex



Cheers, this has done the trick. Bitcoin Core has loaded & the blockchain is now downloading. Thanks everyone for your input.

legendary
Activity: 2534
Merit: 6080
Self-proclaimed Genius
March 07, 2022, 05:28:57 AM
#8
My issue is that Bitcoin Core doesn't open at all & shuts down when it says it needs to reindex
Fortunaltely I don't have a Space nor Bandwidth/Speed issues...
You can open bitcoin core if you set prune=550 (value depending on the previous setting) in your bitcoin.conf file because your current blockchain is pruned.
But that's not what you need to do to solve the main issue, it's to reindex.

If --reindex isn't convenient for you, you can just delete or rename the "blocks" and "chainstate" folders from your bitcoin data directory.
That will reset your blockchain and Bitcoin Core will redo the initial block download.
legendary
Activity: 1932
Merit: 1273
March 07, 2022, 03:41:02 AM
#7
@DeltalBravoZulu if you installed the Bitcoin Core application with the default way, using below command should do it.

Code:
/Applications/Bitcoin-Qt.app/Contents/MacOS/Bitcoin-Qt --reindex
legendary
Activity: 1512
Merit: 7340
Farewell, Leo
March 05, 2022, 03:26:37 PM
#6
As one who doesn't code I don't know how to use the -reindex command...
You need to execute the Bitcoin daemon with a --reindex in front of it. I neither know anything about MacOS, but according to stackexchange.com, you can achieve it this way:
Code:
open Bitcoin-Qt.app --reindex

Your error occurs when there's something wrong with the database or with the data directory. Could you check if the Bitcoin data folders are read-only? According to bitcoin wiki, that should be in:
Code:
~/Library/Application Support/Bitcoin/
newbie
Activity: 3
Merit: 8
March 05, 2022, 09:28:42 AM
#5
Quote
You need to rebuild the database using -reindex to go back to unpruned mode.  This will redownload the entire blockchain.

To use the node without pruning you need to reindex your node. Is there a reason you need to use bitcoin core without being pruned though, bisq has its own built in wallets?

If you do, you'll have to start bitcoin core with the -reindex command (im not too familiar with macos but if you can run things from the console just run it with - reindex after it and it should reindex - the download might take a long time though and bitcoin's blockchain is over 200gb now (check you have the space first).

Thanks for taking the time to reply. As one who doesn't code I don't know how to use the -reindex command...
I assume that I open Terminal (MacOS), however what command line needs to be ahead of this -reindex command?
I've tried "dBs-MacBook-Pro:~ db$ /Volumes/Extreme\ Pro/Bitcoin/bitcoin.conf -reindex" but nothing seems to happen. Huh

My issue is that Bitcoin Core doesn't open at all & shuts down when it says it needs to reindex
Fortunaltely I don't have a Space nor Bandwidth/Speed issues...

Cheers
legendary
Activity: 2870
Merit: 7490
Crypto Swap Exchange
March 03, 2022, 06:45:13 AM
#4
Description of Problem:
I downloaded BISQ and in order to use my node I had to switch to unpruned mode. This required me to redownload the blockchain. However on reloading Bitcoin Core I get Error opening block database. Please advise what steps I need to take.

Do you plan to run your own unpruned Bitcoin full node because you have very serious privacy concern? If no, just let Bisq connect to nodes run by trusted Bisq contributors (which is the default behavior)[1]. Bisq use Tor by default anyway[2]. But if you do, follow @jackg suggestion and prepare lots of free storage space. I would recommend at least 600GB free since Bitcoin blockchain size growing rather fast.

[1] https://bisq.wiki/Connecting_to_your_own_Bitcoin_node#Connecting_to_another_Bitcoin_node
[2] https://bisq.wiki/Introduction#How_Bisq_keeps_data_private
legendary
Activity: 952
Merit: 1385
March 03, 2022, 02:54:20 AM
#3
bitcoin's blockchain is over 200gb now (check you have the space first).

It is around 416GB, +indexes +chainstate = around 460GB in total.
copper member
Activity: 2856
Merit: 3071
https://bit.ly/387FXHi lightning theory
March 02, 2022, 10:37:32 AM
#2
Quote
You need to rebuild the database using -reindex to go back to unpruned mode.  This will redownload the entire blockchain.

To use the node without pruning you need to reindex your node. Is there a reason you need to use bitcoin core without being pruned though, bisq has its own built in wallets?

If you do, you'll have to start bitcoin core with the -reindex command (im not too familiar with macos but if you can run things from the console just run it with - reindex after it and it should reindex - the download might take a long time though and bitcoin's blockchain is over 200gb now (check you have the space first).
newbie
Activity: 3
Merit: 8
March 02, 2022, 10:30:40 AM
#1
Bitcoin Client Software and Version Number: V22.0.0

Operating System:
macOS Monterey V12.2.1

System Hardware Specs:
Model Name:   MacBook Pro
  Model Identifier:   MacBookPro15,2
  Processor Name:   Quad-Core Intel Core i5
  Processor Speed:   2.3 GHz
  Number of Processors:   1
  Total Number of Cores:   4
  L2 Cache (per Core):   256 KB
  L3 Cache:   6 MB
  Hyper-Threading Technology:   Enabled
  Memory:   8 GB
  System Firmware Version:   1715.81.2.0.0 (iBridge: 19.16.10744.0.0,0)
  OS Loader Version:   540.80.2~11
  Serial Number (system):   C02YJ09PJHC8
  Hardware UUID:   C4D547D5-BB7C-56EF-89D4-AE3985C0619F
  Provisioning UDID:   C4D547D5-BB7C-56EF-89D4-AE3985C0619F
  Activation Lock Status:   Enabled

Description of Problem:
I downloaded BISQ and in order to use my node I had to switch to unpruned mode. This required me to redownload the blockchain. However on reloading Bitcoin Core I get Error opening block database. Please advise what steps I need to take.

Any Related Addresses: NA

Any Related Transaction IDs: NA

Screenshot of the problem:

Log Files from the Bitcoin Client:
2022-03-02T15:20:30Z Bitcoin Core version v22.0.0 (release build)
2022-03-02T15:20:30Z Qt 5.12.11 (static), plugin=cocoa (static)
2022-03-02T15:20:30Z Static plugins:
2022-03-02T15:20:30Z  QCocoaIntegrationPlugin, version 330752
2022-03-02T15:20:30Z  QMacStylePlugin, version 330752
2022-03-02T15:20:30Z Style: macintosh / QMacStyle
2022-03-02T15:20:30Z System: macOS 10.16, x86_64-little_endian-lp64
2022-03-02T15:20:30Z Screen: Colour LCD 1440x900, pixel ratio=2.0
2022-03-02T15:20:31Z GUI: QFSFileEngine::open: No file name specified
2022-03-02T15:20:31Z GUI: QFSFileEngine::open: No file name specified
2022-03-02T15:20:31Z GUI: QFSFileEngine::open: No file name specified
2022-03-02T15:20:31Z GUI: QFSFileEngine::open: No file name specified
2022-03-02T15:20:31Z GUI: QFSFileEngine::open: No file name specified
2022-03-02T15:20:31Z Assuming ancestors of block 00000000000000000008a89e854d57e5667df88f1cdef6fde2fbca1de5b639ad have valid signatures.
2022-03-02T15:20:31Z Setting nMinimumChainWork=00000000000000000000000000000000000000001fa4663bbbe19f82de910280
2022-03-02T15:20:31Z Using the 'sse4(1way),sse41(4way),avx2(8way)' SHA256 implementation
2022-03-02T15:20:31Z Using RdSeed as additional entropy source
2022-03-02T15:20:31Z Using RdRand as an additional entropy source
2022-03-02T15:20:31Z Default data directory /Users/db/Library/Application Support/Bitcoin
2022-03-02T15:20:31Z Using data directory /Volumes/Extreme Pro/Bitcoin
2022-03-02T15:20:31Z Config file: /Volumes/Extreme Pro/Bitcoin/bitcoin.conf
2022-03-02T15:20:31Z Setting file arg: wallet = ["BTC Core #1"]
2022-03-02T15:20:31Z Using at most 125 automatic connections (2560 file descriptors available)
2022-03-02T15:20:31Z Using 16 MiB out of 32/2 requested for signature cache, able to store 524288 elements
2022-03-02T15:20:31Z Using 16 MiB out of 32/2 requested for script execution cache, able to store 524288 elements
2022-03-02T15:20:31Z Script verification uses 7 additional threads
2022-03-02T15:20:31Z scheduler thread start
2022-03-02T15:20:31Z Using wallet directory /Volumes/Extreme Pro/Bitcoin
2022-03-02T15:20:31Z init message: Verifying wallet(s)…
2022-03-02T15:20:31Z Using BerkeleyDB version Berkeley DB 4.8.30: (April  9, 2010)
2022-03-02T15:20:31Z Using wallet /Volumes/Extreme Pro/Bitcoin/BTC Core #1/wallet.dat
2022-03-02T15:20:31Z BerkeleyEnvironment::Open: LogDir=/Volumes/Extreme Pro/Bitcoin/BTC Core #1/database ErrorFile=/Volumes/Extreme Pro/Bitcoin/BTC Core #1/db.log
2022-03-02T15:20:31Z init message: Loading banlist…
2022-03-02T15:20:31Z SetNetworkActive: true
2022-03-02T15:20:31Z Using /16 prefix for IP bucketing
2022-03-02T15:20:31Z Cache configuration:
2022-03-02T15:20:31Z * Using 2.0 MiB for block index database
2022-03-02T15:20:31Z * Using 8.0 MiB for chain state database
2022-03-02T15:20:31Z * Using 440.0 MiB for in-memory UTXO set (plus up to 286.1 MiB of unused mempool space)
2022-03-02T15:20:31Z init message: Loading block index…
2022-03-02T15:20:31Z Switching active chainstate to Chainstate [ibd] @ height -1 (null)
2022-03-02T15:20:31Z Opening LevelDB in /Volumes/Extreme Pro/Bitcoin/blocks/index
2022-03-02T15:20:31Z Opened LevelDB successfully
2022-03-02T15:20:31Z Using obfuscation key for /Volumes/Extreme Pro/Bitcoin/blocks/index: 0000000000000000
2022-03-02T15:20:34Z LoadBlockIndexDB: last block file = 2943
2022-03-02T15:20:34Z LoadBlockIndexDB: last block file info: CBlockFileInfo(blocks=78, size=118703243, heights=725522...725599, time=2022-03-02...2022-03-02)
2022-03-02T15:20:34Z Checking all blk files are present...
2022-03-02T15:20:34Z LoadBlockIndexDB(): Block files have previously been pruned
2022-03-02T15:20:34Z : You need to rebuild the database using -reindex to go back to unpruned mode.  This will redownload the entire blockchain.
Please restart with -reindex or -reindex-chainstate to recover.
2022-03-02T15:20:37Z init message: Loading block index…
2022-03-02T15:20:37Z should not be overwriting a chainstate
2022-03-02T15:20:37Z Error: Error opening block database
2022-03-02T15:20:38Z Shutdown: In progress...
2022-03-02T15:20:38Z scheduler thread exit
2022-03-02T15:20:38Z Shutdown: done

Jump to: