0 like 0 dislike

Please log in or register to answer this question.

1 Answer

0 like 0 dislike
answered by (430 points)  

For example Assume your linux server running 4 postgres cluster so you want to create the postgres user to all cluster use below script to create user with specific privileges.

for K in {5432,5433,5434,5435}
psql -U postgres -d postgres -p $K <<DDL
CREATE USER khan IN ROLE role_name connection limit 50;
COMMENT ON ROLE khan IS 'fullname:khan mohammed';
\du+ khan 


Related questions

0 like 0 dislike
1 answer
0 like 0 dislike
1 answer
Welcome to PostgreSQL Database Discussion Forum where you can ask questions and receive answers from other members of the community. Can discuss here Oracle, Postgresql, mariadb , mySQL , AWS , Linux , MSSQL , MongoDB , Greenplum databases related queries ...etc.