新建服务器出现错误 Peer authentication failed for user "postgres" 的解决办法
用pgadmin3 新建服务器出现错误 Peer authentication failed for user "postgres"
在stackoverflow上找到答案,出现此错误的原因是:
Peer authentication 是默认的配置,如果你的计算机用户名和你的postgres数据库名是一样的话,那么就不会出现此错误,不需要为你的数据库设置密码。
还有一种md5 authentication,它需要密码。
而我的计算机用户名和我的数据库名不一致,所以需要把Peer authentication改成md5 authentication,然后给数据库设置密码。
在哪里改?
/etc/postgresql/9.3/main/pg_hba.conf
执行命令
找到下面的一行:
local all postgres peer
改成
local all postgres md5
然后restart postgresql server
sudo service postgresql restart
新建服务器出现错误 Peer authentication failed for user "postgres" 的解决办法的更多相关文章
- pgadmin3 新建服务器出现错误 Peer authentication failed for user "postgres" 的解决办法
转自:http://blog.csdn.net/tingyuanss/article/details/43763899 用pgadmin3 新建服务器出现错误 Peer authentication ...
- 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 ...
- CAS (10) —— JBoss EAP 6.4下部署CAS时出现错误exception.message=Error decoding flow execution的解决办法
CAS (10) -- JBoss EAP 6.4下部署CAS时出现错误exception.message=Error decoding flow execution的解决办法 jboss版本: jb ...
- JVM 崩溃 Failed to write core dump解决办法 WINDOWS
JVM 崩溃 Failed to write core dump解决办法 WINDOWS MIT key words: JVM,崩溃,windows,Failed,core dump,虚拟内存 最近从 ...
- 【转载】Android Gradle Build Error:Some file crunching failed, see logs for details解决办法
Android Gradle Build Error:Some file crunching failed, see logs for details解决办法 转载请标明出处: http://www. ...
- 远程连接MySQL错误“plugin caching_sha2_password could not be loaded”的解决办法
远程连接MySQL错误"plugin caching_sha2_password could not be loaded"的解决办法 问题描述: 今天在阿里云租了一个服务器,当我用 ...
- Authentication token manipulation error报错解决办法
Authentication token manipulation error报错解决办法 #参考http://blog.163.com/junwu_lb/blog/static/1916798920 ...
- mongodb 错误 SCRAM-SHA-1 authentication failed for --转
log 日志错误信息 2018-10-24T16:14:42.244+0800 I NETWORK [initandlisten] connection accepted from 192.168.1 ...
- 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 保 ...
随机推荐
- python模块之_正则 re_configparser_logging_hashlib
正则表达式的内容放在最下面了 configparser 模块: #!/usr/bin/env python # coding:utf-8 import configparser # 专门用于操作配置文 ...
- 【转】Android-Input Getevent
https://source.android.com/devices/input/getevent Getevent getevent 工具可在设备上运行,并可提供关于输入设备和内核输入事件的实时转储 ...
- dos6章
现在开始: 在CMD使用IF /?打开IF的系统帮助(自己看我就不全部列出来了),我们会发现IF有3种基本的用法!执行批处理程序中的条件处理. IF [NOT] ERRORLEVEL number c ...
- Django REST framewor
4.1 RESTfull 4.1.1.前后端不分离 前端看到什么效果,由后端决定,前端页面看到的效果是有后端控制的 前后端耦合度很高 比较适合纯网页设计,如果有APP,还需要开发APP后端借口 4 ...
- Jquery easyUI datagrid遇到空行做判断
点击[上月]按钮直到没有数据,上月按钮禁用.并提示无数据. 最直接的思路就是datagrid('reload',{month:-1}); 可是这样,想了很多办法无法获取加载的数据. 最简单的办法: $ ...
- Windows 下Redis的部署 及key 过期事件
window下Redis部署,下载安装完成之后,进入到redis目录: 1.修改配置文件redis.windows.service.conf配置密码 requirepass myRedis (注意在R ...
- vue 项目搭建步骤
环境搭建步骤: 打开git ,运行 npm install --global vue-cli 这是安装vue的命令行 vue init webpack vue-demo 这是vue基于webpack的 ...
- Spring Boot框架的自动配置
(图片来源于网络,侵删!!!) l @RestController 因为我们例子是写一个web应用,因此写的这个注解,这个注解相当于同时添加@Controller和@ResponseBody注解 l ...
- 更改手机系统的User-Agent & okhttp
okhttp 和 volley 1. 之前用的是volley,其中一部分功能,比如User-Agent,是系统去处理的,改成okhttp库后,这部分功能需要浏览器自己处理 2. 具体区别可以参考: h ...
- 什么是混合app?
APP混合模式和原生模式的优劣 ECSHOP模板/ecshop开发中心(www.68ecshop.com) / 2014-06-27 每当你打算开发移动应用程序时,都要考虑你的应用如何创建以及如何部署 ...