# Hello, prisma's migration function does not work in Fly Postgres. I think it is occupied by users who manage the cluster, but I don't know how to suspend it.

**URL:** <https://community.fly.io/t/hello-prismas-migration-function-does-not-work-in-fly-postgres-i-think-it-is-occupied-by-users-who-manage-the-cluster-but-i-dont-know-how-to-suspend-it/18150>\
**Category:** General\
**Tags:** dev, postgres, nodejs, login-only\
**Created:** [February 9, 2024, 9:22am UTC](https://community.fly.io/t/hello-prismas-migration-function-does-not-work-in-fly-postgres-i-think-it-is-occupied-by-users-who-manage-the-cluster-but-i-dont-know-how-to-suspend-it/18150 "2024-02-09T09:22:49Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![OConnects](https://sea1.discourse-cdn.com/fly1/user_avatar/community.fly.io/oconnects/32/17983_2.png) [@OConnects](https://community.fly.io/u/OConnects)\
**Post date:** [February 9, 2024, 9:22am UTC](https://community.fly.io/t/hello-prismas-migration-function-does-not-work-in-fly-postgres-i-think-it-is-occupied-by-users-who-manage-the-cluster-but-i-dont-know-how-to-suspend-it/18150/1 "2024-02-09T09:22:49Z")

</div>

I executed the command:

```auto
fly proxy 5432 -a pg

prisma migrate dev --name init

```

Exception thrown

```auto
Prisma schema loaded from prisma/schema.prisma
Datasource "db": PostgreSQL database "postgres", schema "public" at "localhost:5432"

Error: ERROR: database "prisma_migrate_shadow_db_13cc2be0-8659-4d75-a1f5-9997855cc574" is being accessed by other users
DETAIL: There is 1 other session using the database.

```

---

<div class="post-metadata">

**Author:** ![mayailurus](https://sea1.discourse-cdn.com/fly1/user_avatar/community.fly.io/mayailurus/32/17593_2.png) [@mayailurus](https://community.fly.io/u/mayailurus)\
**Post date:** [February 12, 2024, 1:38am UTC](https://community.fly.io/t/hello-prismas-migration-function-does-not-work-in-fly-postgres-i-think-it-is-occupied-by-users-who-manage-the-cluster-but-i-dont-know-how-to-suspend-it/18150/2 "2024-02-12T01:38:25Z")

</div>

Hi… You can use `pg_stat_activity` to see more about who’s present:

[https://community.fly.io/t/rename-postgres-database-after-importing-from-heroku/17840/4](https://community.fly.io/t/rename-postgres-database-after-importing-from-heroku/17840/4)

Is the migration attempting to rename or drop `prisma_migrate_shadow_*` at this point?

---

<div class="post-metadata">

**Author:** ![mayailurus](https://sea1.discourse-cdn.com/fly1/user_avatar/community.fly.io/mayailurus/32/17593_2.png) [@mayailurus](https://community.fly.io/u/mayailurus)\
**Post date:** [February 12, 2024, 1:39am UTC](https://community.fly.io/t/hello-prismas-migration-function-does-not-work-in-fly-postgres-i-think-it-is-occupied-by-users-who-manage-the-cluster-but-i-dont-know-how-to-suspend-it/18150/3 "2024-02-12T01:39:21Z")

</div>

Added #dev, #nodejs

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/fly1/original/3X/6/e/6e8955d00cb218e186ebbe3a6ab06fefdce15290.svg) [@system](https://community.fly.io/u/system)\
**Post date:** [February 19, 2024, 1:39am UTC](https://community.fly.io/t/hello-prismas-migration-function-does-not-work-in-fly-postgres-i-think-it-is-occupied-by-users-who-manage-the-cluster-but-i-dont-know-how-to-suspend-it/18150/4 "2024-02-19T01:39:43Z")

</div>

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.
