Re: Explicit relation name in VACUUM VERBOSE log

From: Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com>
To: Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>
Cc: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Explicit relation name in VACUUM VERBOSE log
Date: 2017-08-15 07:38:25
Message-ID: CAD21AoCdB0wDsyPOeYdu-i1k3Ugrurrnwo12yTUQvF49MH=apg@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Tue, Aug 15, 2017 at 11:14 AM, Alvaro Herrera
<alvherre(at)2ndquadrant(dot)com> wrote:
> Michael Paquier wrote:
>> On Tue, Aug 15, 2017 at 10:27 AM, Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com> wrote:
>> > Currently vacuum verbose outputs vacuum logs as follows. The first log
>> > message INFO: vacuuming "public.hoge" writes the relation name with
>> > schema name but subsequent vacuum logs output only relation name
>> > without schema name. I've encountered a situation where there are some
>> > same name tables in different schemas and the concurrent vacuum logs
>> > made me hard to distinguish tables. Is there any reasons why we don't
>> > write an explicit name in vacuum verbose logs? If not, can we add
>> > schema names to be more clearly?
>>
>> That's definitely a good idea. lazy_vacuum_rel() uses in one place
>> dbname.schname.relname for autovacuum. This is an inconsistent bit,
>> but that's not really worth changing and there is always
>> log_line_prefix = '%d'.
>
> Worth keeping in mind that INFO messages do not normally go to the
> server log, but rather only to the client. If it were a problem at the
> server side, you could also suggest adding %p to the log line prefix to
> disambiguate. Maybe the scenario where this is a real problem is
> vacuumdb -j ...

Yeah, the situation I encountered is that. Invoke vaucuumdb -j and
save its logs to check later.

Regards,

--
Masahiko Sawada
NIPPON TELEGRAPH AND TELEPHONE CORPORATION
NTT Open Source Software Center

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tomas Vondra 2017-08-15 10:04:50 Re: measuring the impact of increasing WAL segment size
Previous Message Marko Tiikkaja 2017-08-15 07:17:51 Re: INSERT .. ON CONFLICT DO SELECT [FOR ..]