title: Postgres asking for forgotten password (MacOS)
body: <p>I'm completely unable to access anything in postgres as it's asking for a password for both the default <code>postgres</code> user as well as my mac username. I don't have a password for either, and in the case of <code>postgres</code> I don't even understand why there <strong>is</strong> a password as by defualt it shouldn't have one.</p>
  <p>After running through many other answers on the subject:</p>
  <p>If I run <code>psql</code>:</p>
  <pre><code>$ psql
  Password for user &lt;MY_USERNAME&gt;:
  psql: error: could not connect to server: FATAL:  password authentication failed for user &quot;&lt;MY_USERNAME&gt;&quot;
  </code></pre>
  <p>If I run it with <code>sudo</code>:</p>
  <pre><code>$ sudo psql
  Password for user root:
  psql: error: could not connect to server: FATAL:  password authentication failed for user &quot;root&quot;
  </code></pre>
  <p>If I run it with <code>postgres</code> user:</p>
  <pre><code>$ sudo -u postgres psql
  Password for user postgres:
  psql: error: could not connect to server: FATAL:  password authentication failed for user &quot;postgres&quot;
  </code></pre>
  <p>Also in my <code>pg_hba.conf</code> all the methods are set to trust, have also tried changing to <code>ident</code> and <code>md5</code>.</p>
  <p>On the advice of @jjanes I searched for other <code>pg_hba.conf</code> files and this is what I found:</p>
  <pre><code>/usr/local/var/postgres.old/pg_hba.conf
  /usr/local/var/postgres/pg_hba.conf
  /usr/local/var/postgresql@10/pg_hba.conf
  /Library/PostgreSQL/12/data/pg_hba.conf
  </code></pre>
  <p>The last one is empty (and read only) and the other three all look like this:</p>
  <pre><code># TYPE  DATABASE        USER            ADDRESS                 METHOD
  
  # &quot;local&quot; is for Unix domain socket connections only
  local   all             all                                     trust
  # IPv4 local connections:
  host    all             all             127.0.0.1/32            trust
  # IPv6 local connections:
  host    all             all             ::1/128                 trust
  # Allow replication connections from localhost, by a user with the
  # replication privilege.
  local   replication     all                                     trust
  host    replication     all             127.0.0.1/32            trust
  host    replication     all             ::1/128                 trust
  </code></pre>
  <p>Anyone have any advice?</p>