• Register
0 votes

Problem :

I am not very sure how can I fix the below issue

I have really no idea about why am I facing below error while trying to do the runserver:

Performing system checks...
System check identified no issues (0 silenced).
Unhandled exception in thread started by <function wrapper at 0x1085589b0>
Traceback (most recent call last):
  File "/Library/Python/2.7/site-packages/django/utils/autoreload.py", line 333, in wrapper
    fn(*args, **kwargs)
  File "/Library/Python/2.7/site-packages/django/core/management/commands/runserver.py", line 218, in inner_run


And when I try to connect to my postgres I face below error:

psql: could not connect to server: No such file or directory
        Is the server running locally and accepting
        connections on Unix domain socket "/tmp/.s.PGSQL.5432"?
6 5 3
7,540 points

Please log in or register to answer this question.

1 Answer

0 votes

Solution :

It can be some of the below issues:

1. The PostgreSQL is not running. You need to check it with the sudo service postgresql status

2. The PostgresSQl is not running on the port no 5432. You need to check it by typing sudo netstat -nl | grep postgres

3. You have something wrong while trying to connect to the db like your username,your password or your databasename. You need to check that they are what the postgres ask for you to connect it and that is your db_name that you want to access to.

9 7 4
38,600 points

Related questions

0 votes
1 answer 2 views
Problem: Could not connect to server connection refused.
asked Apr 7 charles mathews 5.5k points
0 votes
1 answer 318 views
Problem : I am facing a lot of errors with the below message : &ldquo;DatabaseError: current transaction is aborted, commands ignored until end of transaction block&rdquo; Whenever I tried to change from the python-psycopg to the python-psycopg2 as my Django project's database engine. My code remains the same, just unable to know where those errors are coming from ?
asked Jan 4, 2020 alecxe 7.5k points
0 votes
1 answer 103 views
Problem : I am having hell lot of troubles because of below error message internalerror: current transaction is aborted, commands ignored until end of transaction block
asked Nov 14, 2019 peterlaw 6.9k points
0 votes
1 answer 7 views
Problem: I'm trying to run psql on my Vagrant machine, but I get this error: psql: could not connect to server: No such file or directory
asked Mar 31 ummesalma 25.2k points
0 votes
2 answers 582 views
Problem : I want to set up the multiple setting files (e.g. Dev, Prod, ..) that include some base settings also. But unable to gain successes in my goal. Whenever I am trying to run my ./manage.py runserver I ... == "__main__": os.environ.setdefault("DJANGO_SETTINGS_MODULE", "cb.settings.development") from django.core.management import execute_from_command_line execute_from_command_line(sys.argv)
asked Dec 5, 2019 alecxe 7.5k points
0 votes
1 answer 103 views
Problem: Facing this error message: Unchecked runtime.lasterror: could not establish connection. receiving end does not exist.
asked Mar 14 Wafa Abu Yousef 6.1k points
0 votes
1 answer 2K views
Problem : I had recently uninstalled the Postgres10 and after that reinstalled the Postgres10. After that I went to run a Node, Express, React application that relies on connecting to a Postgres10 database and also communicates with it using Sequelize. Initially I was unable to ... app at in the browser. Does anyone have any idea what is going wrong? Please suggest me the solution for my error.
asked Nov 22, 2019 peterlaw 6.9k points
0 votes
1 answer 5 views
Problem: I have an issue that i am unable to init server: could not connect: connection refused can anybody solve this issue.
asked Mar 22 waseem memon 2.4k points
1 vote
1 answer 579 views
Problem: I am beginner to ruby on rails. Recently I have started learning ruby on rails in depth. I am trying to use the ruby on rails to develop my website but I am facing below error whenever I try to open the localhost. could not connect to server: Connection refused ... can&rsquo;t fix the error so now I am looking for help from ruby on rails expert to give me the quick fix for above error.
asked May 18, 2020 Martin K 6.6k points
1 vote
1 answer 50 views
Problem : I am very new to MySQL Server. I am newly assigned to this MySQL Server project. If I try to connect with the local MySQL server during my assigned test suite it shows me the below error: "Can't connect to local MySQL server through socket '/tmp/ ... that exception I can connect with my exact same parameters. I am very confused about above error. Can some expert help me in fixing it?
asked Apr 8, 2020 morrisBson 3.2k points