Postgres storage initialization failure: Message: ERROR: relation "maps_idx" already exists
bradydean opened this issue ยท 2 comments
I'm trying to use Postgres as the storage backend. The first time I booted the server up the logs indicated the storage backend successfully created the db schema. After rebooting the server, I get an uncaught exception about initializing the storage backend.
- Dynmap Version: 3.4-beta-3-spigot
- Server Version: paper 1.18.2-378
- Pastebin of Configuration.txt: https://pastebin.com/JvvgLgxp
- Server Host (if applicable): Self hosted
- Pastebin of crashlogs or other relevant logs: https://pastebin.com/P7GNCu48
- Steps to Replicate:
I'm using the postgres:14
docker image. I have added a dynmap
user, dynmap
database, and granted role dynmap
all privileges on database dynmap
. The paper instance is deployed in a amazoncorretto:18
docker image.
[X] I have looked at all other issues and this is not a duplicate
[X] I have been able to replicate this
In my first-boot logs I have
[23:50:34 INFO]: [dynmap] Initializing database schema
[23:50:35 INFO]: [dynmap] Schema version = 4
[23:50:35 INFO]: [dynmap] Mod Support processing completed
However, select * from schemaversion
shows level=3
. This may explain why the error logs say it's trying to migrate from schema version 3.
EDIT: I read through the code which migrates the db and since version 4 only adds the index, and considering it's already created, I manually updated level to 4 and it appears to be working now.
already found in #3765 and they created a patch for it, the most recent version of dynmap should have the fix implemented.
If you find that to not be the case you can go ahead and reopen this issue.