Received: from localhost (unknown [200.46.208.211]) by mail.postgresql.org (Postfix) with ESMTP id 408C56330BE for ; Mon, 2 Nov 2009 10:20:01 -0400 (AST) Received: from mail.postgresql.org ([200.46.204.86]) by localhost (mx1.hub.org [200.46.208.211]) (amavisd-maia, port 10024) with ESMTP id 61356-03 for ; Mon, 2 Nov 2009 14:19:42 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-bw0-f213.google.com (mail-bw0-f213.google.com [209.85.218.213]) by mail.postgresql.org (Postfix) with ESMTP id B12CE63429A for ; Mon, 2 Nov 2009 10:19:49 -0400 (AST) Received: by bwz5 with SMTP id 5so6515686bwz.3 for ; Mon, 02 Nov 2009 06:19:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:in-reply-to:references :date:message-id:subject:from:to:cc:content-type; bh=roODEGkDwYaK+hyKdvb7SJBw/mnzgvD+2OqIj+WVaMM=; b=pYU7Poyx487byl3fnJOdyzMs2hXUDrytcvSK8dIJr++ycACP4i9TlJJJ9XCQQWb8IM kOONkUyTaAra9qXirUIwLtezjNJZsi+MOgMYP3R24SIXNKoojMYADDe5S6bJHalqRUZw p7fIrgEBA4aT+8ylcJao0X6OmwMpf1eCJZf/I= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=Guiy5g4wsINZzqtGxC9ys48GLVmK8VLEcnsy+gRZkMN8cKSA9EnR5V5hspeIxAB+zA nEaDojKqeuPKDY2tUcez5b2ILmAxCIbF9Pmm2myvPBI0opyrI3lZvNGApTUqL1n0lSWa u7PQDgGSPgHbjWspOoqxomC2HnS9+awxU2UM0= MIME-Version: 1.0 Received: by 10.204.32.75 with SMTP id b11mr4010561bkd.94.1257171587039; Mon, 02 Nov 2009 06:19:47 -0800 (PST) In-Reply-To: References: Date: Mon, 2 Nov 2009 14:19:47 +0000 Message-ID: <2f4958ff0911020619yc7ed6e6u74ff6a01cb7ce98c@mail.gmail.com> Subject: Re: Problem with database performance, Debian 4gb ram ? From: =?UTF-8?Q?Grzegorz_Ja=C5=9Bkiewicz?= To: Grant Masan Cc: pgsql-performance@postgresql.org Content-Type: multipart/alternative; boundary=000325552aaade064a0477641123 X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.345 tagged_above=-10 required=5 tests=AWL=0.253, BAYES_00=-2.599, HTML_MESSAGE=0.001 X-Spam-Level: X-Archive-Number: 200911/12 X-Sequence-Number: 36180 --000325552aaade064a0477641123 Content-Type: text/plain; charset=UTF-8 On Mon, Nov 2, 2009 at 2:16 PM, Grant Masan wrote: > Hi Hi all, > > I have now readed many many forums and tried many different solutions and I > am not getting good performance to database. My server is Debian linux, with > 4gb ram, there is also java application and I am giving to that 512mb > (JAVA_OPTS) memory. In database there is now like 4milj rows. What should I > do better. > > I would rather start to look at queries performance. What's the size of db ? select pg_size_pretty(pg_database_size('yourDbName')); start logging queries, with time of execution, to see which ones are causing problems. -- GJ --000325552aaade064a0477641123 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: quoted-printable

On Mon, Nov 2, 2009 at 2:16 PM, Grant Ma= san <grant.m= assan@gmail.com> wrote:
Hi Hi all,

I have now readed many many forums and tried many different solutions and I am not getting good performance to database. My server is Debian linux, with 4gb ram, there is also java application and I am giving to that 512mb (JAVA_OPTS) memory. In database there is now like 4milj rows. What should I do better.


I would rather start to look at= queries performance.

What's the size of db ?
select pg_siz= e_pretty(pg_database_size('yourDbName'));
=C2=A0
start logging queries, with time of execution, to see which ones are causin= g problems.



--
GJ
--000325552aaade064a0477641123--