Re: [PERFORM] Slow query in JDBC

2017-09-29 Thread Dave Cramer
Good catch Jeff. as for which version. We always recommend the latest version. 42.1.4 Dave Cramer da...@postgresintl.com www.postgresintl.com On 29 September 2017 at 06:44, Subramaniam C <subramaniam31...@gmail.com> wrote: > Yes you are right the timestamp which the application was

Re: [PERFORM] Slow query in JDBC

2017-09-28 Thread Dave Cramer
won't help this situation but there's still no reason not to upgrade. Dave Cramer da...@postgresintl.com www.postgresintl.com On 28 September 2017 at 12:32, Subramaniam C <subramaniam31...@gmail.com> wrote: > The JDBC version is 9.4-1201-jdbc41. > > Query :- > > select cou

Re: [PERFORM] Slow query in JDBC

2017-09-28 Thread Dave Cramer
What version of the driver are you using? The driver does not automatically use a cursor, but it does use prepared statements which can be slower. Can you provide the query and the jdbc query ? Dave Cramer da...@postgresintl.com www.postgresintl.com On 28 September 2017 at 05:59

Re: [PERFORM] degrading inser performance

2015-09-17 Thread Dave Cramer
Nobody has asked what kind of machine this is ??? Hard disks, memory, etc. What are your relevant settings in postgresql.conf ? Shared buffers, checkpoints, etc. Also how big are the inserts ? What else is this machine doing ? Is it bare hardware, or a VM ? Dave Cramer dave.cramer(at)credativ

[PERFORM] Unable to allocate 2G of shared memory on wheezy

2014-06-18 Thread Dave Cramer
kernel.shmmni = 4096 To reduce the request size [FAILently 2232950784 bytes), reduce PostgreSQL's shared memory usage, Dave Cramer

Re: [PERFORM] Unable to allocate 2G of shared memory on wheezy

2014-06-18 Thread Dave Cramer
bytes), reduce PostgreSQL's shared memory usage, perhaps by reducing shared_buffers or max_connections. ipcs -m -- Shared Memory Segments keyshmid owner perms bytes nattch status Dave Cramer On 18 June 2014 15:15, Tom Lane t...@sss.pgh.pa.us wrote

Re: [PERFORM] Unable to allocate 2G of shared memory on wheezy

2014-06-18 Thread Dave Cramer
Problem solved... a runaway process (puppet) had consumed all available real memory Dave Cramer On 18 June 2014 15:24, Dave Cramer davecra...@gmail.com wrote: 2014-06-18 13:37:15 EDT FATAL: could not map anonymous shared memory: Cannot allocate memory 2014-06-18 13:37:15 EDT HINT

[PERFORM] Testing strategies

2014-04-15 Thread Dave Cramer
about fragmentation of the WAL logs. I am looking at testing with and without the WAL logs on ZFS. Any other specific concerns ? Dave Cramer credativ ltd (Canada) 78 Zina St Orangeville, ON Canada. L9W 1E8 Office: +1 (905) 766-4091 Mobile: +1 (519) 939-0336

[PERFORM] performance regression with 9.2

2012-11-12 Thread Dave Cramer
: 2kB - Seq Scan on note_set_sources (cost=0.00..1.16 rows=16 width=794) (actual time=0.012..0.014 rows=16 loops=1) Total runtime: 829.657 ms (25 rows) Dave Cramer dave.cramer(at)credativ(dot)ca http://www.credativ.ca

Re: [PERFORM] performance regression with 9.2

2012-11-12 Thread Dave Cramer
Tom, Will try to get one ASAP. Dave Dave Cramer dave.cramer(at)credativ(dot)ca http://www.credativ.ca On Mon, Nov 12, 2012 at 3:43 PM, Tom Lane t...@sss.pgh.pa.us wrote: Dave Cramer p...@fastcrypt.com writes: This query is a couple orders of magnitude slower the first result is 9.2.1

Re: [PERFORM] JDBC 5 million function insert returning Single Transaction Lock Access Exclusive Problem

2012-08-31 Thread Dave Cramer
Dave Cramer dave.cramer(at)credativ(dot)ca http://www.credativ.ca On Thu, Aug 30, 2012 at 2:34 AM, Eileen hey_h...@yahoo.com wrote: Hi, I have written some Java code which builds a postgresql function. That function calls approximately 6 INSERT statements with a RETURNING clause. I

Re: [PERFORM] JDBC question for PG 8.3.9

2010-04-15 Thread Dave Cramer
On Wed, Apr 14, 2010 at 7:10 PM, Craig Ringer cr...@postnewspapers.com.au wrote: On 15/04/10 04:49, Dave Crooke wrote: Hi foilks I am using PG 8.3 from Java. I am considering a performance tweak which will involve holding about 150 java.sql.PreparedStatment objects open against a single

Re: [PERFORM] Explain Analyze returns faster than psql or JDBC calls.

2009-10-09 Thread Dave Cramer
You should also keep in mind that JDBC uses prepared statements, so you have to explain analyze accordingly. Dave On Thu, Oct 8, 2009 at 5:18 PM, Tom Lane t...@sss.pgh.pa.us wrote: G B g.b.co...@gmail.com writes: How can explain-analyze return significantly much faster than other means?

Re: [PERFORM] I have a fusion IO drive available for testing

2009-03-31 Thread Dave Cramer
On Fri, Mar 27, 2009 at 4:33 PM, David Rees dree...@gmail.com wrote: On Fri, Mar 27, 2009 at 10:30 AM, da...@lang.hm wrote: On Thu, 26 Mar 2009, Dave Cramer wrote: So far using dd I am seeing around 264MB/s on ext3, 335MB/s on ext2 write speed. So the question becomes what is the best

[PERFORM] I have a fusion IO drive available for testing

2009-03-26 Thread Dave Cramer
So far using dd I am seeing around 264MB/s on ext3, 335MB/s on ext2 write speed. So the question becomes what is the best filesystem for this drive? Anyone want me to run anything on it ? Dave

Re: [JDBC] [PERFORM] Query much slower when run from postgres function

2009-03-09 Thread Dave Cramer
On Mon, Mar 9, 2009 at 1:16 PM, Tom Lane t...@sss.pgh.pa.us wrote: Guillaume Smet guillaume.s...@gmail.com writes: Unnamed prepared statements are planned after binding the values, starting with 8.3, or more precisely starting with 8.3.2 as early 8.3 versions were partially broken on this

[PERFORM] Planner won't use composite index if there is an order by ????

2008-04-24 Thread Dave Cramer
Any idea why it wouldn't choose the right index ? This is 8.3 # \d battles Table public.battles Column|Type | Modifiers -+-

[PERFORM] using like in a prepare doesnt' use the right index

2008-03-27 Thread Dave Cramer
I have a query which is prepare s_18 as select uid from user_profile where name like $1::varchar and isactive=$2 order by name asc limit 250; explain analyze execute s_18 ('atxchery%','t'); QUERY PLAN

Re: [PERFORM] Benchmark: Dell/Perc 6, 8 disk RAID 10

2008-03-17 Thread Dave Cramer
On 17-Mar-08, at 2:50 PM, Justin wrote: Just out of curiosity: Last time I did research, the word seemed to be that xfs was better than ext2 or ext3. Is that not true? Why use ext2/3 at all if xfs is faster for Postgres? Criag Ext2 vs XFS on my setup there is difference in the

Re: [PERFORM] Benchmark: Dell/Perc 6, 8 disk RAID 10

2008-03-16 Thread Dave Cramer
On 16-Mar-08, at 2:19 AM, Justin wrote: I decided to reformat the raid 10 into ext2 to see if there was any real big difference in performance as some people have noted here is the test results please note the WAL files are still on the raid 0 set which is still in ext3 file system

Re: [PERFORM] Benchmark: Dell/Perc 6, 8 disk RAID 10

2008-03-16 Thread Dave Cramer
On 16-Mar-08, at 3:04 PM, Craig James wrote: Dave Cramer wrote: On 16-Mar-08, at 2:19 AM, Justin wrote: I decided to reformat the raid 10 into ext2 to see if there was any real big difference in performance as some people have noted here is the test results please note the WAL files

Re: [PERFORM] how many index can have????

2008-03-11 Thread Dave Cramer
On 11-Mar-08, at 8:28 AM, petchimuthu lingam wrote: I have one table with 30 fields, i have more then 60 million records, if i use more no of indexes will it affect the insertion performance? and select performance? Yes, and yes, but without more information about what you are trying to

Re: [PERFORM] Why the difference in plans ?

2008-03-07 Thread Dave Cramer
On 6-Mar-08, at 9:30 PM, Stephen Denne wrote: The strange thing of course is that the data is exactly the same for both runs, the tables have not been changed between runs, and I did them right after another. Even more strange is that the seq scan is faster than the index scan. It is not

Re: [PERFORM] Why the difference in plans ?

2008-03-07 Thread Dave Cramer
Josh, On 6-Mar-08, at 12:26 PM, Josh Berkus wrote: Dave, Below I have two almost identical queries. Strangely enough the one that uses the index is slower ??? My first guess would be that records are highly correlated by DOB and not at all by name. However, it would help if you

Re: [PERFORM] count * performance issue

2008-03-06 Thread Dave Cramer
On 6-Mar-08, at 1:43 AM, sathiya psql wrote: is there any way to explicitly force the postgres to use index scan If you want to count all the rows in the table there is only one way to do it (without keeping track yourself with a trigger ); a seq scan. An index will not help you. The

Re: [PERFORM] count * performance issue

2008-03-06 Thread Dave Cramer
Hi, On 6-Mar-08, at 6:58 AM, sathiya psql wrote: The only thing that is going to help you is really fast disks, and more memory, and you should consider moving to 8.3 for all the other performance benefits. Is 8.3 is a stable version or what is the latest stable version of postgres ?? Yes

Re: [PERFORM] Why the difference in plans ?

2008-03-06 Thread Dave Cramer
On 6-Mar-08, at 5:10 PM, Stephen Denne wrote: Dave Cramer wrote: I have two almost identical queries. Strangely enough the one that uses the index is slower ??? The index scan is being used so that it can retrieve the rows in the name order. It expects that if it was to retrieve every

Re: [PERFORM] PostgreSQL performance on a virtual host

2008-03-05 Thread Dave Cramer
Hi, I've run it on xen. works OK. Course this is all predicated upon your expectations. If you expect it to be as fast as a dedicated machine, you will be dissapointed. Dave On 5-Mar-08, at 3:54 AM, Moritz Onken wrote: We have very good experiences with openVZ as virtualizer. Since it's

[PERFORM] Why the difference in plans ?

2008-03-05 Thread Dave Cramer
Below I have two almost identical queries. Strangely enough the one that uses the index is slower ??? explain analyze select uid from user_profile where lower(firstname)='angie' and extract(year from age('2008-02-26 02:50:31.382', dob)) = 18 and extract(year from age('2008-02-26

Re: [PERFORM] Question about shared_buffers and cpu usage

2008-02-21 Thread Dave Cramer
On 21-Feb-08, at 12:13 AM, bh yuan wrote: Hi I am using Postgres8.3 on 8G memory , Xeon X5355 Quad Core x 2 processer RH5 machine with 10G data. (with some table which have about 2,000,000~ 5,000,000 rows ) I have two quesion. 1. how to set the shared_buffers and other postgresql.conf

Re: [PERFORM] 4s query want to run faster

2008-02-21 Thread Dave Cramer
On 21-Feb-08, at 6:16 PM, Scott Marlowe wrote: On Thu, Feb 21, 2008 at 4:59 PM, Mark Kirkwood [EMAIL PROTECTED] wrote: The other parameter you might want to look at is effective_cache_size - increasing it will encourage index use. On a machine with 16GB the default is probably too small

Re: [PERFORM] 7 hrs for a pg_restore?

2008-02-19 Thread Dave Cramer
On 19-Feb-08, at 1:12 PM, Joshua D. Drake wrote: -BEGIN PGP SIGNED MESSAGE- Hash: SHA1 On Tue, 19 Feb 2008 13:03:58 -0500 Douglas J Hunley [EMAIL PROTECTED] wrote: I spent a whopping seven hours restoring a database late Fri nite for a client. We stopped the application, ran pg_dump

Re: [PERFORM] 7 hrs for a pg_restore?

2008-02-19 Thread Dave Cramer
shared buffers is *way* too small as is effective cache set them to 2G/6G respectively. Dave ---(end of broadcast)--- TIP 5: don't forget to increase your free space map settings

Re: [PERFORM] 7 hrs for a pg_restore?

2008-02-19 Thread Dave Cramer
On 19-Feb-08, at 2:35 PM, Douglas J Hunley wrote: On Tuesday 19 February 2008 14:28:54 Dave Cramer wrote: shared buffers is *way* too small as is effective cache set them to 2G/6G respectively. Dave pardon my ignorance, but is this in the context of a restore only? or 'in general

Re: [PERFORM] Example web access to Postgres DB

2008-02-17 Thread Dave Cramer
On 17-Feb-08, at 10:18 AM, Bill Moran wrote: Mohamed Ali JBELI [EMAIL PROTECTED] wrote: Hi members I am looking for an example of a web application (WAR) which executea a Postgres actions. This aims to test the performance of Postgres in Web mode. I shall be grateful if someone gives

Re: [PERFORM] Dell Perc/6

2008-02-13 Thread Dave Cramer
On 13-Feb-08, at 5:02 AM, Tore Halset wrote: Hello. I think I started that discussion. We ended up buying a Dell 2900 with PERC 6/i and 10 * 145GB SAS 3,5 15KRpm discs. 6 of the SAS discs are in a raid 10 for the database, 2 in a mirror for the wal and the last 2 in a mirror for the OS.

[PERFORM] difference between a unique constraint and a unique index ???

2007-11-12 Thread Dave Cramer
In order to get like queries to use an index with database initialized with a UTF-8 character set I added a unique index to a table with a varchar_pattern_ops This table already had a unique constraint on the column so I dropped the unique constraint. I can't give exact measurements

Re: [PERFORM] difference between a unique constraint and a unique index ???

2007-11-12 Thread Dave Cramer
On 12-Nov-07, at 9:56 AM, Alvaro Herrera wrote: Dave Cramer wrote: In order to get like queries to use an index with database initialized with a UTF-8 character set I added a unique index to a table with a varchar_pattern_ops This table already had a unique constraint on the column so I

Re: [PERFORM] difference between a unique constraint and a unique index ???

2007-11-12 Thread Dave Cramer
On 12-Nov-07, at 11:37 AM, Tom Lane wrote: Alvaro Herrera [EMAIL PROTECTED] writes: Well, AFAIK the index with varchar_pattern_ops is used for LIKE queries, whereas the other one is going to be used for = queries. So you need to keep both indexes. Given the current definition of text

[PERFORM] Attempting to disable count triggers on cleanup

2007-09-25 Thread Dave Cramer
I have a database that we want to keep track of counts of rows. We have triggers on the rows which increment, and decrement a count table. In order to speed up deleting many rows we have added the following if user != 'mocospace_cleanup' then

Re: [PERFORM] Attempting to disable count triggers on cleanup

2007-09-25 Thread Dave Cramer
hubert depesz lubaczewski wrote: On Tue, Sep 25, 2007 at 07:08:42AM -0400, Dave Cramer wrote: ERROR: deadlock detected DETAIL: Process 23063 waits for ExclusiveLock on tuple (20502,48) of relation 48999028 of database 14510214; blocked by process 23110. Process 23110 waits for ShareLock

Re: [PERFORM] Dell Hardware Recommendations

2007-08-13 Thread Dave Cramer
On 13-Aug-07, at 9:50 AM, Vivek Khera wrote: On Aug 10, 2007, at 4:36 PM, Merlin Moncure wrote: I'm not so sure I agree. They are using LSI firmware now (and so is everyone else). The servers are well built (highly subjective, I admit) and configurable. I have had some bad experiences

[PERFORM] best use of an EMC SAN

2007-07-11 Thread Dave Cramer
Assuming we have 24 73G drives is it better to make one big metalun and carve it up and let the SAN manage the where everything is, or is it better to specify which spindles are where. Currently we would require 3 separate disk arrays. one for the main database, second one for WAL logs,

Re: [PERFORM] best use of an EMC SAN

2007-07-11 Thread Dave Cramer
On 11-Jul-07, at 10:05 AM, Gregory Stark wrote: Dave Cramer [EMAIL PROTECTED] writes: Assuming we have 24 73G drives is it better to make one big metalun and carve it up and let the SAN manage the where everything is, or is it better to specify which spindles are where. This is quite

Re: [PERFORM] best use of an EMC SAN

2007-07-11 Thread Dave Cramer
On 11-Jul-07, at 2:35 PM, Greg Smith wrote: On Wed, 11 Jul 2007, Jim Nasby wrote: I suppose an entirely in-memory database might be able to swamp a 2 drive WAL as well. You can really generate a whole lot of WAL volume on an EMC SAN if you're doing UPDATEs fast enough on data that is

Re: [PERFORM] How much ram is too much

2007-06-14 Thread Dave Cramer
Hi Andrew On 11-Jun-07, at 11:34 AM, Andrew Sullivan wrote: On Mon, Jun 11, 2007 at 11:09:42AM -0400, Dave Cramer wrote: and set them to anything remotely close to 128GB. Well, we'd give 25% of it to postgres, and the rest to the OS. Are you quite sure that PostgreSQL's management

Re: [PERFORM] How much ram is too much

2007-06-11 Thread Dave Cramer
Actually this one is an opteron, so it looks like it's all good. Dave On 8-Jun-07, at 3:41 PM, Guy Rouillier wrote: Dave Cramer wrote: It's an IBM x3850 using linux redhat 4.0 I had to look that up, web site says it is a 4-processor, dual-core (so 8 cores) Intel Xeon system. It also says

Re: [PERFORM] How much ram is too much

2007-06-11 Thread Dave Cramer
On 10-Jun-07, at 11:11 PM, Jim Nasby wrote: On Jun 8, 2007, at 11:31 AM, Dave Cramer wrote: Is it possible that providing 128G of ram is too much ? Will other systems in the server bottleneck ? Providing to what? PostgreSQL? The OS? My bet is that you'll run into issues with how

Re: [PERFORM] How much ram is too much

2007-06-11 Thread Dave Cramer
Hi Andrew On 11-Jun-07, at 11:34 AM, Andrew Sullivan wrote: On Mon, Jun 11, 2007 at 11:09:42AM -0400, Dave Cramer wrote: and set them to anything remotely close to 128GB. Well, we'd give 25% of it to postgres, and the rest to the OS. Are you quite sure that PostgreSQL's management

[PERFORM] How much ram is too much

2007-06-08 Thread Dave Cramer
Is it possible that providing 128G of ram is too much ? Will other systems in the server bottleneck ? Dave ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq

Re: [PERFORM] How much ram is too much

2007-06-08 Thread Dave Cramer
It's an IBM x3850 using linux redhat 4.0 On 8-Jun-07, at 12:46 PM, Guy Rouillier wrote: Dave Cramer wrote: Is it possible that providing 128G of ram is too much ? Will other systems in the server bottleneck ? What CPU and OS are you considering? -- Guy Rouillier

Re: [OT] Re: [PERFORM] How much ram is too much

2007-06-08 Thread Dave Cramer
On 8-Jun-07, at 2:10 PM, Joshua D. Drake wrote: Zoltan Boszormenyi wrote: Dave Cramer írta: It's an IBM x3850 using linux redhat 4.0 Isn't that a bit old? I have a RedHat 4.2 somewhere that was bundled with Applixware 3. :-) He means redhat ES/AS 4 I assume. Yes AS4 J

[PERFORM] postgresql running on a virtual cluster

2007-06-04 Thread Dave Cramer
Does anyone have any experience running pg on multiple IBM 3950's set up as a single machine ? Dave ---(end of broadcast)--- TIP 1: if posting/reading through Usenet, please send an appropriate subscribe-nomail command to [EMAIL PROTECTED]

[PERFORM] PITR performance costs

2007-05-28 Thread Dave Cramer
Since PITR has to enable archiving does this not increase the amount of disk I/O required ? Dave ---(end of broadcast)--- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq

Re: [PERFORM] PITR performance costs

2007-05-28 Thread Dave Cramer
Heikki, Don't the archived logs have to be copied as well as the regular WAL logs get recycled ? Dave On 28-May-07, at 12:31 PM, Heikki Linnakangas wrote: Dave Cramer wrote: Since PITR has to enable archiving does this not increase the amount of disk I/O required ? There's

Re: [PERFORM] 500 requests per second

2007-05-21 Thread Dave Cramer
* set reasonable statement timeout * backup with pitr. pg_dump is a headache on extremely busy servers. Where do you put your pitr wal logs so that they don't take up extra I/O ? * get good i/o system for your box. start with 6 disk raid 10 and go from there. * spend some time reading

Re: [PERFORM] Intermitent slow queries

2007-05-02 Thread Dave Cramer
On 2-May-07, at 11:24 AM, Parks, Aaron B. wrote: My pg 8.1 install on an AMD-64 box (4 processors) with 9 gigs of ram running RHEL4 is acting kind of odd and I thought I would see if anybody has any hints. I have Java program using postgresql-8.1-409.jdbc3.jar to connect over the

Re: [PERFORM] What`s wrong with JFS configuration?

2007-04-25 Thread Dave Cramer
On 25-Apr-07, at 4:54 AM, Heikki Linnakangas wrote: Paweł Gruszczyński wrote: To test I use pgBench with default database schema, run for 25, 50, 75 users at one time. Every test I run 5 time to take average. Unfortunetly my result shows that ext is fastest, ext3 and jfs are very simillar.

Re: [PERFORM] Foreign Key Deadlocking

2007-04-19 Thread Dave Cramer
Hi Csaba, I have a similar problem. In an attempt to avoid the overhead of select count(*) from mailbox where uid = somuid I've implemented triggers on insert and delete. So there is a user table which refers to to an inbox table, so when people insert into the inbox there is an RI

Re: [PERFORM] High Load on Postgres 7.4.16 Server

2007-04-05 Thread Dave Cramer
On 5-Apr-07, at 3:33 PM, John Allgood wrote: The hard thing about running multiple postmasters is that you have to tune each one separate. Most of the databases I have limited the max- connections to 30-50 depending on the database. What would reasonable values for effective_cache_size and

Re: [PERFORM] High Load on Postgres 7.4.16 Server

2007-04-05 Thread Dave Cramer
] On Behalf Of Dave Cramer Sent: Thursday, April 05, 2007 4:01 PM To: John Allgood Cc: 'Jeff Frost'; pgsql-performance@postgresql.org Subject: Re: [PERFORM] High Load on Postgres 7.4.16 Server On 5-Apr-07, at 3:33 PM, John Allgood wrote: The hard thing about running multiple postmasters is that you

Re: [PERFORM] Scaling SELECT:s with the number of disks on a stripe

2007-04-04 Thread Dave Cramer
On 4-Apr-07, at 2:01 AM, Peter Schuller wrote: Hello, The next question then is whether anything in your postgres configuration is preventing it getting useful performance from the OS. What settings have you changed in postgresql.conf? The only options not commented out are the

Re: [PERFORM] scalablility problem

2007-04-01 Thread Dave Cramer
I may have missed this but have you tuned your postgresql configuration ? 8.2 tuning guidelines are significantly different than 7.3 Dave On 1-Apr-07, at 1:51 PM, Xiaoning Ding wrote: I repeated the test again. It took 0.92 second under 8.2.3. I checked system load using top and ps. There

Re: [PERFORM] Optimization postgresql 8.1.4 FC 6 X64 ?

2007-03-24 Thread Dave Cramer
I also think there have been changes in pgbench itself. Make sure you run the same pgbench on both servers. Dave On 24-Mar-07, at 6:44 AM, Heikki Linnakangas wrote: amrit angsusingh wrote: I try to change my database server from the older one ie. 2Cpu Xeon 2.4 32 bit 4Gb SDram Hdd SCSI RAID

Re: [PERFORM] SATA RAID: Promise vs. 3ware

2007-03-20 Thread Dave Cramer
On 20-Mar-07, at 9:23 AM, Ireneusz Pluta wrote: Hello all, I sent a similar post to a FreeBSD group, but thought I'd might try here too. I am completing a box for PostgreSQL server on FreeBSD. Selecting a RAID controller I decided to go with 3ware SE9650-16, following good opinions

Re: [PERFORM] SATA RAID: Promise vs. 3ware

2007-03-20 Thread Dave Cramer
On 20-Mar-07, at 1:53 PM, Benjamin Arai wrote: This is a little biased but I would stay away from areca only because they have fans on the card. At some point down the line that card is going to die. When it does there is really no telling what it will do to your data. I personally use

Re: [PERFORM] [JDBC] does prepareThreshold work? forced to use old driver

2007-02-26 Thread Dave Cramer
On 26-Feb-07, at 11:12 AM, Gene wrote: hi! I've been having some serious performance issues with postgresql8.2/hibernate/jdbc due to postgres reusing bad cached query plans. It doesn't look at the parameter values and therefore does not use any partial indexes. After trying to set

Re: [PERFORM] Tuning

2007-01-26 Thread Dave Cramer
On 26-Jan-07, at 6:28 AM, John Parnefjord wrote: Hi! I'm planning to move from mysql to postgresql as I believe the latter performs better when it comes to complex queries. The mysql database that I'm running is about 150 GB in size, with 300 million rows in the largest table. We do quite a

Re: [PERFORM] PG8.2.1 choosing slow seqscan over idx scan

2007-01-17 Thread Dave Cramer
On 17-Jan-07, at 9:37 AM, Jeremy Haile wrote: I still keep wondering if this table is bloated with dead tuples. Even if you vacuum often if there's a connection with an idle transaction, the tuples can't be reclaimed and the table would continue to grow. I used to vacuum once an hour,

Re: [PERFORM] Configuration Advice

2007-01-17 Thread Dave Cramer
On 17-Jan-07, at 3:41 PM, Steve wrote: Hey there; I've been lurking on this list awhile, and I've been working with postgres for a number of years so I'm not exactly new to this. But I'm still having trouble getting a good balance of settings and I'd like to see what other people

Re: [PERFORM]

2007-01-14 Thread Dave Cramer
On 14-Jan-07, at 7:31 AM, Rolf Østvik (HA/EXA) wrote: 1234567890123456789012345678901234567890123456789012345678901234567890 1234567890 00112233445566 77 I have been trying to change a many parameters on server versions 7.4.15,

Re: [PERFORM] Problem with grouping, uses Sort and GroupAggregate, HashAggregate is better(?)

2007-01-14 Thread Dave Cramer
On 14-Jan-07, at 10:34 AM, Rolf Østvik (HA/EXA) wrote: Computer: Dell PowerEdge 2950 openSUSE Linux 10.1 Intel(R) Xeon 3.00GHz 4GB memory xfs filesystem on SAS disks -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf

Re: [PERFORM] Performance of Parser?

2007-01-13 Thread Dave Cramer
On 13-Jan-07, at 7:24 PM, Tom Lane wrote: Jignesh Shah [EMAIL PROTECTED] writes: The appserver is basically using bunch of prepared statements that the server should be executing directly without doing the parsing again. Better have another look at that theory, because you're clearly

Re: [PERFORM] Large table performance

2007-01-12 Thread Dave Cramer
On 12-Jan-07, at 7:31 PM, Mark Dobbrow wrote: Hello - I have a fairly large table (3 million records), and am fetching 10,000 non-contigous records doing a simple select on an indexed column ie select grades from large_table where teacher_id = X This is a test database, so the number

Re: [PERFORM] Horribly slow query/ sequential scan

2007-01-09 Thread Dave Cramer
On 9-Jan-07, at 7:50 AM, Nörder-Tuitje, Marcus wrote: Forget abount IN. Its horribly slow. I think that statement above was historically correct, but is now incorrect. IN has been optimized quite significantly since 7.4 Dave try : select w.appid, w.rate,

Re: [PERFORM] High update activity, PostgreSQL vs BigDBMS

2007-01-07 Thread Dave Cramer
On 6-Jan-07, at 11:32 PM, Guy Rouillier wrote: Dave Cramer wrote: The box has 3 GB of memory. I would think that BigDBMS would be hurt by this more than PG. Here are the settings I've modified in postgresql.conf: As I said you need to set shared_buffers to at least 750MB

Re: [PERFORM] High update activity, PostgreSQL vs BigDBMS

2007-01-05 Thread Dave Cramer
On 5-Jan-07, at 9:51 PM, Guy Rouillier wrote: I've got back access to my test system. I ran another test run with the same input data set. This time I put pg_xlog on a different RAID volume (the unused one that I suspect is a software RAID), and I turned fsync=off in postgresql.conf. I

Re: [PERFORM] Worse perfomance on 8.2.0 than on 7.4.14

2006-12-31 Thread Dave Cramer
On 31-Dec-06, at 6:33 AM, Rolf Østvik wrote: Hi I have a simple query which uses 32ms on 7.4.14 and 1015ms on 8.2.0. I guess 7.4.14 creates a better execution plan than 8.2.0 for this query but i don't know how to get it to select a better one. Explain analyse output will be found near

Re: [PERFORM] High update activity, PostgreSQL vs BigDBMS

2006-12-28 Thread Dave Cramer
Guy, Did you tune postgresql ? How much memory does the box have? Have you tuned postgresql ? Dave On 28-Dec-06, at 12:46 AM, Guy Rouillier wrote: I don't want to violate any license agreement by discussing performance, so I'll refer to a large, commercial PostgreSQL- compatible DBMS

Re: [PERFORM] Postgresql Configutation and overflow

2006-12-28 Thread Dave Cramer
Hi, On 28-Dec-06, at 8:58 PM, fabrix peñuelas wrote: Good day, I have been reading about the configuration of postgresql, but I have a server who does not give me the performance that should. The tables are indexed and made vacuum regularly, i monitor with top, ps and pg_stat_activity

Re: [PERFORM] New to PostgreSQL, performance considerations

2006-12-11 Thread Dave Cramer
On 11-Dec-06, at 5:36 AM, Daniel van Ham Colchete wrote: Hi Dave, On 12/11/06, Dave Cramer [EMAIL PROTECTED] wrote: Hi Daniel On 10-Dec-06, at 8:02 PM, Daniel van Ham Colchete wrote: Hi Gene, at my postgresql.conf, the only non-comented lines are: fsync = off This can, and will result

Re: [PERFORM] Locking in PostgreSQL?

2006-12-06 Thread Dave Cramer
Unless you specifically ask for it postgresql doesn't lock any rows when you update data. Dave On 6-Dec-06, at 2:04 AM, Joost Kraaijeveld wrote: Does PostgreSQL lock the entire row in a table if I update only 1 column? -- Groeten, Joost Kraaijeveld Askesis B.V. Molukkenstraat 14 6524NB

Re: [PERFORM] Locking in PostgreSQL?

2006-12-06 Thread Dave Cramer
On 6-Dec-06, at 8:20 AM, Jens Schipkowski wrote: On Wed, 06 Dec 2006 13:29:37 +0100, Dave Cramer [EMAIL PROTECTED] wrote: Unless you specifically ask for it postgresql doesn't lock any rows when you update data. Thats not right. UPDATE will force a RowExclusiveLock to rows matching

Re: [PERFORM] Configuration settings for 32GB RAM server

2006-12-04 Thread Dave Cramer
On 4-Dec-06, at 12:10 PM, Mark Lonsdale wrote: Hi We are migrating our Postgres 7.3.4 application to postgres 8.1.5 and also moving it to a server with a much larger hardware configuration as well.The server will have the following specification. - 4 physical CPUs

Re: [PERFORM] shared_buffers 284263 on OS X

2006-11-18 Thread Dave Cramer
Brian, On 16-Nov-06, at 7:03 PM, Brian Wipf wrote: I'm trying to optimize a PostgreSQL 8.1.5 database running on an Apple G5 Xserve (dual G5 2.3 GHz w/ 8GB of RAM), running Mac OS X 10.4.8 Server. The queries on the database are mostly reads, and I know a larger shared memory allocation

Re: [PERFORM] Jdbc/postgres performance

2006-10-22 Thread Dave Cramer
On 17-Oct-06, at 3:05 PM, Behl, Rohit ((Infosys)) wrote: HiWe are facing performance problems in postgres while executing a query. When I execute this query on the server it takes 5-10 seconds. Also I get good performance while executing this query from my code in java with the hard codes values.

Re: [PERFORM] New hardware thoughts

2006-10-20 Thread Dave Cramer
Ben, On 20-Oct-06, at 3:49 AM, Ben Suffolk wrote: Hello all, I am currently working out the best type of machine for a high volume pgsql database that I going to need for a project. I will be purchasing a new server specifically for the database, and it won't be running any other

Re: [PERFORM] Opteron vs. Xeon benchmark

2006-09-23 Thread Dave Cramer
On 23-Sep-06, at 9:00 AM, Guido Neitzer wrote: I find the benchmark much more interesting in comparing PostgreSQL to MySQL than Intel to AMD. It might be as biased as other benchmarks but it shows clearly something that a lot of PostgreSQL user always thought: MySQL gives up on concurrency ...

Re: [PERFORM] Opteron vs. Xeon benchmark

2006-09-23 Thread Dave Cramer
On 23-Sep-06, at 9:49 AM, Guido Neitzer wrote: On 9/23/06, Dave Cramer [EMAIL PROTECTED] wrote: 1) The database fits entirely in memory, so this is really only testing CPU, not I/O which should be taken into account IMO I don't think this really is a reason that MySQL broke down on ten

Re: [PERFORM] sql-bench

2006-09-14 Thread Dave Cramer
Have you tuned postgresql ? You still haven't told us what the machine is, or the tuning parameters. If you follow Merlin's links you will find his properly tuned postgres out performs mysql in every case. --dc-- On 14-Sep-06, at 2:55 AM, yoav x wrote: You can use the test with InnoDB by

Re: [PERFORM] Vacuums on large busy databases

2006-09-14 Thread Dave Cramer
On 14-Sep-06, at 11:23 AM, Francisco Reyes wrote: My setup: Freebsd 6.1 Postgresql 8.1.4 Memory: 8GB SATA Disks Raid 1 10 spindles (2 as hot spares) 500GB disks (16MB buffer), 7200 rpm Raid 10 Raid 2 4 spindles 150GB 10K rpm disks Raid 10 shared_buffers = 1 shared buffers should be

Re: [PERFORM] Vacuums on large busy databases

2006-09-14 Thread Dave Cramer
Francisco On 14-Sep-06, at 1:36 PM, Francisco Reyes wrote: Dave Cramer writes: What is effective_cache set to ? Increasing this seems to have helped significantly a web app. Load times seem magnitudes faster. Increased it to effective_cache_size = 12288 # 96MB What is a reasonable

Re: [PERFORM] Vacuums on large busy databases

2006-09-14 Thread Dave Cramer
Francisco On 14-Sep-06, at 4:30 PM, Francisco Reyes wrote: Dave Cramer writes: What is a reasonable number? I estimate I have at least 1 to 2 GB free of memory. You are using 6G of memory for something else ? Right now adding up from ps the memory I have about 2GB. Have an occassional

Re: [PERFORM] Vacuums on large busy databases

2006-09-14 Thread Dave Cramer
On 14-Sep-06, at 7:50 PM, Francisco Reyes wrote: Dave Cramer writes: personally, I'd set this to about 6G. This doesn't actually consume memory it is just a setting to tell postgresql how much memory is being used for cache and kernel buffers Gotcha. Will increase further. regarding

Re: [PERFORM] Poor performance on seq scan

2006-09-13 Thread Dave Cramer
On 13-Sep-06, at 6:16 AM, Laszlo Nagy wrote: I have had extremely bad performance historically with onboard SATA chipsets on Linux. The one exception has been with the Intel based chipsets (not the CPU, the I/O chipset). This board has Intel chipset. I cannot remember the exact type

Re: [PERFORM] sql-bench

2006-09-13 Thread Dave Cramer
All of the tuning parameters would affect all queries shared buffers, wal buffers, effective cache, to name a few --dc-- On 13-Sep-06, at 8:24 AM, yoav x wrote: Hi I am trying to run sql-bench against PostgreSQL 8.1.4 on Linux. Some of the insert tests seems to be ver slow For example:

Re: [PERFORM] sql-bench

2006-09-13 Thread Dave Cramer
wrote: So why are these queries so slow in PG? --- Dave Cramer [EMAIL PROTECTED] wrote: All of the tuning parameters would affect all queries shared buffers, wal buffers, effective cache, to name a few --dc-- On 13-Sep-06, at 8:24 AM, yoav x wrote: Hi I am trying to run sql-bench against

Re: [PERFORM] Xeon Woodcrest/Dempsey vs Opteron Socket F/940 with postgresql and some SAS raid-figures

2006-09-08 Thread Dave Cramer
Hi, Arjen, On 8-Sep-06, at 1:51 AM, Arjen van der Meijden wrote: Hi, We've been running our webapp database-benchmark again on mysql and postgresql. This time using a Fujitsu-Siemens RX300 S3 machine equipped with a 2.66Ghz Woodcrest (5150) and a 3.73Ghz Dempsey (5080). And compared

Re: [PERFORM] Xeon Woodcrest/Dempsey vs Opteron Socket F/940 with postgresql and some SAS raid-figures

2006-09-08 Thread Dave Cramer
On 8-Sep-06, at 8:44 AM, Arjen van der Meijden wrote: Dave Cramer wrote: Hi, Arjen, The Woodcrest is quite a bit faster than the Opterons. Actually... With Hyperthreading *enabled* the older Dempsey- processor is also faster than the Opterons with PostgreSQL. But then again

Re: [PERFORM] increasing shared buffers: how much should be removed

2006-09-05 Thread Dave Cramer
On 5-Sep-06, at 9:31 AM, Merlin Moncure wrote: On 9/1/06, Joshua D. Drake [EMAIL PROTECTED] wrote: I think 'shared buffers' is one of the most overrated settings from a performance standpoint. however you must ensure there is enough for things the server does besides caching. It

  1   2   >