Postgresql can't connect application server through PGAdmin4

前端 未结 8 2022
陌清茗
陌清茗 2020-12-30 08:18

I installed PostgreSql on my Windows machine. I can connect to PostgreSql through cmd. But when I want to launch pgAdmin I am getting this error message.

相关标签:
8条回答
  • 2020-12-30 08:47

    I ran into this today even though the service was running in Windows 10. I just stopped the service, gave it a few seconds, and restarted it. I was able to connect with pgAdmin 4.

    0 讨论(0)
  • 2020-12-30 08:48

    Try starting the pgAdmin as administrator.

    0 讨论(0)
  • 2020-12-30 08:48

    You can start the server manually - any errors will echo on the terminal. The windows app seems touchy on timing - this allows the server to take as much time as needed to start up.

    Assuming you installed version 3 into "p:\pgAdmin 4" run the following commands"

    p:
    cd "\pgAdmin 4\v3\web"
    set PYTHONPATH=P:\pgAdmin 4\v3\venv\Lib;P:\pgAdmin 4\v3\venv\DLLs
    python pgAdmin4.py
    

    When I run that I get the following output:

    Starting pgAdmin 4. Please navigate to http://127.0.0.1:5050 in your browser.
    
    0 讨论(0)
  • 2020-12-30 08:53

    In my case the problem was solved by restarting the postgresql service. Windows-> Service -> find for postgreSQL -> Stop and then Start

    0 讨论(0)
  • 2020-12-30 08:55

    In my case, SERVER_MODE was already False in config_distro.py. I then proceeded to start pgadmin4 as an administrator. This also did not work. Finally, I resolved this by restarting postgresql service in services.msc. postgres service restart

    0 讨论(0)
  • 2020-12-30 08:58

    In my case, the problem was non-ascii username.

    Find pgAdmin installation and open/create config_local.py in editor, add this:

    DATA_DIR = "C:/Data/pgAdmin" # set non-ascii path here
    

    and run setup.py using python interpreter.

    0 讨论(0)
提交回复
热议问题