title: PostgreSQL login issue, unable to connect in Linux
body: <p>when I am trying to login to postgresql by using <code>psql -d root -U postgres</code> I am getting below error.</p>
  
  <pre><code>psql: FATAL:  Peer authentication failed for user "postgres"
  </code></pre>
  
  <p>And when typing only <code>psql</code> getting below error:</p>
  
  <pre><code>psql: FATAL:  no pg_hba.conf entry for host "[local]", user "root", database "root", SSL off
  </code></pre>
  
  <p>what I can do ? I am not able to undrstand.</p>
  
  <p>Thanks in advance</p>