pg_user或pg_shadow中:
列valuntil值为infinity或空值表示用户密码永不过期;默认为空
修改用户密码过期时间:
alter user user_name with valid until '2018-01-01 08:00:00';
修改用户密码永不过期:
alter user user_name with valid until 'infinity';
highgo=# select * from pg_user;
usename | usesysid | usecreatedb | usesuper | usecatupd | userepl | passwd | valuntil | useconfig---------+----------+-------------+----------+-----------+---------+----------+----------+-----------
highgo | 10 | t | t | t | t | ******** | |
a | 49231 | f |