pg.ddx.io pgsql-performance@postgresql.org mailing list archive
help / color / mirror / Atom feedFastest Backup & Restore for perf testing
4+ messages / 4 participants
[nested] [flat]
* Fastest Backup & Restore for perf testing
@ 2015-05-27 20:24 Wes Vaske (wvaske) <wvaske@micron.com>
2015-05-27 20:37 ` Re: Fastest Backup & Restore for perf testing Andrew Dunstan <andrew@dunslane.net>
2015-05-27 20:39 ` Re: Fastest Backup & Restore for perf testing Steve Atkins <steve@blighty.com>
0 siblings, 2 replies; 4+ messages in thread
From: Wes Vaske (wvaske) @ 2015-05-27 20:24 UTC (permalink / raw)
To: pgsql-performance
Hi,
I'm running performance tests against a PostgreSQL database (9.4) with various hardware configurations and a couple different benchmarks (TPC-C & TPC-H).
I'm currently using pg_dump and pg_restore to refresh my dataset between runs but this process seems slower than it could be.
Is it possible to do a tar/untar of the entire /var/lib/pgsql tree as a backup & restore method?
If not, is there another way to restore a dataset more quickly? The database is dedicated to the test dataset so trashing & rebuilding the entire application/OS/anything is no issue for me-there's no data for me to lose.
Thanks!
Wes Vaske | Senior Storage Solutions Engineer
Micron Technology
101 West Louis Henna Blvd, Suite 210 | Austin, TX 78728
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: Fastest Backup & Restore for perf testing
2015-05-27 20:24 Fastest Backup & Restore for perf testing Wes Vaske (wvaske) <wvaske@micron.com>
@ 2015-05-27 20:37 ` Andrew Dunstan <andrew@dunslane.net>
1 sibling, 0 replies; 4+ messages in thread
From: Andrew Dunstan @ 2015-05-27 20:37 UTC (permalink / raw)
To: Wes Vaske (wvaske) <wvaske@micron.com>; pgsql-performance
On 05/27/2015 04:24 PM, Wes Vaske (wvaske) wrote:
>
> Hi,
>
> I’m running performance tests against a PostgreSQL database (9.4) with
> various hardware configurations and a couple different benchmarks
> (TPC-C & TPC-H).
>
> I’m currently using pg_dump and pg_restore to refresh my dataset
> between runs but this process seems slower than it could be.
>
> Is it possible to do a tar/untar of the entire /var/lib/pgsql tree as
> a backup & restore method?
>
> If not, is there another way to restore a dataset more quickly? The
> database is dedicated to the test dataset so trashing & rebuilding the
> entire application/OS/anything is no issue for me—there’s no data for
> me to lose.
>
> Thanks!
>
Read all of this chapter.
<http://www.postgresql.org/docs/current/static/backup.html;
cheers
andrew
--
Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: Fastest Backup & Restore for perf testing
2015-05-27 20:24 Fastest Backup & Restore for perf testing Wes Vaske (wvaske) <wvaske@micron.com>
@ 2015-05-27 20:39 ` Steve Atkins <steve@blighty.com>
2015-05-28 17:40 ` Re: Fastest Backup & Restore for perf testing Jim Nasby <Jim.Nasby@BlueTreble.com>
1 sibling, 1 reply; 4+ messages in thread
From: Steve Atkins @ 2015-05-27 20:39 UTC (permalink / raw)
To: pgsql-performance; +Cc: Wes Vaske (wvaske) <wvaske@micron.com>
> On May 27, 2015, at 1:24 PM, Wes Vaske (wvaske) <wvaske@micron.com> wrote:
>
> Hi,
>
> I’m running performance tests against a PostgreSQL database (9.4) with various hardware configurations and a couple different benchmarks (TPC-C & TPC-H).
>
> I’m currently using pg_dump and pg_restore to refresh my dataset between runs but this process seems slower than it could be.
>
> Is it possible to do a tar/untar of the entire /var/lib/pgsql tree as a backup & restore method?
>
> If not, is there another way to restore a dataset more quickly? The database is dedicated to the test dataset so trashing & rebuilding the entire application/OS/anything is no issue for me—there’s no data for me to lose.
>
Dropping the database and recreating it from a template database with "create database foo template foo_template" is about as fast as a file copy, much faster than pg_restore tends to be.
Cheers,
Steve
--
Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance
^ permalink raw reply [nested|flat] 4+ messages in thread
* Re: Fastest Backup & Restore for perf testing
2015-05-27 20:24 Fastest Backup & Restore for perf testing Wes Vaske (wvaske) <wvaske@micron.com>
2015-05-27 20:39 ` Re: Fastest Backup & Restore for perf testing Steve Atkins <steve@blighty.com>
@ 2015-05-28 17:40 ` Jim Nasby <Jim.Nasby@BlueTreble.com>
0 siblings, 0 replies; 4+ messages in thread
From: Jim Nasby @ 2015-05-28 17:40 UTC (permalink / raw)
To: Steve Atkins <steve@blighty.com>; pgsql-performance; +Cc: Wes Vaske (wvaske) <wvaske@micron.com>
On 5/27/15 3:39 PM, Steve Atkins wrote:
>
>> On May 27, 2015, at 1:24 PM, Wes Vaske (wvaske) <wvaske@micron.com> wrote:
>>
>> Hi,
>>
>> I’m running performance tests against a PostgreSQL database (9.4) with various hardware configurations and a couple different benchmarks (TPC-C & TPC-H).
>>
>> I’m currently using pg_dump and pg_restore to refresh my dataset between runs but this process seems slower than it could be.
>>
>> Is it possible to do a tar/untar of the entire /var/lib/pgsql tree as a backup & restore method?
>>
>> If not, is there another way to restore a dataset more quickly? The database is dedicated to the test dataset so trashing & rebuilding the entire application/OS/anything is no issue for me—there’s no data for me to lose.
>>
>
> Dropping the database and recreating it from a template database with "create database foo template foo_template" is about as fast as a file copy, much faster than pg_restore tends to be.
Another possibility is filesystem snapshots, which could be even faster
than createdb --template.
--
Jim Nasby, Data Architect, Blue Treble Consulting, Austin TX
Data in Trouble? Get it in Treble! http://BlueTreble.com
--
Sent via pgsql-performance mailing list (pgsql-performance@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-performance
^ permalink raw reply [nested|flat] 4+ messages in thread
end of thread, other threads:[~2015-05-28 17:40 UTC | newest]
Thread overview: 4+ messages (download: mbox mbox.gz follow: Atom feed)
-- links below jump to the message on this page --
2015-05-27 20:24 Fastest Backup & Restore for perf testing Wes Vaske (wvaske) <wvaske@micron.com>
2015-05-27 20:37 ` Andrew Dunstan <andrew@dunslane.net>
2015-05-27 20:39 ` Steve Atkins <steve@blighty.com>
2015-05-28 17:40 ` Jim Nasby <Jim.Nasby@BlueTreble.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