psql.exe - password authentication failed in windows

后端 未结 3 1378
小蘑菇
小蘑菇 2021-02-05 07:57

I\'m a noob in PostgreSQL. I installed ver 9.2 on windows7. During installation it asked for password and i entered it. Now whenever i run d:\\tools\\PostgreSQL9.2\\bin\\psql.ex

3条回答
  •  无人及你
    2021-02-05 09:00

    Here is the simple solution for installation Postgresql without getting errors(cluster errors and authentication errors),i have followed below steps and i got installed postgresql sucessfully

    1. create new user in windows from controlpanel-->user accounts

    2. After logged into new user(whic u hve created) copy postrgresql(.exe) application into any directory(other than 'C') and click on the application to install(dont forget to change the installation directory to which u have copied the application file above).

    3. after completion of installaion change below configurations in postgresql.conf and pg_hba.cof

    add like below in your postgresql.conf

    listen_addresses = '*'  
    

    add like below in your pg_hba.cof

    # 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.
    # host   sameuser    postgres    127.0.0.1/32    trust
    #host    replication     postgres        ::1/128                 md5 
    

提交回复
热议问题