WebFaction
Community site: login faq

Hi, I installed a private instance of postgres from the web interface 'control panel'. Now, I ssh in then tried running; $ psql -h localhost -p <port> postgres #where <port>is the port number of my private postgres 'app' from the control panel. And I got this error:

   psql: could not connect to server: Connection refused
    Is the server running on host "localhost" and accepting
    TCP/IP connections on port #####?

So, I did what we always do when we get errors, debug? no that's so 1980s, I jumped around on stackoverflow, google and the webfaction community forums, you get the drift. Anyway, I came across this answer on the community forums-> https://community.webfaction.com/questions/12961/postgres-server-stopped-running

So I tried; ~/webapps/<app_name>/bin/start #and I got an error that there's no such file or directory

cd ~/webapps/<app_name>

ls -l
total 0

So I can't restart my private postgres. In the answer I previously linked to one guy said you should try to run the command:

/usr/bin/pg_ctl -D /home/<username>/webapps/<app_name>/data start > /dev/null 2>&1

But that didn't help me at all. If I do;

cd /usr

ls

one of the directories listed is called pgsql-9.1: Is that my private instance, and how do I restart it. Also, why is ~/webapps/<app_name> empty? There should be a bin dir inside And why isnt psql -h localhost -p <port> postgres working?

Thanks in advance, Komu B.

This question is marked "community wiki".

asked 04 Feb '14, 10:29

komu
113
accept rate: 0%

edited 04 Feb '14, 10:32

Please open a support ticket so we can look at your account directly. Something may have happened during the install.

(04 Feb '14, 15:26) bmeyer71 ♦♦
Be the first one to answer this question!
toggle preview

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Markdown Basics

  • *italic* or _italic_
  • **bold** or __bold__
  • link:[text](http://url.com/ "title")
  • image?![alt text](/path/img.jpg "title")
  • numbered list: 1. Foo 2. Bar
  • to add a line break simply add two spaces to where you would like the new line to be.
  • basic HTML tags are also supported

Question tags:

×109
×22
×12
×4

question asked: 04 Feb '14, 10:29

question was seen: 2,005 times

last updated: 04 Feb '14, 15:26

WEBFACTION
REACH US
SUPPORT
AFFILIATE PROGRAM
LEGAL
© COPYRIGHT 2003-2019 SWARMA LIMITED - WEBFACTION IS A SERVICE OF SWARMA LIMITED
REGISTERED IN ENGLAND AND WALES 5729350 - VAT REGISTRATION NUMBER 877397162
5TH FLOOR, THE OLD VINYL FACTORY, HAYES, UB3 1HA, UNITED KINGDOM