My serve active, but connection refuse. My plan is free.
I use Python
Error:OperationalError: connection to server at “localhost” (::1), port 5432 failed: Connection refused (0x0000274D/10061)
Is the server running on that host and accepting TCP/IP connections?
connection to server at “localhost” (127.0.0.1), port 5432 failed: Connection refused (0x0000274D/10061)
Is the server running on that host and accepting TCP/IP connections?
Code:
connection_string = os.getenv(‘postgres://###:#####@ep-blue-sun-37031258.us-east-2.aws.neon.tech/Teste’)
# Connect to the PostgreSQL database
conn = psycopg2.connect(connection_string)
Line error: 6 conn = psycopg2.connect(connection_string)
@ThiagoLM did you end up getting a response to this? I’ve just experienced this while doing running showcase .
Caught error: PrismaClientUnknownRequestError:
Invalid `prisma.patient.findMany()` invocation:
Error occurred during query execution:
ConnectorError(ConnectorError { user_facing_error: None, kind: QueryError(PostgresError { code: "08001", message: "[NEON_SMGR] could not establish connection to pageserver", severity: "ERROR", detail: Some("connection to server at \"pageserver-2.ap-southeast-1.aws.neon.tech\" (ITS_IP_ADDRESS), port ITS_PORT failed: Connection refused\n\tIs the server running on that host and accepting TCP/IP connections?"), column: None, hint: None }), transient: false })
at si.handleRequestError (/var/task/node_modules/.pnpm/@prisma+client@5.8.1_prisma@5.8.1/node_modules/@prisma/client/runtime/library.js:125:7007)
at si.handleAndLogRequestError (/var/task/node_modules/.pnpm/@prisma+client@5.8.1_prisma@5.8.1/node_modules/@prisma/client/runtime/library.js:125:6151)
at si.request (/var/task/node_modules/.pnpm/@prisma+client@5.8.1_prisma@5.8.1/node_modules/@prisma/client/runtime/library.js:125:5859)
at async l (/var/task/node_modules/.pnpm/@prisma+client@5.8.1_prisma@5.8.1/node_modules/@prisma/client/runtime/library.js:130:9805)
at async d (/var/task/.next/server/app/page.js:18:8680)
at async l (/var/task/.next/server/app/page.js:18:6924)
at async T (/var/task/.next/server/app/page.js:18:2438) {
clientVersion: '5.8.1'
}
Just to let you know, it eventually started working again ~5 minutes later. I also looked at Neon’s Services Status page to see if there was a potential outage, but there was nothing there.
Sorry to hear that you’re running into an issue. Do you mind sharing more details about your setup? Based on the logs you shared, I see that you’re using Next.js and Prisma. Are you using Serverless functions on Vercel? Or are you using something else?
Also, are you running into this issue frequently?
I also looked at Neon’s Services Status page to see if there was a potential outage, but there was nothing there.
We didn’t have any recent incidents that affected the ap-southeast region. If you could share with me your project ID (you can find it in your project settings) our team can take a closer look.
Btw if you prefer to not have this conversation here, you can reach out on our Discord