Eos: 1.8.1 start from snapshot error

Created on 17 Jul 2019  ·  6Comments  ·  Source: EOSIO/eos

From http://snapshots.eossweden.org/ download the latest snapshot, and start nodeos like below

nodeos --data-dir /data/eos --verbose-http-errors --http-validate-host=false --snapshot /data/eos/${snapshotfile}

The printout is

info 2019-07-17T10:01:27.517 nodeos controller.cpp:2255 startup ] Starting initialization from snapshot, this may take a significant amount of time
error 2019-07-17T10:01:34.968 nodeos controller.cpp:2261 startup ] db storage not configured to have enough storage for the provided snapshot, please increase and retry snapshot
error 2019-07-17T10:01:36.039 nodeos main.cpp:117 main ] bad alloc

Support

Most helpful comment

I guess you need to have around 16GB available RAM to start with this snapshot. Please set chain-state-db-size-mb = 16384 and it take about less than 1 hour:

info  2019-12-02T06:17:32.940 thread-0  controller.cpp:2261           startup              ] Starting initialization from snapshot, this may take a significant amount of time
info  2019-12-02T06:55:03.072 thread-0  controller.cpp:688            init                 ] database initialized with hash: f1b1e1461cfdc2cd01395f0404fa35a1a21fc14b3bb1294f2133f260e91512f2
info  2019-12-02T06:55:03.072 thread-0  controller.cpp:2271           startup              ] Finished initialization from snapshot
info  2019-12-02T06:55:03.072 thread-0  chain_plugin.cpp:982          plugin_startup       ] starting chain in read/write mode
info  2019-12-02T06:55:03.073 thread-0  chain_plugin.cpp:986          plugin_startup       ] Blockchain started; head block is #92771723, genesis timestamp is 2018-06-08T08:08:08.888

All 6 comments

Only find out 2 config value about db and both larger than the bin file.

grep db config.ini

chain-state-db-size-mb = 65536
reversible-blocks-db-size-mb = 65536

ls -l
total 2506952
-rw-r--r-- 1 nobody nogroup 10234 Jul 17 10:09 config.ini
-rw-r--r-- 1 nobody nogroup 816 Jul 11 10:14 genesis.json
-rw-r--r-- 1 1001 1001 2090643731 Jul 17 06:01 snapshot-69102198.bin

What's the size of your physical RAM?

4.00 GB (3.89 GB usable)

I faced and solved this problem very easily. The only thing you should make is,

nano ~/.local/share/eosio/nodeos/config/config.ini

and find the line

# Maximum size (in MiB) of the chain state database (eosio::chain_plugin)

after that, just delete the # sign for the option and set your maximum size as your hdd/ssd area.

For example, for 1tb SSD or HDD store, your config file should look like the figure below,

image

I guess you need to have around 16GB available RAM to start with this snapshot. Please set chain-state-db-size-mb = 16384 and it take about less than 1 hour:

info  2019-12-02T06:17:32.940 thread-0  controller.cpp:2261           startup              ] Starting initialization from snapshot, this may take a significant amount of time
info  2019-12-02T06:55:03.072 thread-0  controller.cpp:688            init                 ] database initialized with hash: f1b1e1461cfdc2cd01395f0404fa35a1a21fc14b3bb1294f2133f260e91512f2
info  2019-12-02T06:55:03.072 thread-0  controller.cpp:2271           startup              ] Finished initialization from snapshot
info  2019-12-02T06:55:03.072 thread-0  chain_plugin.cpp:982          plugin_startup       ] starting chain in read/write mode
info  2019-12-02T06:55:03.073 thread-0  chain_plugin.cpp:986          plugin_startup       ] Blockchain started; head block is #92771723, genesis timestamp is 2018-06-08T08:08:08.888

In order to focus our efforts on issues that are currently creating difficulty for the community we are closing tickets that were created prior to the EOSIO 2.0 release. If you believe this issue is still relevant please feel free to reopen it or create a new one. Thank you for your continued support of EOSIO!

Was this page helpful?
0 / 5 - 0 ratings

Related issues

sim31 picture sim31  ·  3Comments

ResponsiveWebApps picture ResponsiveWebApps  ·  3Comments

IvanYakimov picture IvanYakimov  ·  3Comments

bezalel picture bezalel  ·  3Comments

yashbhavsar007 picture yashbhavsar007  ·  3Comments