Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8683907
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 12, 20262026-06-12T22:09:49+00:00 2026-06-12T22:09:49+00:00

I am using Postgres 9.1.5. The JDBC works fine on the very first instance

  • 0

I am using Postgres 9.1.5. The JDBC works fine on the very first instance but it starts refusing connection when I try to do it again. For example, I logged in to my web-application using JDBC, works fine. But then, I try to use the connection to fetch some other data, its raises an exception: Connection refused. I am sure that there is nothing wrong with my code because the login JDBC, that worked fine last time also raises an exception: Connection Refused.

It works again after I restart the postgres windows service. Then,login JDBC, some data gets fetched and then connection refused. I have tried reinstallation. Is there something wrong with my laptop?

Also, PGAdmin, suffers from the same problem. It would run some queries and then starts showing the error message: Postgres service has stopped.
Is there anything I can do? Please advice.
Also, if there is any extra information required, please let me know.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-12T22:09:50+00:00Added an answer on June 12, 2026 at 10:09 pm

    Hard to guess, looks like it starts up properly but gets into problems later on. Your first stop in these cases should always be the logfile. A quick check could be to verify max_connections in the configuration file (doc here), it might be preset at a ridiculously low value. If in pgAdminIII you click on the server node, you can see all open connections under the “statistics” tab as well, maybe there’s some issue with a process that eats up all available connections.

    Another way of figuring out what happens would be to start the postgres server interactively (ie, have it output all its messages in the window you started it in) as explained in the official documentation.

    Also, if your server runs on Linux, ps can help you, postgres connections are managed by individual processes, ie they appear individually in ps:

    ps ax | grep postgres:
    ....
    20528 ?        Ss     0:00 postgres: username dbname clienraddress(48679) idle
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I create a connection to a postgres 9 database using the stardard JDBC driver.
Using Postgres on Heroku Cedar, when I try to verify a public key using
I can compile but can't execute the following code with the error (using Postgres):
I'm using postgres, and I have a users table which contains users first and
I am trying to retrieve a blob from a postgres database using the jdbc
I've installed postgresql 9.1 for Windows but I can't connect to it using JDBC.
We are using Postgres 9.1.0 with Hibernate 3.2.5. I have downloaded latest JDBC driver
I've been using JDBC with a local Postgres DB to copy data from CSV
I'm trying to throw together a quick JDBC app using Postgres as the DB
Using Postgres, I'm trying to use AUTO_INCREMENT to number my primary key automatically in

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.