



Likewise, the PostgreSQL database is one such open-source database type and one of the most popular management tools to operate on this database is pgAdmin. Almost every type of user persona connects to SQL Server instances on-premises or on the cloud using SSMS to perform operations suited for their role. For example, one of the most popular management and operational tool for SQL Server is SQL Server Management Studio (SSMS). What I could NOT find was the config file that sets the default values for the psql CLI command.In this article, we will show how to connect to instances of Azure Database for PostgreSQL servers using the pgAdmin tool installed locally on a user’s workstation.Įvery type of database has a community of data tools that facilitates management and operations on the database instances. (Just don't forget to /etc/init.d/postgresql restart ) I think it is certainly worth checking out before you muck about with file permissions and ownerships. Of course, you can simply remove your last set of config changes from the *.conf files, too, to test if those are the source of your problem. There are a number of useful options like this for the psql command that you can find here: so that you can test out your OWN particular misconfiguration. To test if you have done something similar, you can run When I changed it back to 5432, it worked as expected. I had changed the port from port = 5432 to port = 5433. I had mis-configured the listening port in the config file: /etc/postgresql/9.4/main/nf. It turned out that my solution was far simpler. I got this same error from trying to run psql on the command line. Sidenote: if you are using activerecord-postgresql-adapter gem, uninstall it first, then re-install pg, then install activerecord-postgresql-adapter again. After a quick pg_ctl to restart the server, both new and old projects worked. Very frustrating.until I re-installed pg gem in an pre-10.8 project ( gem uninstall pg & gem install pg) and left unix_socket_directory commented out in conf file. But if I changed conf and hard-coded var/pgsql_socket, any new projects would complain that the socket in /tmp was missing. If I left unix_socket_directory blank/commented out in nf, any projects existing prior to the upgrade would complain that the socket in /var/pgsql_socket was missing. I also had the mysterious /var/pgsql_socket_alt folder post-upgrade, but I just removed it and created /var/pgsql_socket as suggested by However, that wasn't the final solution. That was for Lion, but I was having same issues as the one in this thread after upgrading from 10.6.8 to Mountain Lion and having installed PostgreSQL via HomeBrew prior while on 10.6.8.

There appears to be no /var/pgsql_socket/ directory, let alone the /var/pgsql_socket/.s.PGSQL.5432 socket file mentioned above!?! Maybe the install of Mountain Lion wiped that out? $ ls -l /var/ | grep pgĭrwxr-x- 2 _postgres _postgres 68 Jun 20 16:39 pgsql_socket_alt Rendered users/ within layouts/application (1.3ms) Meltemi 466 0.0 0.0 2443096 3728 ? S Wed12PM 0:00.85 /usr/local/bin/postgres -D /usr/local/varpostgres -r /usr/local/var/postgres/server.logĪnd it's responding to queries (both to a test db and the development db) from a local Rails app User Load (0.2ms) SELECT "users".* FROM "users" Is the server running locally and acceptingĬonnections on Unix domain socket "/var/pgsql_socket/.s.PGSQL.5432"?īut Postgres is still clearly running: $ ps aux | grep postgres Psql: could not connect to server: No such file or directory I am unable to connect (but was able to before pre-Mountain Lion): $ psql -U rails -d myapp_development I'm not a DBA, but hoping someone can tell me how to troubleshoot this. It was installed originally via Homebrew. Recently updated my machine from Mac OS X Lion (10.7.4) to Mountain Lion (10.8) and I think it borked my PostgreSQL installation.
