pg.ddx.io  pgsql-admin@postgresql.org mailing list archive  
help / color / mirror / Atom feed
Fwd: Export vaccumdb messages
5+ messages / 4 participants
[nested] [flat]

* Fwd: Export vaccumdb messages
@ 2015-09-01 17:21 Edgar Delgado <edgdelgado@gmail.com>
  2015-09-01 17:24 ` Re: Fwd: Export vaccumdb messages Jorge Torralba <jorge.torralba@gmail.com>
  2015-09-01 18:54 ` Re: Fwd: Export vaccumdb messages Marco Nietz <pg@mnietz.de>
  0 siblings, 2 replies; 5+ messages in thread

From: Edgar Delgado @ 2015-09-01 17:21 UTC (permalink / raw)
  To: pgsql-admin

Hi.

How can I export the INFOS that generates from running vaccumdb? Tried ">>"
but I don't receive this kind of information:


INFO:  analyzing "pg_catalog.pg_foreign_data_wrapper"
INFO:  "pg_foreign_data_wrapper": scanned 0 of 0 pages, containing 0 live
rows and 0 dead rows; 0 rows in sample, 0 estimated total rows
INFO:  vacuuming "pg_catalog.pg_shseclabel"
INFO:  "pg_shseclabel": found 0 removable, 0 nonremovable row versions in 0
pages
DETAIL:  0 dead row versions cannot be removed yet.
CPU 0.00s/0.00u sec elapsed 0.00 sec.

I need to generate a log of this and send over e-mail.


Thanks,

^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Fwd: Export vaccumdb messages
  2015-09-01 17:21 Fwd: Export vaccumdb messages Edgar Delgado <edgdelgado@gmail.com>
@ 2015-09-01 17:24 ` Jorge Torralba <jorge.torralba@gmail.com>
  1 sibling, 0 replies; 5+ messages in thread

From: Jorge Torralba @ 2015-09-01 17:24 UTC (permalink / raw)
  To: Edgar Delgado <edgdelgado@gmail.com>; +Cc: pgsql-admin

you could do a vacuum verbose and | to tee

On Tue, Sep 1, 2015 at 10:21 AM, Edgar Delgado <edgdelgado@gmail.com> wrote:

>
>
> Hi.
>
> How can I export the INFOS that generates from running vaccumdb? Tried
> ">>" but I don't receive this kind of information:
>
>
> INFO:  analyzing "pg_catalog.pg_foreign_data_wrapper"
> INFO:  "pg_foreign_data_wrapper": scanned 0 of 0 pages, containing 0 live
> rows and 0 dead rows; 0 rows in sample, 0 estimated total rows
> INFO:  vacuuming "pg_catalog.pg_shseclabel"
> INFO:  "pg_shseclabel": found 0 removable, 0 nonremovable row versions in
> 0 pages
> DETAIL:  0 dead row versions cannot be removed yet.
> CPU 0.00s/0.00u sec elapsed 0.00 sec.
>
> I need to generate a log of this and send over e-mail.
>
>
> Thanks,
>
>


-- 
Thanks,

Jorge Torralba
----------------------------

Note: This communication may contain privileged or other confidential
information. If you are not the intended recipient, please do not print,
copy, retransmit, disseminate or otherwise use the information. Please
indicate to the sender that you have received this email in error and
delete the copy you received. Thank You.

^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Fwd: Export vaccumdb messages
  2015-09-01 17:21 Fwd: Export vaccumdb messages Edgar Delgado <edgdelgado@gmail.com>
@ 2015-09-01 18:54 ` Marco Nietz <pg@mnietz.de>
  2015-09-02 08:36   ` Re: Fwd: Export vaccumdb messages Wei Shan <weishan.ang@gmail.com>
  1 sibling, 1 reply; 5+ messages in thread

From: Marco Nietz @ 2015-09-01 18:54 UTC (permalink / raw)
  To: pgsql-admin

Hi,

try it like this:

vacuumdb -v > /tmp/your.log 2>&1


Best,

  Marco


Am 01.09.2015 um 19:21 schrieb Edgar Delgado:
>
>
> Hi.
>
> How can I export the INFOS that generates from running vaccumdb? Tried
> ">>" but I don't receive this kind of information:
>
>
> INFO:  analyzing "pg_catalog.pg_foreign_data_wrapper"
> INFO:  "pg_foreign_data_wrapper": scanned 0 of 0 pages, containing 0
> live rows and 0 dead rows; 0 rows in sample, 0 estimated total rows
> INFO:  vacuuming "pg_catalog.pg_shseclabel"
> INFO:  "pg_shseclabel": found 0 removable, 0 nonremovable row versions
> in 0 pages
> DETAIL:  0 dead row versions cannot be removed yet.
> CPU 0.00s/0.00u sec elapsed 0.00 sec.
>
> I need to generate a log of this and send over e-mail.
>
>
> Thanks,
>


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



^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Fwd: Export vaccumdb messages
  2015-09-01 17:21 Fwd: Export vaccumdb messages Edgar Delgado <edgdelgado@gmail.com>
  2015-09-01 18:54 ` Re: Fwd: Export vaccumdb messages Marco Nietz <pg@mnietz.de>
@ 2015-09-02 08:36   ` Wei Shan <weishan.ang@gmail.com>
  2015-09-02 13:08     ` Re: Fwd: Export vaccumdb messages Edgar Delgado <edgdelgado@gmail.com>
  0 siblings, 1 reply; 5+ messages in thread

From: Wei Shan @ 2015-09-02 08:36 UTC (permalink / raw)
  To: Marco Nietz <pg@mnietz.de>; +Cc: pgsql-admin

Hi,

Just for sharing. This is what I'm doing now.

*Crontab*
*0 0 * * * su - postgres -c /var/lib/pgsql/postgres_vacuum.sh*

*Script*
*# cat /var/lib/pgsql/postgres_vacuum.sh*
*#!/bin/bash*

*echo `date` >> /var/lib/pgsql/postgres_vacuum.log*

*ps -aef | grep 'wal sender' | grep -v 'grep wal sender' > /dev/null*

*if [ $? -eq 0 ]; then*
*        /usr/pgsql-9.2/bin/vacuumdb -avz >>
/var/lib/pgsql/postgres_vacuum.log 2>>&1*
*else*
*        echo "This is a postgres slave. Don't vacuum it!" >>
/var/lib/pgsql/postgres_vacuum.log*
*fi*

Hope this helps.

On 2 September 2015 at 02:54, Marco Nietz <pg@mnietz.de> wrote:

> Hi,
>
> try it like this:
>
> vacuumdb -v > /tmp/your.log 2>&1
>
>
> Best,
>
>  Marco
>
>
>
> Am 01.09.2015 um 19:21 schrieb Edgar Delgado:
>
>>
>>
>> Hi.
>>
>> How can I export the INFOS that generates from running vaccumdb? Tried
>> ">>" but I don't receive this kind of information:
>>
>>
>> INFO:  analyzing "pg_catalog.pg_foreign_data_wrapper"
>> INFO:  "pg_foreign_data_wrapper": scanned 0 of 0 pages, containing 0
>> live rows and 0 dead rows; 0 rows in sample, 0 estimated total rows
>> INFO:  vacuuming "pg_catalog.pg_shseclabel"
>> INFO:  "pg_shseclabel": found 0 removable, 0 nonremovable row versions
>> in 0 pages
>> DETAIL:  0 dead row versions cannot be removed yet.
>> CPU 0.00s/0.00u sec elapsed 0.00 sec.
>>
>> I need to generate a log of this and send over e-mail.
>>
>>
>> Thanks,
>>
>>
>
> --
> Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
> To make changes to your subscription:
> http://www.postgresql.org/mailpref/pgsql-admin
>



-- 
Regards,
Ang Wei Shan

^ permalink  raw  reply  [nested|flat] 5+ messages in thread

* Re: Fwd: Export vaccumdb messages
  2015-09-01 17:21 Fwd: Export vaccumdb messages Edgar Delgado <edgdelgado@gmail.com>
  2015-09-01 18:54 ` Re: Fwd: Export vaccumdb messages Marco Nietz <pg@mnietz.de>
  2015-09-02 08:36   ` Re: Fwd: Export vaccumdb messages Wei Shan <weishan.ang@gmail.com>
@ 2015-09-02 13:08     ` Edgar Delgado <edgdelgado@gmail.com>
  0 siblings, 0 replies; 5+ messages in thread

From: Edgar Delgado @ 2015-09-02 13:08 UTC (permalink / raw)
  To: Wei Shan <weishan.ang@gmail.com>; +Cc: Marco Nietz <pg@mnietz.de>; pgsql-admin

Thanks everyone!!

Trying out now! :D

2015-09-02 5:36 GMT-03:00 Wei Shan <weishan.ang@gmail.com>:

> Hi,
>
> Just for sharing. This is what I'm doing now.
>
> *Crontab*
> *0 0 * * * su - postgres -c /var/lib/pgsql/postgres_vacuum.sh*
>
> *Script*
> *# cat /var/lib/pgsql/postgres_vacuum.sh*
> *#!/bin/bash*
>
> *echo `date` >> /var/lib/pgsql/postgres_vacuum.log*
>
> *ps -aef | grep 'wal sender' | grep -v 'grep wal sender' > /dev/null*
>
> *if [ $? -eq 0 ]; then*
> *        /usr/pgsql-9.2/bin/vacuumdb -avz >>
> /var/lib/pgsql/postgres_vacuum.log 2>>&1*
> *else*
> *        echo "This is a postgres slave. Don't vacuum it!" >>
> /var/lib/pgsql/postgres_vacuum.log*
> *fi*
>
> Hope this helps.
>
> On 2 September 2015 at 02:54, Marco Nietz <pg@mnietz.de> wrote:
>
>> Hi,
>>
>> try it like this:
>>
>> vacuumdb -v > /tmp/your.log 2>&1
>>
>>
>> Best,
>>
>>  Marco
>>
>>
>>
>> Am 01.09.2015 um 19:21 schrieb Edgar Delgado:
>>
>>>
>>>
>>> Hi.
>>>
>>> How can I export the INFOS that generates from running vaccumdb? Tried
>>> ">>" but I don't receive this kind of information:
>>>
>>>
>>> INFO:  analyzing "pg_catalog.pg_foreign_data_wrapper"
>>> INFO:  "pg_foreign_data_wrapper": scanned 0 of 0 pages, containing 0
>>> live rows and 0 dead rows; 0 rows in sample, 0 estimated total rows
>>> INFO:  vacuuming "pg_catalog.pg_shseclabel"
>>> INFO:  "pg_shseclabel": found 0 removable, 0 nonremovable row versions
>>> in 0 pages
>>> DETAIL:  0 dead row versions cannot be removed yet.
>>> CPU 0.00s/0.00u sec elapsed 0.00 sec.
>>>
>>> I need to generate a log of this and send over e-mail.
>>>
>>>
>>> Thanks,
>>>
>>>
>>
>> --
>> Sent via pgsql-admin mailing list (pgsql-admin@postgresql.org)
>> To make changes to your subscription:
>> http://www.postgresql.org/mailpref/pgsql-admin
>>
>
>
>
> --
> Regards,
> Ang Wei Shan
>

^ permalink  raw  reply  [nested|flat] 5+ messages in thread


end of thread, other threads:[~2015-09-02 13:08 UTC | newest]

Thread overview: 5+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2015-09-01 17:21 Fwd: Export vaccumdb messages Edgar Delgado <edgdelgado@gmail.com>
2015-09-01 17:24 ` Jorge Torralba <jorge.torralba@gmail.com>
2015-09-01 18:54 ` Marco Nietz <pg@mnietz.de>
2015-09-02 08:36   ` Wei Shan <weishan.ang@gmail.com>
2015-09-02 13:08     ` Edgar Delgado <edgdelgado@gmail.com>

This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox