1.配置postgreql 可以远程访问:

sudo vim /etc/postgresql/9.1/main/postgresql.conf

root@ubuntuserver:~# sudo vi /etc/postgresql/9.1/main/postgresql.conf
—>改变行:#listen_addresses = ‘localhost’
—>修改为:listen_addresses = ‘*’
—>改变行:#password_encryption = on
—>修改为:password_encryption = on
root@ubuntuserver:~# sudo vi /etc/postgresql/9.1/main/pg_hba.conf
—>文件末添加行:# to allow your client visiting postgresql server
—>文件末添加行:host all all 0.0.0.0 0.0.0.0 md5
root@ubuntuserver:~# sudo /etc/init.d/postgresql-9.1 restart

2.修改默认的postgres 密码

sudo -u postgres psql template1

ALTER USER postgres with encrypted password 'your_password'

3.重启POSTGRESQL服务

sudo /etc/init.d/postgresql-9.1 restart

POSTGRESQL 9.1 FATAL: password authentication failed for user "postgres"的更多相关文章

  1. pg_dump: [archiver (db)] connection to database “dbase” failed: FATAL: Peer authentication failed for user “postgres”

    "Peer authentication" means that it's comparing your database username against your Linux ...

  2. (转载)postgresql navicat 客户端连接验证失败解决方法:password authentication failed for user

    命令:su - postgres CREATE USER foo WITH PASSWORD 'secret'; ==================== 1.2个配置修改 postgresql.co ...

  3. 【解决】Git failed with a fatal error. Authentication failed for ‘http://......’

    今天在visual studio中运行项目,打算pull最新的代码的时候,报错: Git failed with a fatal error. Authentication failed for ‘h ...

  4. pgadmin3 新建服务器出现错误 Peer authentication failed for user "postgres" 的解决办法

    转自:http://blog.csdn.net/tingyuanss/article/details/43763899 用pgadmin3 新建服务器出现错误 Peer authentication ...

  5. 新建服务器出现错误 Peer authentication failed for user "postgres" 的解决办法

    用pgadmin3 新建服务器出现错误 Peer authentication failed for user "postgres" 在stackoverflow上找到答案,出现此 ...

  6. Rails: could not connect to database postgres: FATAL: Peer authentication failed for user "username"

    /var/lib/pgsql/9.2/data/pg_hba.conf 打开之后找到 local all postgres/all peer 改成 local all postgres trust 保 ...

  7. 【docker】启动docker连接数据库 出现FATAL: password authentucation failed for user "homestatead"问题

    docker可以成功启动,启动命令如下: docker run -d -p : -v `pwd`/pgdata:/var/lib/postgresql/data -e POSTGRES_USER=ho ...

  8. SecureCRT使用SSH链接出现Password Authentication Failed,Please verify that the username and password are correct的解决办法(亲测有效)

  9. linux-centos-pgsql-Ident authentication failed for user “postgres”错误出现解决方法

    首先,要找到pg_hba.conf\ -->cd /var/lib/pgsql/data -->vi pg_hba.conf 然后,将里面的配置文件修改如下: # TYPE DATABAS ...

随机推荐

  1. Python学习:python网址收集

    Python学习网址收集: 语法学习:http://www.cnblogs.com/hongten/tag/python/             http://www.liaoxuefeng.com ...

  2. screen space shadowmap unity

    unity用到了screen space shadow map 1.camera 在light pos 生成depth1 2.screen space depth2 3.根据depth1 depth2 ...

  3. (转)如何将本地git仓库中的代码上传到github

    1,  在github上新建一个仓库,比如为:CSS3Test,仓库地址为:https://github.com/hyuanyuanlisiwei/CSS3Test 2,本地git仓库中的文件项目为C ...

  4. sip

    INVITE sip:10010101402@10.7.36.70:5060 SIP/2.0 Via: SIP/2.0/UDP 10.7.36.250:5060;rport;branch=z9hG4b ...

  5. jquery操作select2控件

    (一)select2常用的操作:添加.移除.获取选中的value()与text() (1)移除事件:$("#select_id").unbind("change" ...

  6. vue - webpack.prod.conf.js

    描述:webpack打包项目时的配置文件. 命令:yarn run build 或 npm run build 打包后,生成的文件在dist文件夹下 打包后,要在服务器环境下运行!!! 关于怎样运行, ...

  7. 面向对象知识点之statickeyword的使用

    <?php /*由static定义的属性和方法称为静态成员和静态方法.static定义的属性和方法是属于类的,在对象之间共享.*/ /*比如能够通过定义一个静态变量来统计类实例化了多少个对象*/ ...

  8. iOS 滑块拼图游戏(Puzzle8)

    代码地址如下:http://www.demodashi.com/demo/11505.html 一.准备工作 先了解一个定义和定理 定义:在一个1,2,...,n的排列中,如果一对数的前后位置与大小顺 ...

  9. SSH限制ip登陆

    linux限制IP访问ssh   在/etc/hosts.allow输入   (其中192.168.10.88是你要允许登陆ssh的ip,或者是一个网段192.168.10.0/24)   sshd: ...

  10. 解疑 Numpy 中的 transpose(转置)和swapaxes(两个轴转置变换)

    1.一维和二维数据 .T等同于.transopse 2.三维及更多维数据 对于 z 轴 与 x 轴的变换 In [40]: arr = np.arange(16).reshape((2, 2, 4)) ...