AntelopeIO / spring

C++ implementation of the Antelope protocol with Savanna consensus
Other
9 stars 5 forks source link

Starting with wrong option in config.ini creates a corrupte state file #154

Closed matthewdarwin closed 2 weeks ago

matthewdarwin commented 5 months ago

Start nodeos with producer-threads = 4, which is invalid for this release. Restart nodeos after removing that option, and you end up with this mess:

May 17 13:32:18 spring1-bp203 nodeos[512]: error 2024-05-17T13:32:18.982 nodeos    main.cpp:217                  main                 ] 3060005 bad_database_version_exception: Database is an unknown or unsupported version
May 17 13:32:18 spring1-bp203 nodeos[512]: state database version pre-dates versioning, please restore from a compatible snapshot or replay!
May 17 13:32:18 spring1-bp203 nodeos[512]:     {}
May 17 13:32:18 spring1-bp203 nodeos[512]:     nodeos  controller.cpp:1859 validate_db_version
May 17 13:32:18 spring1-bp203 nodeos[512]: rethrow
May 17 13:32:18 spring1-bp203 nodeos[512]:     {}
May 17 13:32:18 spring1-bp203 nodeos[512]:     nodeos  chain_plugin.cpp:1097 plugin_initialize

Nodeos should not create a corrupt state database.

heifner commented 5 months ago

Potentially related to #138

matthewdarwin commented 5 months ago

Yes, I'm using block-log-retain-blocks = 0

heifner commented 5 months ago

Is it possible you had an old data-dir/state/ directory from a different version of nodeos?

heifner commented 5 months ago

Did you happen to run with main before using release/1.0-beta1 ?

bhazzard commented 2 weeks ago

We haven't been able to reproduce this.