title: Postgres connection not established after abnormal reboot
body: <p>After a memory freeze of the unit running postgresql, upon restart the connections cannot be established as</p>
  <pre><code>Is the server running locally and accepting
  connections on Unix domain socket &quot;/tmp/.s.PGSQL.5432&quot;?
  </code></pre>
  <p>A rails application can generate a <code>tmp/pid/server.pid</code> file, confirms no connections are established.  Now a manual restart with</p>
  <pre><code>pg_ctl -D /usr/local/var/postgresql@9.5  -l /usr/local/var/postgres@9.5/server.log start
  
  pg_ctl: another server might be running; trying to start server anyway
  server starting
  $ /bin/sh: /usr/local/var/postgres@9.5/server.log: No such file or directory
  
  </code></pre>
  <p>then hangs there without returning a prompt.  <code>control-c</code> needs to be invoked to get the prompt back.  Further:</p>
  <pre><code>pg_ctl -D /usr/local/var/postgresql@9.5 stop
  waiting for server to shut down............................................................... failed
  pg_ctl: server does not shut down
  </code></pre>
  <p>directory <code>/usr/local/var/postgresql@9.5</code> contains a <code>postgresql.conf</code> file although it is entirely populated by commented out lines.</p>
  <p>I also noted that directory /usr/local/var/log has two files <code>postgres.log</code> and <code>postgresql@9.5.log</code>  which are timestamped to the current minute (which is consistent with the notion of server running). The logs are <strong>huge</strong>  possibly being at the root of the problem in the first place.</p>
  <p>What is the best way to reset to reset the log files and get postgresql running properly?</p>