Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 80D6FE0E996 for ; Thu, 10 Nov 2011 03:36:33 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 10555-08 for ; Thu, 10 Nov 2011 07:36:27 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.8.0-rc2 Received: from bunspace.com (mail.andrea-schroeder.com [64.142.76.151]) by mail.postgresql.org (Postfix) with SMTP id 2354CE0E995 for ; Thu, 10 Nov 2011 03:36:26 -0400 (AST) Received: (qmail 29328 invoked by uid 453); 10 Nov 2011 07:36:25 -0000 X-Virus-Checked: Checked by ClamAV on bunspace.com Received: from tiburon.bunspace.com (HELO tiburon.localnet) (192.168.1.4) by bunspace.com (qpsmtpd/0.83) with ESMTP; Wed, 09 Nov 2011 23:36:25 -0800 From: Uwe Schroeder Organization: OSS4U, LLC To: pgsql-admin@postgresql.org Subject: Re: error log, tablespace, wal files Date: Wed, 9 Nov 2011 23:36:24 -0800 User-Agent: KMail/1.13.5 (Linux/2.6.35-25-paeoss; KDE/4.5.1; i686; ; ) References: In-Reply-To: MIME-Version: 1.0 Content-Type: Text/Plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Message-Id: <201111092336.24858.uwe@oss4u.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.9 tagged_above=-10 required=5 tests=BAYES_00=-1.9 X-Spam-Level: X-Archive-Number: 201111/43 X-Sequence-Number: 38637 > Hello, > > 1) what is tablespace in postgres? > > 2) one more issue is that, I try to rename or delete some file in > /opt/PostgresPlus/9.0/data/base/16428/ directory. when I restart postgres > server, it start normally. but I thing this is wrong. I rename or delete > file into above directory, that means my database(having 16428 oid) is > corrupted. So How can my postgres server is started normally?? I want to > see the log file for that database corruption. Can I see it?? and where??? > and please explain me that what's going on in above case?????? > > 3) I want know about pg_xlog(wal) file creation. That means, size of > wal files and how to create that files and time stamp between creation of > two different wal files, that means when one file is created on 11:53AM, so > how much time after the second file is created?? can we set that time > stamp??? There are people here better qualified to answer this, but I'll take a shot anyways. 1) tablespaces allow you to physically store tables in different directories (meaning different disks). So if you have a table that contains gazillions of records and needs a lot of space, you could add a disk for that, mount it to some directory on your server and create a tablespace on the disk. Then you'd tell postgresql to store the large table(s) in that tablespace. 2) I think - and I certainly may be wrong here - that you will encounter the error only when postgresql tries to access data that should be in those files. It's kind of like misplacing your car keys - you'll only notice when you need them. 3) This depends a lot on your settings in postgresql.conf. To my understanding WAL files are majorly depending on the amount of data written to them and not based on a time period. If your database does mostly reads, no WAL log will be needed, thus the files allocated don't fill up quickly. If you have a lot of write operations, the files will fill quickly and once full the next file (up to number of WAL files configured) will be created. This one I'm even more fuzzy on than #2 - so someone here with more knowledge of the internals may set me right.