Re: Tail -f or watch for postgres

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Tue, Apr 20, 2010 at 1:20 AM, Renato Oliveira
<renato.oliveira@xxxxxxxxxxx> 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.

-- 
Sent via pgsql-admin mailing list (pgsql-admin@xxxxxxxxxxxxxx)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-admin


[Index of Archives]     [KVM ARM]     [KVM ia64]     [KVM ppc]     [Virtualization Tools]     [Spice Development]     [Libvirt]     [Libvirt Users]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite Questions]     [Linux Kernel]     [Linux SCSI]     [XFree86]

  Powered by Linux