| From: | Scott Marlowe <scott(dot)marlowe(at)gmail(dot)com> |
|---|---|
| To: | Renato Oliveira <renato(dot)oliveira(at)grant(dot)co(dot)uk> |
| Cc: | "pgsql-admin(at)postgresql(dot)org" <pgsql-admin(at)postgresql(dot)org> |
| Subject: | Re: Tail -f or watch for postgres |
| Date: | 2010-04-20 10:32:57 |
| Message-ID: | j2wdcc563d11004200332hf17ead27l8c21f8b3aaf17c12@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-admin |
On Tue, Apr 20, 2010 at 1:20 AM, Renato Oliveira
<renato(dot)oliveira(at)grant(dot)co(dot)uk> wrote:
> Dear all,
>
> It may sounds crazy it may not sound so crazy.
>
> I was here think are there any commands to watch new transactions rolling
> through the screen like a terminal monitor?
>
> For example, if you want to watch a log file you can execute the command;
> tail –f <logfile> or watch.
>
> This will keep the log entries rolling and being displayed on screen.
>
> Is there something similar to postgreSQL?
while true; do psql mydb -c "select * from pg_stat_activity where
current_query <>'<IDLE>'";sleep 10;done
or something like that.
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Scott Mead | 2010-04-20 12:28:08 | Re: Tail -f or watch for postgres |
| Previous Message | Renato Oliveira | 2010-04-20 07:20:56 | Tail -f or watch for postgres |