# V2.2 not work pgbackrest

**URL:** <https://forums.percona.com/t/v2-2-not-work-pgbackrest/24267>\
**Category:** Percona Operator for PostgreSQL\
**Created:** [August 7, 2023, 10:59am UTC](https://forums.percona.com/t/v2-2-not-work-pgbackrest/24267 "2023-08-07T10:59:23Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Sergey\_Zhuravlev](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/sergey_zhuravlev/32/6410_2.png) [@Sergey\_Zhuravlev](https://forums.percona.com/u/Sergey_Zhuravlev)\
**Post date:** [August 7, 2023, 10:59am UTC](https://forums.percona.com/t/v2-2-not-work-pgbackrest/24267/1 "2023-08-07T10:59:23Z")

</div>

## Description:

I deploy a cluster where only the master without replicas.  
Apparently in this case, a stanza is not created. (???)  
In the logs of the operator there are such entries:

```auto
time="2023-08-07T10:55:26Z" level=debug msg="command terminated with exit code 31: ERROR: [031]: configuration file contains duplicate options ('repo1-path', 'repo-path') in section '[global]'\n" object="{PostgresCluster pgo pdb e1810128-f1ca-4b34-a3e5-7cf5d488f5ef postgres-operator.crunchydata.com/v1beta1 1478195 }" reason=UnableToCreateStanzas type=Warning version=
time="2023-08-07T10:55:26Z" level=debug msg="reconciled cluster" PostgresCluster=pgo/pdb controller=postgrescluster controllerGroup=postgres-operator.crunchydata.com controllerKind=PostgresCluster name=pdb namespace=pgo reconcileID=be98145c-985d-431e-9f3e-549e8a803757 version=

```

attempts to make a backup on demand are not successful

## Steps to Reproduce:

deploy a cluster where only the master without replicas

## Version:

pgo2.2 pgbackrest 2.43

## Logs:

time=“2023-08-07T10:55:26Z” level=debug msg=“command terminated with exit code 31: ERROR: [031]: configuration file contains duplicate options (‘repo1-path’, ‘repo-path’) in section ‘[global]’\n” object=“{PostgresCluster pgo pdb e1810128-f1ca-4b34-a3e5-7cf5d488f5ef [postgres-operator.crunchydata.com/v1beta1](http://postgres-operator.crunchydata.com/v1beta1) 1478195 }” reason=UnableToCreateStanzas type=Warning version=  
time=“2023-08-07T10:55:26Z” level=debug msg=“reconciled cluster” PostgresCluster=pgo/pdb controller=postgrescluster [controllerGroup=postgres-operator.crunchydata.com](http://controllerGroup=postgres-operator.crunchydata.com) controllerKind=PostgresCluster name=pdb namespace=pgo reconcileID=be98145c-985d-431e-9f3e-549e8a803757 version=

---

<div class="post-metadata">

**Author:** ![Sergey\_Zhuravlev](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/sergey_zhuravlev/32/6410_2.png) [@Sergey\_Zhuravlev](https://forums.percona.com/u/Sergey_Zhuravlev)\
**Post date:** [August 7, 2023, 6:46pm UTC](https://forums.percona.com/t/v2-2-not-work-pgbackrest/24267/2 "2023-08-07T18:46:33Z")

</div>

I clarify the situation - we use our own image pg13 which is from the Dockerfile of the corresponding percona repo.  
We inserted a COPY of the RPMs we collected with a couple of pg extensions into it. And another command to install these rpm.

Now we noticed that with the native image for pg13 there is a file  
/etc/pgbackrest.conf with content

```auto
[main]
#pg1-path=/data/db

```

and with ours we have content like this

```auto
[global]
repo-path=/var/lib/pgbackrest

#[main]
#pg-path=/var/lib/pgsql/data

```

It became clear what was causing the error, but it is not clear why this is happening)  
Tried to delete a /etc/pgbackrest.conf file in the Dockerfile

the original error disappeared, but lo and behold a new one appeared

```auto
4373-a051-b081d1cefc46 reconciler=pgBackRest version=
time="2023-08-07T18:09:47Z" level=debug msg="command terminated with exit code 39: ERROR: [039]: expected value '2.44' for greeting key 'version' but got '2.43'\n HINT: is the same version of pgBackRest installed on the local and remote host?\n" object="{PostgresCluster pgo2 xdb 112bd3e3-6be5-4e53-9068-5cd2cd013629 postgres-operator.crunchydata.com/v1beta1 12361 }" reason=UnableToCreateStanzas type=Warning version=

```

Can someone explain how this works?

Checked pgbackrest versions everywhere 2.43 – Sorry!!! This is not true.

---

<div class="post-metadata">

**Author:** ![Sergey\_Zhuravlev](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/sergey_zhuravlev/32/6410_2.png) [@Sergey\_Zhuravlev](https://forums.percona.com/u/Sergey_Zhuravlev)\
**Post date:** [August 8, 2023, 9:10am UTC](https://forums.percona.com/t/v2-2-not-work-pgbackrest/24267/3 "2023-08-08T09:10:19Z")

</div>

I checked it more carefully - it turned out that version 2.44 is being built into our image - although we did not indicate this anywhere.

---

<div class="post-metadata">

**Author:** ![Sergey\_Zhuravlev](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/sergey_zhuravlev/32/6410_2.png) [@Sergey\_Zhuravlev](https://forums.percona.com/u/Sergey_Zhuravlev)\
**Post date:** [August 8, 2023, 11:35am UTC](https://forums.percona.com/t/v2-2-not-work-pgbackrest/24267/4 "2023-08-08T11:35:47Z")

</div>

Everything was decided like this: (in Dockerfile)

1. replaced  
`percona-pgbackrest`  
on  
`percona-pgbackrest-1:2.43-1.el8.x86_64`
2. added a line to remove /etc/pgbackrest.conf  
`RUN rm -rf /etc/pgbackrest.conf`
