Received: from localhost (maia-1.hub.org [200.46.204.191]) by postgresql.org (Postfix) with ESMTP id 5F4D59FB916 for ; Fri, 25 May 2007 09:30:41 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.191]) (amavisd-maia, port 10024) with ESMTP id 47386-05 for ; Fri, 25 May 2007 09:30:37 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey-1.7.4 Received: from wp045.webpack.hosteurope.de (wp045.webpack.hosteurope.de [80.237.132.52]) by postgresql.org (Postfix) with ESMTP id 0E18B9FB912 for ; Fri, 25 May 2007 09:30:38 -0300 (ADT) Received: from d088150.adsl.hansenet.de ([80.171.88.150] helo=[192.168.1.44]); authenticated by wp045.webpack.hosteurope.de running ExIM using esmtpa id 1HrYwG-0001Xo-OI; Fri, 25 May 2007 14:30:36 +0200 Message-ID: <4656D6EC.5060506@bastian-voigt.de> Date: Fri, 25 May 2007 14:30:36 +0200 From: Bastian Voigt User-Agent: Thunderbird 2.0.0.0 (X11/20070502) MIME-Version: 1.0 To: pgsql-performance@postgresql.org Subject: My quick and dirty "solution" (Re: Performance Problem with Vacuum of bytea table (PG 8.0.13)) References: <46569E6A.2060509@bastian-voigt.de> <4656BB5E.3000109@archonet.com> <4656BEF1.4050609@bastian-voigt.de> <4656C1C7.3000003@archonet.com> <4656C411.8010509@bastian-voigt.de> <4656CDC2.6030106@archonet.com> In-Reply-To: <4656CDC2.6030106@archonet.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 8bit X-bounce-key: webpack.hosteurope.de; post@bastian-voigt.de; 1180096237; 7514f765; X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.571 tagged_above=0 required=5 tests=AWL=-0.151, BAYES_50=0.001, RCVD_IN_NJABL_PROXY=0.721 X-Spam-Level: X-Archive-Number: 200705/496 X-Sequence-Number: 24886 No, this did not help. The vacuum process is still running far too long and makes everything slow. It is even worse than before, cause now the system is slow almost all the time while when vacuuming only every 3 hours it is only slow once every three hours..... I now did the following. Well, no comment..... Shellscript A: while true do psql -U $user -d $database -c "vacuum analyze verbose binary_cache" echo "Going to sleep" sleep 60 done Shellscript B: while true do ps aux > $tempfile numwaiting=`grep UPDATE.waiting $tempfile | grep -c -v grep` echo "Number of waiting updates: $numwaiting" vacuumpid=`grep VACUUM $tempfile| grep -v grep | awk '{print $2}'` echo "PID of vacuum process: $vacuumpid" if [ $numwaiting -gt 5 ] then echo "Too many waiting transactions, killing vacuum process $vacuumpid..." kill $vacuumpid fi echo "Sleeping 30 Seconds" sleep 30 done -- Bastian Voigt Neumünstersche Straße 4 20251 Hamburg telefon +49 - 40 - 67957171 mobil +49 - 179 - 4826359