Re: Detect who ran DROP schema

From: Muhammad Imtiaz <imtiazpg712(at)gmail(dot)com>
To: Siraj G <tosiraj(dot)g(at)gmail(dot)com>
Cc: Pgsql-admin <pgsql-admin(at)lists(dot)postgresql(dot)org>
Subject: Re: Detect who ran DROP schema
Date: 2024-07-24 07:30:51
Message-ID: CACW1Ly1wHaB_cGh3Y4RQsXfi8uwcQKLWZ17R4F7vXs9Vpr=svQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-admin

Hi,

Please check the database server logs for the drop schema command. This
should provide details about the user and the session origin.
Configurations like* log_connections = on *and* log_statement = 'all' *are
recommended to capture the required details in db server logs.

*Muhammad Imtiaz*

*PostgreSQL Technical Support Lead *
*/ Pakistan R&D*
*Mobile: +923345072521*
*Email: imtiaz(dot)m(at)bitnine(dot)net <imtiaz(dot)m(at)bitnine(dot)net>*

On Wed, Jul 24, 2024 at 12:14 PM Siraj G <tosiraj(dot)g(at)gmail(dot)com> wrote:

> Hello -
>
> A schema was dropped from our UAT environment on 18th July. We are trying
> to find out who did. We have only one user in our environment, i.e.,
> postgres, but we are trying to identify from where the connection was
> initiated, which issued DROP schema. Can anyone help?
>
> Regards
> Siraj
>

In response to

Responses

Browse pgsql-admin by date

  From Date Subject
Next Message Laurenz Albe 2024-07-24 07:34:58 Re: Detect who ran DROP schema
Previous Message Siraj G 2024-07-24 07:14:28 Detect who ran DROP schema