Received: from sss.pgh.pa.us (unknown [192.204.191.242]) by postgresql.org (Postfix) with ESMTP id F2C54475974 for ; Tue, 16 Apr 2002 09:53:34 -0400 (EDT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.11.4/8.11.4) with ESMTP id g3GDr0F11842; Tue, 16 Apr 2002 09:53:00 -0400 (EDT) To: "Nigel J. Andrews" Cc: pgsql-admin@postgresql.org Subject: Re: Databases in memory (-->flashdrive problem) In-reply-to: References: Comments: In-reply-to "Nigel J. Andrews" message dated "Mon, 15 Apr 2002 20:20:27 +0100" Date: Tue, 16 Apr 2002 09:53:00 -0400 Message-ID: <11839.1018965180@sss.pgh.pa.us> From: Tom Lane X-Archive-Number: 200204/153 X-Sequence-Number: 4041 "Nigel J. Andrews" writes: >> Sure: keep the database on a RAM-drive (this will mean an initdb and >> data load on each bootup, hope you can stand that) and use pg_dump to >> a text file on flashdrive as your backup mechanism. Use a cron task >> to run pg_dump at whatever frequency suits you. > Wouldn't it be possible/better to just do recursive filesystem copy > between RAM drive and the flash drive? > Obviously that would be before starting postmaster and after stopping > it using cpio or whatever tool is prefered. You could do it that way. I like the pg_dump idea better, because (a) you can take a pg_dump snapshot without stopping the database, and (b) the pg_dump output will likely be smaller than the raw database files. However, the recursive copy would allow faster startup at system boot (recursive copy back to RAMdisk is probably faster than initdb + load pg_dump script --- though this assumption should be tested). You pays your money and you takes your choice... regards, tom lane