X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (developer.postgresql.org [64.117.224.193]) by svr1.postgresql.org (Postfix) with ESMTP id F2586B43A79 for ; Thu, 3 Jul 2003 15:58:09 +0000 (GMT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (svr1.postgresql.org [64.117.224.193]) (amavisd-new, port 10024) with ESMTP id 31053-05 for ; Thu, 3 Jul 2003 12:56:56 -0300 (ADT) Received: from www.postgresql.com (www.postgresql.com [64.117.225.209]) by svr1.postgresql.org (Postfix) with ESMTP id DE3EDB43A16 for ; Thu, 3 Jul 2003 12:56:29 -0300 (ADT) Received: from ucsns.ucs.co.za (ucs.co.za [196.23.43.2]) by www.postgresql.com (Postfix) with ESMTP id 148CFCF75B4 for ; Thu, 3 Jul 2003 07:04:33 -0300 (ADT) Received: from mailgw1.ucs.co.za (mailgw2.ucs.co.za [196.23.43.253]) by ucsns.ucs.co.za (Postfix) with ESMTP id 38E462BD84; Thu, 3 Jul 2003 12:03:48 +0200 (SAST) Received: from ct.ucs.co.za (ct.ucs.co.za [172.31.65.3]) by mailgw1.ucs.co.za (Postfix) with ESMTP id 8B33FDAC20; Thu, 3 Jul 2003 12:03:46 +0200 (SAST) Received: from ct.ucs.co.za (djm.ct.ucs.co.za [172.31.65.91]) by ct.ucs.co.za (8.11.6/8.11.6) with ESMTP id h63A3ht32041; Thu, 3 Jul 2003 12:03:46 +0200 Message-ID: <3F03FFD8.7020502@ct.ucs.co.za> Date: Thu, 03 Jul 2003 12:05:12 +0200 From: Derek Main User-Agent: Mozilla/5.0 (X11; U; Linux i686; en-US; rv:0.9.4) Gecko/20011019 Netscape6/6.2 X-Accept-Language: en-us MIME-Version: 1.0 To: Tom Lane Cc: pgsql-admin@postgresql.org Subject: Re: zero (o) return code on failure of pg_dump References: <3F019BA8.1070803@ct.ucs.co.za> <10857.1057087787@sss.pgh.pa.us> <3F02F18A.2060702@ct.ucs.co.za> <28541.1057159614@sss.pgh.pa.us> Content-Type: multipart/alternative; boundary="------------000308030905050902070902" X-Archive-Number: 200307/29 X-Sequence-Number: 9370 --------------000308030905050902070902 Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit Tom - thanks for explaining the space issue. I think I have that now and yes, we do need more space. However, you seem to be misunderstanding my issue with the return codes. Whether I run this job as postgres or as root (with the 'su' command), the job fails with the message : pg_dump: [tar archiver] could not write to tar member (wrote 158, attempted 285) With the 'su', zero is returned and with postgres running the job, one is returned. How can this be? Is this perhaps an su issue and not a pg_dump issue? Tom Lane wrote: >Derek Main writes: > >>[ pg_dump works as root, fails as postgres ] >> > >>I have since found that this is not caused by a space problem since the >>last time I ran the command, only 90% of the disk was used when it >>crashed. >> > >I think you've forgotten a standard Unix behavior: root is allowed to >use up every last block of disk space, but ordinary unprivileged users >aren't. Ordinary processes will typically start getting "out of disk >space" errors at either 90% or 95% full, depending on what your minfree >setting is for the particular filesystem. > >Reducing minfree to zero is *not* a good idea, because filesystem >performance goes to hell in a handbasket when you are down to very >small amounts of free space. It's time to buy a bigger disk, or do >some housekeeping to free up space. > > regards, tom lane > >---------------------------(end of broadcast)--------------------------- >TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org > --------------000308030905050902070902 Content-Type: text/html; charset=us-ascii Content-Transfer-Encoding: 7bit Tom - thanks for explaining the space issue. I think I have that now and yes, we do need more space. However, you seem to be misunderstanding my issue with the return codes. Whether I run this job as postgres or as root (with the 'su' command), the job fails with the message :
   
        pg_dump: [tar archiver] could not write to tar member (wrote 158, attempted 285)

With the 'su', zero is returned and with postgres running the job, one is returned. How can this be? Is this perhaps an su issue and not a pg_dump issue?

Tom Lane wrote:
Derek Main <djm@ct.ucs.co.za> writes:
[ pg_dump works as root, fails as postgres ]

I have since found that this is not caused by a space problem since the 
last time I ran the command, only 90% of the disk was used when it
crashed.

I think you've forgotten a standard Unix behavior: root is allowed to
use up every last block of disk space, but ordinary unprivileged users
aren't. Ordinary processes will typically start getting "out of disk
space" errors at either 90% or 95% full, depending on what your minfree
setting is for the particular filesystem.

Reducing minfree to zero is *not* a good idea, because filesystem
performance goes to hell in a handbasket when you are down to very
small amounts of free space. It's time to buy a bigger disk, or do
some housekeeping to free up space.

regards, tom lane

---------------------------(end of broadcast)---------------------------
TIP 1: subscribe and unsubscribe commands go to majordomo@postgresql.org


--------------000308030905050902070902--