pg.ddx.io pgsql-hackers@postgresql.org mailing list archive
help / color / mirror / Atom feed From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andreas Karlsson <andreas@proxel.se>
Cc: Andres Freund <andres@anarazel.de>
Cc: pgsql-hackers@postgresql.org
Subject: Re: Cutting initdb's runtime (Perl question embedded)
Date: Sat, 15 Apr 2017 00:07:33 -0400
Message-ID: <5807.1492229253@sss.pgh.pa.us> (raw )
In-Reply-To: <b549c8ad-f12e-aad1-9a59-b24cb3e55a17@proxel.se >
References: <30896.1492006367@sss.pgh.pa.us >
<a15e94ac-c346-5816-69ae-ec6811e32af1@proxel.se >
<972d541d-7285-53ff-ea71-dcbfd886570a@proxel.se >
<6312.1492100010@sss.pgh.pa.us >
<20170413164132.3nhobp4z4wnnvhca@alap3.anarazel.de >
<27409.1492102574@sss.pgh.pa.us >
<20170413170614.6pv2mpqiq7s6huio@alap3.anarazel.de >
<9244.1492106743@sss.pgh.pa.us >
<20170413204223.7znfwllhqmglzaam@alap3.anarazel.de >
<12002.1492206859@sss.pgh.pa.us >
<b549c8ad-f12e-aad1-9a59-b24cb3e55a17@proxel.se >
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
Andreas Karlsson <andreas@proxel.se> writes:
> Looked some at this and what take time now for me seems to mainly be
> these four things (out of a total runtime of 560 ms).
> 1. setup_conversion: 140 ms
> 2. select_default_timezone: 90 ms
> 3. bootstrap_template1: 80 ms
> 4. setup_schema: 65 ms
FWIW, you can bypass select_default_timezone by setting environment
variable TZ to a valid timezone name before calling initdb. On
my workstation, that currently cuts the time for "initdb --no-sync"
from about 1.25 sec to just about exactly 1.0 sec.
I doubt that we want all the buildfarm members to switch over to
doing that, since then we'd lose coverage of select_default_timezone.
But it's interesting to speculate about having the buildfarm script
extract the selected timezone name out of postgresql.conf after the
first initdb it does, and then set TZ for remaining tests. We surely
don't need to test select_default_timezone more than once per
buildfarm run.
regards, tom lane
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
view thread (52+ messages) latest in thread
Message-ID: <5807.1492229253@sss.pgh.pa.us>
Permalink: ../5807.1492229253@sss.pgh.pa.us/
Also on: postgresql.org/message-id/5807.1492229253@sss.pgh.pa.us
copy link · copy postgr.es
reply 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: tgl@sss.pgh.pa.us, andreas@proxel.se, andres@anarazel.de
Subject: Re: Cutting initdb's runtime (Perl question embedded)
In-Reply-To: <5807.1492229253@sss.pgh.pa.us>
* 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