Thread: database lagging
Is there any other thing running with that database? If so, I would consider a locking problem. CREATE/ALTER ROLE should never take too much time, unless there is some kind of lock in a global catalog.
Regards,
Alvaro Aguayo
Operations Manager
Open Comb Systems E.I.R.L.
From: Pepe TD Vo <pepevo@yahoo.com>
Sent: 23 July 2021 12:52
To: pgsql-admin@lists.postgresql.org
Subject: database lagging
I am doing CIS Benchmart on Postgreql 12. After alter parameters and when I tried to create a new role. It's lagging and didn't prompt out the result, until I hit the ctl C key. Even alter role. All I needed to hit ctl C key if not, it hung there for ever. Is there a way to fix it?
postgres=# create role appuser;
^CCancel request sent
CREATE ROLE
postgres=# ALTER ROLE appuser NOSUPERUSER;
^CCancel request sent
ALTER ROLE
postgres=# ALTER ROLE appuser NOREPLICATION;
^CCancel request sent
ALTER ROLE
postgres=# ALTER ROLE appuser NOCREATEROLE;
^CCancel request sent
ALTER ROLE
postgres=# ALTER ROLE appuser NOHERIT;
^CCancel request sent
ALTER ROLE
No one in this world is pure and perfect. If you avoid people for their mistakes you will be alone. So judge less, love, and forgive more.



**Live simply **Love generously **Care deeply **Speak kindly.
Is there any other thing running with that database? If so, I would consider a locking problem. CREATE/ALTER ROLE should never take too much time, unless there is some kind of lock in a global catalog.
Regards,
Alvaro Aguayo
Operations Manager
Open Comb Systems E.I.R.L.
From: Pepe TD Vo <pepevo@yahoo.com>
Sent: 23 July 2021 12:52
To: pgsql-admin@lists.postgresql.org
Subject: database lagging
I am doing CIS Benchmart on Postgreql 12. After alter parameters and when I tried to create a new role. It's lagging and didn't prompt out the result, until I hit the ctl C key. Even alter role. All I needed to hit ctl C key if not, it hung there for ever. Is there a way to fix it?
postgres=# create role appuser;
^CCancel request sent
CREATE ROLE
postgres=# ALTER ROLE appuser NOSUPERUSER;
^CCancel request sent
ALTER ROLE
postgres=# ALTER ROLE appuser NOREPLICATION;
^CCancel request sent
ALTER ROLE
postgres=# ALTER ROLE appuser NOCREATEROLE;
^CCancel request sent
ALTER ROLE
postgres=# ALTER ROLE appuser NOHERIT;
^CCancel request sent
ALTER ROLE

Is there any other thing running with that database? If so, I would consider a locking problem. CREATE/ALTER ROLE should never take too much time, unless there is some kind of lock in a global catalog.
Regards,
Alvaro Aguayo
Operations Manager
Open Comb Systems E.I.R.L.
From: Pepe TD Vo <pepevo@yahoo.com>
Sent: 23 July 2021 12:52
To: pgsql-admin@lists.postgresql.org
Subject: database lagging
I am doing CIS Benchmart on Postgreql 12. After alter parameters and when I tried to create a new role. It's lagging and didn't prompt out the result, until I hit the ctl C key. Even alter role. All I needed to hit ctl C key if not, it hung there for ever. Is there a way to fix it?
postgres=# create role appuser;
^CCancel request sent
CREATE ROLE
postgres=# ALTER ROLE appuser NOSUPERUSER;
^CCancel request sent
ALTER ROLE
postgres=# ALTER ROLE appuser NOREPLICATION;
^CCancel request sent
ALTER ROLE
postgres=# ALTER ROLE appuser NOCREATEROLE;
^CCancel request sent
ALTER ROLE
postgres=# ALTER ROLE appuser NOHERIT;
^CCancel request sent
ALTER ROLE

On Fri, 23 Jul 2021 at 23:37, Alvaro Aguayo <aaguayo@opensysperu.com> wrote:Is there any other thing running with that database? If so, I would consider a locking problem. CREATE/ALTER ROLE should never take too much time, unless there is some kind of lock in a global catalog.
I am not so sure this is lock issue? Ctrl C would not complete the command if it were a lock issue?Pepe can confirm if he sees any locks though ?Hey Pepe,Can you let us knowwhat postgres version?what psql version?what OS?also, is it possible for you to collect stack trace of the hanging process?also is it only hanging in interactive mode?psql -c 'alter role foobar superuser;'does this complete fine ?
No one in this world is pure and perfect. If you avoid people for their mistakes you will be alone. So judge less, love, and forgive more.



**Live simply **Love generously **Care deeply **Speak kindly.

On Fri, 23 Jul 2021 at 23:37, Alvaro Aguayo <aaguayo@opensysperu.com> wrote:Is there any other thing running with that database? If so, I would consider a locking problem. CREATE/ALTER ROLE should never take too much time, unless there is some kind of lock in a global catalog.
I am not so sure this is lock issue? Ctrl C would not complete the command if it were a lock issue?Pepe can confirm if he sees any locks though ?Hey Pepe,Can you let us knowwhat postgres version?what psql version?what OS?also, is it possible for you to collect stack trace of the hanging process?also is it only hanging in interactive mode?psql -c 'alter role foobar superuser;'does this complete fine ?
I'm running rh-postgresql12psql version 12.5OS RHEL 7I can run select query but lagging to create role, table,
On Jul 23, 2021, at 1:52 PM, Pepe TD Vo <pepevo@yahoo.com> wrote:I am doing CIS Benchmart on Postgreql 12. After alter parameters and when I tried to create a new role. It's lagging and didn't prompt out the result, until I hit the ctl C key. Even alter role. All I needed to hit ctl C key if not, it hung there for ever. Is there a way to fix it?postgres=# create role appuser;^CCancel request sentCREATE ROLEpostgres=# ALTER ROLE appuser NOSUPERUSER;^CCancel request sentALTER ROLEpostgres=# ALTER ROLE appuser NOREPLICATION;^CCancel request sentALTER ROLEpostgres=# ALTER ROLE appuser NOCREATEROLE;^CCancel request sentALTER ROLEpostgres=# ALTER ROLE appuser NOHERIT;^CCancel request sentALTER ROLE
I am doing CIS Benchmart on Postgreql 12. After alter parameters and when I tried to create a new role. It's lagging and didn't prompt out the result, until I hit the ctl C key. Even alter role. All I needed to hit ctl C key if not, it hung there for ever. Is there a way to fix it?postgres=# create role appuser;^CCancel request sentCREATE ROLE
Check the parameters : synchronous_mode combined with synchronous_standby_names.
postgres=# ALTER ROLE appuser NOSUPERUSER;^CCancel request sentALTER ROLEpostgres=# ALTER ROLE appuser NOREPLICATION;^CCancel request sentALTER ROLEpostgres=# ALTER ROLE appuser NOCREATEROLE;^CCancel request sentALTER ROLEpostgres=# ALTER ROLE appuser NOHERIT;^CCancel request sentALTER ROLE
No one in this world is pure and perfect. If you avoid people for their mistakes you will be alone. So judge less, love, and forgive more.



**Live simply **Love generously **Care deeply **Speak kindly.
I am doing CIS Benchmart on Postgreql 12. After alter parameters and when I tried to create a new role. It's lagging and didn't prompt out the result, until I hit the ctl C key. Even alter role. All I needed to hit ctl C key if not, it hung there for ever. Is there a way to fix it?postgres=# create role appuser;^CCancel request sentCREATE ROLE
Check the parameters : synchronous_mode combined with synchronous_standby_names.
postgres=# ALTER ROLE appuser NOSUPERUSER;^CCancel request sentALTER ROLEpostgres=# ALTER ROLE appuser NOREPLICATION;^CCancel request sentALTER ROLEpostgres=# ALTER ROLE appuser NOCREATEROLE;^CCancel request sentALTER ROLEpostgres=# ALTER ROLE appuser NOHERIT;^CCancel request sentALTER ROLE
On Sat, 24 Jul 2021 at 00:29, Pepe TD Vo <pepevo@yahoo.com> wrote:I'm running rh-postgresql12psql version 12.5OS RHEL 7I can run select query but lagging to create role, table,both in interactive and non interactive mode, it is hanging? all write based queries but not read?if only writes hang, but not reads, do you see any issues/ slowdown with writes on your storage where pg_wal resides?is it network storage or local?
No one in this world is pure and perfect. If you avoid people for their mistakes you will be alone. So judge less, love, and forgive more.



**Live simply **Love generously **Care deeply **Speak kindly.
On Sat, 24 Jul 2021 at 00:29, Pepe TD Vo <pepevo@yahoo.com> wrote:I'm running rh-postgresql12psql version 12.5OS RHEL 7I can run select query but lagging to create role, table,both in interactive and non interactive mode, it is hanging? all write based queries but not read?if only writes hang, but not reads, do you see any issues/ slowdown with writes on your storage where pg_wal resides?is it network storage or local?