# QAN API is Down after upgrade the PMM server from 2.44.0 to 3.2.0 version

**URL:** <https://forums.percona.com/t/qan-api-is-down-after-upgrade-the-pmm-server-from-2-44-0-to-3-2-0-version/38369>\
**Category:** Percona Monitoring and Management (PMM)\
**Created:** [June 18, 2025, 7:15am UTC](https://forums.percona.com/t/qan-api-is-down-after-upgrade-the-pmm-server-from-2-44-0-to-3-2-0-version/38369 "2025-06-18T07:15:51Z")\
**Posts on this page:** 1\
**Showing post:** 7

<div class="post-metadata">

**Author:** ![Naresh9999](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/naresh9999/32/5568_2.png) [@Naresh9999](https://forums.percona.com/u/Naresh9999)\
**Post date:** [June 29, 2025, 6:43am UTC](https://forums.percona.com/t/qan-api-is-down-after-upgrade-the-pmm-server-from-2-44-0-to-3-2-0-version/38369/7 "2025-06-29T06:43:49Z")

</div>

@nurlan, I have resolved the issue by following the steps outlined below.

**Note:** Prior to attempting the PMM 3.2.0 upgrade, I had already taken a backup of PMM 2.44.0 from the production server.

- **Production Server:** `prdpmm101`
- **Temporary Server:** `tmppmm101`

After the PMM 3.2.0 upgrade on the production server failed, I decided to restore the PMM 2.44.0 backup to the temporary server, perform the upgrade there, and then migrate the working setup back to the production environment.

### **Steps taken to resolve the PMM 3.2.0 upgrade issue:**

1. Restored the PMM 2.44.0 backup on the temporary server `tmppmm101`.
2. Upgraded the temporary server to PMM 3.2.0.
3. Verified the status of all services using the PMM Health Check dashboard.
4. This time, the Query Analytics (QAN) functionality came up without issues.
5. After confirming the upgrade was successful, I took a backup of PMM 3.2.0 from the temporary server.
6. Copied the PMM 3.2.0 backup from `tmppmm101` to the production server `prdpmm101`.
7. Performed a fresh installation of PMM 3.2.0 on the production server.
8. Restored the PMM 3.2.0 backup to the production server.
9. Post-restore, I observed that the internal PostgreSQL monitoring was showing issues — specifically, the agent status was displayed as **Down** on the Service Summary dashboard.
10. I reported this issue in the Percona forum:  
[PMM3 | PostgreSQL | Inside container FATAL: role does not exist](https://forums.percona.com/t/pmm3-postgresql-inside-container-fatal-role-does-not-exist/38413)
11. To address the **PostgreSQL role issue** , it is essential to follow these steps:

- After the fresh installation of PMM 3.2.0 but **before restoring the backup** , note down the usernames and passwords from the `agents` table for both `postgres_exporter` and `qan-postgresql-pgstatements-agent`.

1. Once the backup restoration is complete, update the PostgreSQL agent usernames and passwords in the production server using the values noted in step 11.

UPDATE agents SET username = ‘XXXXXXX’,password = ‘XXXXXXX’,updated\_at = NOW() WHERE agent\_id = ‘XXXXXXX’ AND agent\_type = ‘postgres\_exporter’;

UPDATE agents SET username = ‘XXXXXXX’,password = ‘XXXXXXX’,updated\_at = NOW() WHERE agent\_id = ‘XXXXXXX’ AND agent\_type = ‘qan-postgresql-pgstatements-agent’;

1. Verify the PostgreSQL agent status in the PMM Service Summary dashboard.
2. If all services, including the PostgreSQL monitoring, show as **Up** , the backup restoration and upgrade process on the production server can be considered successful.

---

_[View the full topic](https://forums.percona.com/t/qan-api-is-down-after-upgrade-the-pmm-server-from-2-44-0-to-3-2-0-version/38369)._
