From: Jim Nasby <Jim.Nasby@BlueTreble.com>
To: Amit Kapila <amit.kapila16@gmail.com>
Cc: Petr Jelinek <petr@2ndquadrant.com>
Cc: Andres Freund <andres@anarazel.de>
Cc: hlinnaka@iki.fi
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Bruce Momjian <bruce@momjian.us>
Cc: Sawada Masahiko <sawada.mshk@gmail.com>
Cc: Greg Stark <stark@mit.edu>
Cc: PostgreSQL-development <pgsql-hackers@postgresql.org>
Cc: Jeff Janes <jeff.janes@gmail.com>
Subject: Re: Reducing tuple overhead
Date: Fri, 24 Apr 2015 15:28:03 -0500
Message-ID: <553AA753.9010103@BlueTreble.com> (raw)
In-Reply-To: <CAA4eK1+R2f+woEsu_Woj6AgoZE6LRxYCVg5kXiC3snKSkxHmFQ@mail.gmail.com>
References: <20150423162429.GG3055@alap3.anarazel.de>
<553921B1.7080204@2ndquadrant.com>
<5539491C.6040405@BlueTreble.com>
<CAA4eK1+R2f+woEsu_Woj6AgoZE6LRxYCVg5kXiC3snKSkxHmFQ@mail.gmail.com>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
On 4/23/15 10:40 PM, Amit Kapila wrote:
> I agree with you and what I think one of the major reasons of bloat is that
> Index segment doesn't have visibility information due to which clearing of
> Index needs to be tied along with heap. Now if we can move transaction
> information at page level, then we can even think of having it in Index
> segment as well and then Index can delete/prune it's tuples on it's own
> which can reduce the bloat in index significantly and there is a benefit
> to Vacuum as well.
I don't see how putting visibility at the page level helps indexes at
all. We could already put XMIN in indexes if we wanted, but it won't
help, because...
> Now this has some downsides as well like Delete
> needs to traverse Index segment as well to Delete mark the tuples, but
> I think the upsides of reducing bloat can certainly outweigh the downsides.
... which isn't possible. You can not go from a heap tuple to an index
tuple. This has been discussed in the past. If we could do that then
vacuum would become REALLY cheap compared to today.
BTW, before actually tackling anything we should try and get more data
from Robert/Jan about where the extra 80% came from. We don't know if
it's indexes or what.
--
Jim Nasby, Data Architect, Blue Treble Consulting
Data in Trouble? Get it in Treble! http://BlueTreble.com
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-hackers@postgresql.org
Cc: Jim.Nasby@BlueTreble.com, amit.kapila16@gmail.com, petr@2ndquadrant.com, andres@anarazel.de, hlinnaka@iki.fi, robertmhaas@gmail.com, bruce@momjian.us, sawada.mshk@gmail.com, stark@mit.edu, jeff.janes@gmail.com
Subject: Re: Reducing tuple overhead
In-Reply-To: <553AA753.9010103@BlueTreble.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
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