Pages:
Author

Topic: "Error opening block database. Do you want to rebuild the block database now?" - page 5. (Read 47987 times)

hero member
Activity: 700
Merit: 500
I'm on a Mac, running bitcoin-qt v0.8.1-beta. I get the same error:
"Error opening block database. Do you want to rebuild the block database now?"

This is from my log file:

Quote
Bitcoin version v0.8.1-beta (2013-03-17 15:35:36 -0400)
Using OpenSSL version OpenSSL 1.0.1c 10 May 2012
Startup time: 2013-03-31 08:58:46
Default data directory /Users/max/Library/Application Support/Bitcoin
Used data directory /Users/max/Library/Application Support/Bitcoin
Using 8 threads for script verification
init message: Verifying wallet integrity...
dbenv.open LogDir=/Users/max/Library/Application Support/Bitcoin/database ErrorFile=/Users/max/Library/Application Support/Bitcoin/db.log
Bound to [::]:8333
Bound to 0.0.0.0:8333
init message: Loading block index...
Opening LevelDB in /Users/max/Library/Application Support/Bitcoin/blocks/index
Opened LevelDB successfully
Opening LevelDB in /Users/max/Library/Application Support/Bitcoin/chainstate
Opened LevelDB successfully
LoadBlockIndex(): last block file = 50
LoadBlockIndex(): last block file: CBlockFileInfo(blocks=699, size=126642116, heights=228135..228833, time=2013-03-26..2013-03-30)
LoadBlockIndex(): transaction index disabled
LoadBlockIndex(): hashBestChain=000000000000026e424ea170da0ba79e671e081b2c0ee5e389def9d8b4724a75  height=228833 date=2013-03-30 23:08:49
init message: Verifying block database integrity...
Verifying last 288 blocks at level 3
LevelDB read failure: Corruption: block checksum mismatch

The essential part seems to be this: "LevelDB read failure: Corruption: block checksum mismatch"

Anyone knows what's going on?
hero member
Activity: 900
Merit: 1014
advocate of a cryptographic attack on the globe
I ran a long SMART test which took 2+ hours. I says the drive is in perfect health. So no explanation really for the error as far as I can tell.

I think the issue wasn't on your part, instead with the recent Bitcoin 0.8.1 reference client. Developers have tweaked DB parameters in order to comply with older 0.7 client limitations and it seems like LevelDB started complaining. It only affects 0.8.0 to 0.8.1 upgrade. Solution is given by @inglian a few posts up.

Hope it helps.

Thanks, that makes sense! It works well now Smiley Something like this should be included in the release notes though. (Weird however because the issue didn't happen the first time I opened the client after the upgrade.)
legendary
Activity: 924
Merit: 1004
Firstbits: 1pirata
I ran a long SMART test which took 2+ hours. I says the drive is in perfect health. So no explanation really for the error as far as I can tell.

I think the issue wasn't on your part, instead with the recent Bitcoin 0.8.1 reference client. Developers have tweaked DB parameters in order to comply with older 0.7 client limitations and it seems like LevelDB started complaining. It only affects 0.8.0 to 0.8.1 upgrade. Solution is given by @inglian a few posts up.

Hope it helps.
hero member
Activity: 900
Merit: 1014
advocate of a cryptographic attack on the globe
I ran a long SMART test which took 2+ hours. I says the drive is in perfect health. So no explanation really for the error as far as I can tell.
hero member
Activity: 900
Merit: 1014
advocate of a cryptographic attack on the globe
Ran chkdsk /r overnight. It didn't detect any bad blocks, bad file records, or unindexed files. It did discover free space marked as allocated in the volume bitmap and it did clean up unused index entries/security descriptors.
newbie
Activity: 23
Merit: 0
Same problem, immediately upon upgrading from bitcoin-0.8.0rc1-win32 to 0.8.1, on Win7-64.

Chose Cancel. The .sst file referenced did not exist, but no problem creating the .sst file with Cygwin "touch". Deleted the .sst file I had created, restarted Bitcoin-Qt, ran fine the second time, no further mention of .sst files in the debug.log. 2-month old SATA laptop drive with no problems.

Code:
Bitcoin version v0.8.1-beta (2013-03-17 15:35:36 -0400)
Using OpenSSL version OpenSSL 1.0.1c 10 May 2012
Startup time: 2013-03-20 12:52:37
Default data directory C:\Users\username\AppData\Roaming\Bitcoin
Used data directory C:\Users\username\AppData\Local\LargeDB\Bitcoin
Using 4 threads for script verification
init message: Verifying wallet integrity...
dbenv.open LogDir=C:\Users\username\AppData\Local\LargeDB\Bitcoin\database ErrorFile=C:\Users\username\AppData\Local\LargeDB\Bitcoin\db.log
Bound to [::]:8333
Bound to 0.0.0.0:8333
init message: Loading block index...
Opening LevelDB in C:\Users\username\AppData\Local\LargeDB\Bitcoin\blocks\index
Opened LevelDB successfully
Opening LevelDB in C:\Users\username\AppData\Local\LargeDB\Bitcoin\chainstate
Opened LevelDB successfully
LoadBlockIndex(): last block file = 14
LoadBlockIndex(): last block file: CBlockFileInfo(blocks=789, size=119258104, heights=225479..226267, time=2013-03-12..2013-03-17)
LoadBlockIndex(): transaction index disabled
LoadBlockIndex(): hashBestChain=00000000000002e60135b76ddd31d727f4ca44c28f142e85ff38c199b1a098e8  height=226267 date=2013-03-17 02:17:42
init message: Verifying block database integrity...
Verifying last 288 blocks at level 3
LevelDB read failure: IO error: C:\Users\username\AppData\Local\LargeDB\Bitcoin\chainstate\013292.sst: Could not create random access file.
legendary
Activity: 924
Merit: 1004
Firstbits: 1pirata
...

Think it is worth running?

No, seems ok.


Edit: Also perhaps a checkdsk /r is in order?

Give it a go, I assumed you already tried that.

Ok thanks, will run that tonight. So it is likely to be an HD issue I guess rather than client issue as nobody has reported it?

Yes sir, working fine here on an SSD drive at breathtaking speeds  Smiley

hero member
Activity: 900
Merit: 1014
advocate of a cryptographic attack on the globe
...

Think it is worth running?

No, seems ok.


Edit: Also perhaps a checkdsk /r is in order?

Give it a go, I assumed you already tried that.

Ok thanks, will run that tonight. So it is likely to be an HD issue I guess rather than client issue as nobody has reported it?
legendary
Activity: 924
Merit: 1004
Firstbits: 1pirata
...

Think it is worth running?

No, seems ok.


Edit: Also perhaps a checkdsk /r is in order?

Give it a go, I assumed you already tried that.
hero member
Activity: 900
Merit: 1014
advocate of a cryptographic attack on the globe
How old is your HDD? You could be dealing with a faulty disk drive.

Code:
LevelDB read failure: IO error: C:\Users\User\AppData\Roaming\Bitcoin\chainstate\041412.sst: Could not create random access file.

It is about two years now. I can run some SMART tests.

Please do and report back.

=== START OF READ SMART DATA SECTION ===
SMART overall-health self-assessment test result: PASSED

I just ran a short offline which Completed without error.

None of the raw values for the monitored attributes looks odd.

I last ran the 2 hour long test 2,404 hours ago.

Think it is worth running?

Edit: Also perhaps a checkdsk /r is in order?
legendary
Activity: 924
Merit: 1004
Firstbits: 1pirata
How old is your HDD? You could be dealing with a faulty disk drive.

Code:
LevelDB read failure: IO error: C:\Users\User\AppData\Roaming\Bitcoin\chainstate\041412.sst: Could not create random access file.

It is about two years now. I can run some SMART tests.

Please do and report back.
hero member
Activity: 900
Merit: 1014
advocate of a cryptographic attack on the globe
have you tried moving the data directory to some other drive, and starting bitcoin with datadir=d:\new directory\ ?

No, I reindexed it and it is working fine now.
hero member
Activity: 900
Merit: 1014
advocate of a cryptographic attack on the globe
How old is your HDD? You could be dealing with a faulty disk drive.

Code:
LevelDB read failure: IO error: C:\Users\User\AppData\Roaming\Bitcoin\chainstate\041412.sst: Could not create random access file.

It is about two years now. I can run some SMART tests.
legendary
Activity: 924
Merit: 1004
Firstbits: 1pirata
How old is your HDD? You could be dealing with a faulty disk drive.

Code:
LevelDB read failure: IO error: C:\Users\User\AppData\Roaming\Bitcoin\chainstate\041412.sst: Could not create random access file.
legendary
Activity: 2058
Merit: 1431
have you tried moving the data directory to some other drive, and starting bitcoin with datadir=d:\new directory\ ?
hero member
Activity: 900
Merit: 1014
advocate of a cryptographic attack on the globe
LevelDB read failure: IO error: C:\Users\User\AppData\Roaming\Bitcoin\chainstate\041412.sst: Could not create random access file.

Is it possible your disk is full?

Good question but I have a few 100 gigs free.
legendary
Activity: 2506
Merit: 1010
LevelDB read failure: IO error: C:\Users\User\AppData\Roaming\Bitcoin\chainstate\041412.sst: Could not create random access file.

Is it possible your disk is full?
hero member
Activity: 900
Merit: 1014
advocate of a cryptographic attack on the globe
Just opened 0.8.1 after having successfully opened it a few times and received:
"Error opening block database. Do you want to rebuild the block database now?"

I clicked OK. Here is the debug.log. What might have happened? It shut down cleanly last time.

Bitcoin version v0.8.1-beta (2013-03-17 15:35:36 -0400)
Using OpenSSL version OpenSSL 1.0.1c 10 May 2012
Startup time: 2013-03-20 01:05:38
Default data directory C:\Users\User\AppData\Roaming\Bitcoin
Used data directory C:\Users\User\AppData\Roaming\Bitcoin
Using 4 threads for script verification
init message: Verifying wallet integrity...
dbenv.open LogDir=C:\Users\User\AppData\Roaming\Bitcoin\database ErrorFile=C:\Users\User\AppData\Roaming\Bitcoin\db.log
Bound to [::]:8333
Bound to 0.0.0.0:8333
init message: Loading block index...
Opening LevelDB in C:\Users\User\AppData\Roaming\Bitcoin\blocks\index
Opened LevelDB successfully
Opening LevelDB in C:\Users\User\AppData\Roaming\Bitcoin\chainstate
Opened LevelDB successfully
LoadBlockIndex(): last block file = 9
LoadBlockIndex(): last block file: CBlockFileInfo(blocks=726, size=73739518, heights=226085..226810, time=2013-03-16..2013-03-19)
LoadBlockIndex(): transaction index disabled
LoadBlockIndex(): hashBestChain=00000000000002f51920c4ef0b7f89c08df10c7c8594a750d30532bfd9a7575b  height=226810 date=2013-03-19 22:32:29
init message: Verifying block database integrity...
Verifying last 288 blocks at level 3
LevelDB read failure: IO error: C:\Users\User\AppData\Roaming\Bitcoin\chainstate\041412.sst: Could not create random access file.
init message: Loading block index...
Wiping LevelDB in C:\Users\User\AppData\Roaming\Bitcoin\blocks\index
Opening LevelDB in C:\Users\User\AppData\Roaming\Bitcoin\blocks\index
Opened LevelDB successfully
Wiping LevelDB in C:\Users\User\AppData\Roaming\Bitcoin\chainstate
Opening LevelDB in C:\Users\User\AppData\Roaming\Bitcoin\chainstate
Opened LevelDB successfully
Initializing databases...
Pages:
Jump to: