当前位置:网站首页>PostgreSQL 修改数据库用户的密码
PostgreSQL 修改数据库用户的密码
2022-07-06 13:27:00 【ac.char】
pg_hba.conf,认证设置成md5认证连接出现:
postgresql FATAL: password authentication failed for user "postgres"

编辑pg_hba.conf,将md5认证修改成trust认证,编辑后退出保存
执行pg_ctl reload加载生效
psql连接,用alter role修改密码
执行以下命令
alter role postgres with password '新密码';
查看当前postgresql 有多少用户,及对应的密码
select rolname,rolpassword from pg_authid;
退出psql
编辑pg_hba.conf,将turst认证修改成md5认证,编辑后退出保存
执行pg_ctl reload加载生效
边栏推荐
- [MySQL] trigger
- Seven original sins of embedded development
- Aike AI frontier promotion (7.6)
- [Li Kou brushing questions] one dimensional dynamic planning record (53 change exchanges, 300 longest increasing subsequence, 53 largest subarray and)
- SDL2来源分析7:演出(SDL_RenderPresent())
- 袁小林:安全不只是标准,更是沃尔沃不变的信仰和追求
- El table table - get the row and column you click & the sort of El table and sort change, El table column and sort method & clear sort clearsort
- Reflection operation exercise
- Michael smashed the minority milk sign
- JS learning notes OO create suspicious objects
猜你喜欢

50 commonly used numpy function explanations, parameters and usage examples

968 edit distance

20220211 failure - maximum amount of data supported by mongodb

This year, Jianzhi Tencent

Fastjson parses JSON strings (deserialized to list, map)

Seven original sins of embedded development

Chris LATTNER, the father of llvm: why should we rebuild AI infrastructure software

爱可可AI前沿推介(7.6)

对话阿里巴巴副总裁贾扬清:追求大模型,并不是一件坏事

3D face reconstruction: from basic knowledge to recognition / reconstruction methods!
随机推荐
In JS, string and array are converted to each other (II) -- the method of converting array into string
ICML 2022 | Flowformer: 任务通用的线性复杂度Transformer
Why do job hopping take more than promotion?
缓存更新策略概览(Caching Strategies Overview)
Quick access to video links at station B
The use method of string is startwith () - start with XX, endswith () - end with XX, trim () - delete spaces at both ends
mysql根据两个字段去重
[Li Kou brushing questions] one dimensional dynamic planning record (53 change exchanges, 300 longest increasing subsequence, 53 largest subarray and)
JS learning notes OO create suspicious objects
Aiko ai Frontier promotion (7.6)
[MySQL] trigger
嵌入式开发的7大原罪
The underlying implementation of string
Summary of cross partition scheme
Replace Internet TV set-top box application through digital TV and broadband network
Sequoia China, just raised $9billion
启动嵌入式间:资源有限的系统启动
Yyds dry inventory run kubeedge official example_ Counter demo counter
抖音将推独立种草App“可颂”,字节忘不掉小红书?
分糖果