Postgres - Unsupported Frontend Protocol
Asked by Andreas H:

Hello,

running a Confluence Self Hosted Server in Docker since March 2020. Did my first image Update lately in December 2020.

```
version: '3.3'

services:
confluence:
image: atlassian/confluence-server:latest
depends_on:
- db
restart: unless-stopped
container_name: confluence
volumes:
- ./data/confluence/confluencedata:/var/atlassian/application-data/confluence
ports:
- '8090:8090'
- '8091:8091'
environment:
- CONFLUENCE_DB_HOST=db
- CONFLUENCE_DB_PORT=5432
- JVM_MAXIMUM_MEMORY=2048
- CATALINA_OPTS=-Xms256m -Xmx1g
- ATL_PROXY_NAME=my.proxy.name
- ATL_PROXY_PORT=443
- ATL_TOMCAT_SCHEME=https

db:
image: postgres:9.6
container_name: postgres
restart: unless-stopped
volumes:
- ./data/postgresdb/postgresqldata:/var/lib/postgresql/data
environment:
- POSTGRES_USER=postgresuser
- POSTGRES_PASSWORD=postgresuserpassword
- POSTGRES_DB=confluencedb

volumes:
confluencedata: {}
postgresqldata: {}
```

After the update i get the following message when starting with docker-compose up:

```
postgres | FATAL: unsupported frontend protocol 1234.5680: server supports 1.0 to 3.0
```

Since then, server is not starting up anymore.

How do i solve this issue?


Answers:
author: Thiago Masutti
body: Hi [@Andreas H](/t5/user/viewprofilepage/user-id/4216937)

I hope you are well.

It seems the problem you are facing is similar to what is reported in [CONFSERVER-60515](https://jira.atlassian.com/browse/CONFSERVER-60515).

I would suggest you to try replacing the [PostgreSQL JDBC driver](https://confluence.atlassian.com/doc/database-jdbc-drivers-171742.html) bundled with Confluence with the 42.2.18 version available [in this link](https://jdbc.postgresql.org/download.html).

Let us know if that works.

Kind regards  
Thiago Masutti

comments: author: Andreas H
body: Hi [@Thiago Masutti](/t5/user/viewprofilepage/user-id/1209618)

Thanks for the Links.

The location for the driver files inside the docker container is:

```
/opt/atlassian/confluence/confluence/WEB-INF/lib
```

It is also filled with many other .jars.

I tried adding a volume to this directory, but on the host system, the directory stays empty. For testing purposes, i downloaded the Postgresql driver into this volume. It is loaded successfully and the problem seems fixes for the Database part, but the other .jars are now missing.

How do i get the file into the container (optimally keep it portable with volumes)?

Kind regards


author: Andreas H
body: Bump, help?


author: Thiago Masutti
body: Hi [@Andreas H](/t5/user/viewprofilepage/user-id/4216937)

Sorry I didn't see the message here.

You could replace the library file by directly mounting the jar file similar as below:

```
docker run -v <host-confluence-home>:/var/atlassian/application-data/confluence -v <host-confluence-home>/postgresql-42.2.18.jar:/opt/atlassian/confluence/confluence/WEB-INF/lib/postgresql-42.2.16.jar --name="confluence-staging" -d -p 8090:8090 -p 8091:8091 atlassian/confluence-server:7.4.6
```

In the above example, I've downloaded the new JDBC driver file to the location of the home folder in the host and replaced the original file, which in the case of Confluence 7.4.6 is *postgresql-42.2.16.jar*.

Regards,  
Thiago


author: David Pressley
body: did [@Thiago Masutti](/t5/user/viewprofilepage/user-id/1209618) fix solve your issue [@Andreas H](/t5/user/viewprofilepage/user-id/4216937) ?

I also noticed you had an environment variable configured for

```
JVM_MAXIMUM_MEMORY=2048
```

In my case, I had to add the unit label for my server to start up

```
JVM_MAXIMUM_MEMORY=2048m
```

your CATALINA_OPTS environment var may have corrected this though?

I am running with 42.2.16, but get a ton of the unsupported frontend protocol errors in my log

In any case, the following in my Dockerfile worked for me to update the Postgres driver and seems to have resolved the error for my work in the 7.10.0 image from Atlassian

```
FROM atlassian/confluence:7.10.0-ubuntu-jdk11
```

```
WORKDIR /opt/atlassian/confluence/confluence/WEB-INF/lib
COPY postgresql-42.2.18.jar postgresql-42.2.18.jar 
RUN rm postgresql-42.2.16.jar
```


Tags: confluence-server

docker

postgres

server