Hi,
its nice we get more and more new backend db's supported with minetest. One question come up in my mind: "how do i convert an existing sqlite3 db to the redis db? Is there any hint how this could be performed somehow?
TIA
redis support / convert sqlite db
-
- Moderator
- Posts: 4095
- Joined: Wed Aug 24, 2011 09:44
- GitHub: sfan5
- IRC: sfan5
- Location: Germany
Re: redis support / convert sqlite db
1) Set the connections settings in world.mt
2) run minetestserver --migrate redis --world /path/to/world/directory/
3) Done!
This is the same for converting to other backends except that you don't need connection settings for sqlite3 or leveldb.
2) run minetestserver --migrate redis --world /path/to/world/directory/
3) Done!
This is the same for converting to other backends except that you don't need connection settings for sqlite3 or leveldb.
Re: redis support / convert sqlite db
this argument will drop all sqlite3 contents to the new redis db?
-
- Moderator
- Posts: 4095
- Joined: Wed Aug 24, 2011 09:44
- GitHub: sfan5
- IRC: sfan5
- Location: Germany
Re: redis support / convert sqlite db
It will copy all MapBlocks (16x16x16 cubes of nodes) into the redis database and also update the backend setting in world.mt. The sqlite3 database will still be present but can then be deleted.fgr wrote:this argument will drop all sqlite3 contents to the new redis db?
Re: redis support / convert sqlite db
thanks, will give it a try ... for performance tests.
Re: redis support / convert sqlite db
One question I have to the db contents on redis. How do you get persistence to work in case the server crashes? Will the hash entries be lost instead stored at the latest action within minetest?
Re: redis support / convert sqlite db
What are the main advantages of the new DB system?
Re: redis support / convert sqlite db
ignore my inputs prior:
the solution is to add all the information to the world.mt file like this:
then use the command to start minestserver for migrate to redis
take a coffee and wait til it ends. ;)
Update: the migration process gives a core dump...
the solution is to add all the information to the world.mt file like this:
Code: Select all
backend = sqlite3
redis_address = localhost
redis_port = 6379
redis_hash = minetest_pub
Code: Select all
./minetestserver --migrate redis
Update: the migration process gives a core dump...
Code: Select all
20:43:37: ACTION[main]: Migrated 1225500 blocks 53.8197% completed
Segmentation fault (core dumped)
debug:
Program received signal SIGSEGV, Segmentation fault.
0x0000000000527ea9 in Database_Redis::saveBlock(MapBlock*) ()
(gdb) bt
#0 0x0000000000527ea9 in Database_Redis::saveBlock(MapBlock*) ()
#1 0x000000000045da43 in main ()
Who is online
Users browsing this forum: No registered users and 43 guests