Ticket: PostgreSQL version mismatch and authentication errors issue
@defispider Just created a ticket
Question: In the repo docker-compose.dev.yaml file missing lines document https://docs.postiz.com/installation/docker-compose is better but still it fails with following: DETAIL: The data directory was initialized by PostgreSQL version 17, which is not compatible with this version 14.5 (Debian 14.5-2.pgdg110+2). FATAL: database files are incompatible with server postiz-postgres | 2024-10-26 11:32:36.112 UTC [1] DETAIL: The data directory was initialized by PostgreSQL version 17, which is not compatible with this version 14.5 (Debian 14.5-2.pgdg110+2). postiz-postgres | PostgreSQL Database directory appears to contain a database; Skipping initialization docker pulls recent postgresql which is 17 but data directory postgresql version is 14. I changed the following line postiz-postgres: image: postgres:17.0 then I can pass this error but then I got another error : postiz | [Nest] 170 - 10/26/2024, 11:42:53 AM ERROR [PrismaClientInitializationError: Authentication failed against database server at postiz-postgres, the provided database credentials for postiz-user are not valid. postiz | postiz | Please make sure to provide valid database credentials for the database server at postiz-postgres.] Backend failed to start on port 3000 postiz-postgres | 2024-10-26 11:42:56.352 UTC [52] FATAL: role "postiz-user" does not exist postiz | 2024-10-26 11:42:59,948 INFO success: backend entered RUNNING state, process has stayed up for > than 10 seconds (startsecs) π Reproduction steps Try to install mac locally from first repo which fails then try copying from docs https://docs.postiz.com/installation/docker-compose the content of docker-compose.yml file. NODE_VERSION 20.17
Attempted: trying to install locally
Working On: trying to install locally
Take it from here @Postiz
Question: In the repo docker-compose.dev.yaml file missing lines document https://docs.postiz.com/installation/docker-compose is better but still it fails with following: DETAIL: The data directory was initialized by PostgreSQL version 17, which is not compatible with this version 14.5 (Debian 14.5-2.pgdg110+2). FATAL: database files are incompatible with server postiz-postgres | 2024-10-26 11:32:36.112 UTC [1] DETAIL: The data directory was initialized by PostgreSQL version 17, which is not compatible with this version 14.5 (Debian 14.5-2.pgdg110+2). postiz-postgres | PostgreSQL Database directory appears to contain a database; Skipping initialization docker pulls recent postgresql which is 17 but data directory postgresql version is 14. I changed the following line postiz-postgres: image: postgres:17.0 then I can pass this error but then I got another error : postiz | [Nest] 170 - 10/26/2024, 11:42:53 AM ERROR [PrismaClientInitializationError: Authentication failed against database server at postiz-postgres, the provided database credentials for postiz-user are not valid. postiz | postiz | Please make sure to provide valid database credentials for the database server at postiz-postgres.] Backend failed to start on port 3000 postiz-postgres | 2024-10-26 11:42:56.352 UTC [52] FATAL: role "postiz-user" does not exist postiz | 2024-10-26 11:42:59,948 INFO success: backend entered RUNNING state, process has stayed up for > than 10 seconds (startsecs) π Reproduction steps Try to install mac locally from first repo which fails then try copying from docs https://docs.postiz.com/installation/docker-compose the content of docker-compose.yml file. NODE_VERSION 20.17
Attempted: trying to install locally
Working On: trying to install locally
Take it from here @Postiz
10 Replies
Did you change your-domain.com to localhost?
your-server.com*
hmm no let me change and retry
Alright
With the port 5000
MAIN_URL: "http://locahost:5001"
FRONTEND_URL: "http://locahost:5001"
NEXT_PUBLIC_BACKEND_URL: "http://locahost/api:5001"
5000 in use on macos
β― lsof -i tcp:5000
COMMAND PID USER FD TYPE DEVICE SIZE/OFF NODE NAME
ControlCe 403 defispider 10u IPv4 0xb41fdf8b47e05570 0t0 TCP *:commplex-main (LISTEN)
ControlCe 403 defispider 11u IPv6 0x56519c4ddb2a215f 0t0 TCP *:commplex-main (LISTEN)
I changed 3 of the URLs now and retrying
I got following `
I changes https to > http
because of local install
hmm
do you have an linux mashine?
I have linux server there are some thing on it wordpress etc
do you have mac or linux on your local?
`
it might be releated here
I changed here 17.0
otherwise it does not work
at all
I am hosting everything in Proxmox CTs withUbuntu (linux)
Maybe some images are not optimized for mac?
2024-10-26 12:53:43.578 UTC [1] DETAIL: The data directory was initialized by PostgreSQL version 17, which is not compatible with this version 14.5 (Debian 14.5-2.pgdg110+2).
I retried with 14.5 version
may be
I will try to install linux server probaby it will more straightforward
Thank you
Alright
Heya
This can happen if you started Postiz in the past with and older version of postgres, and now are moving to a more recent version.
If this is just a testing deployment and you don't need your postiz data, just delete the postiz volume to start a new one.
If you need to keep it, use the postgres upgrade tools as described