Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-30 Thread Marti Raudsepp
On Sat, Jan 28, 2012 at 19:11, Jayashankar K B jayashankar...@lnties.com wrote: But we are stumped by the amount of CPU Postgres is eating up. You still haven't told us *how* slow it actually is and how fast you need it to be? What's your database layout like (tables, columns, indexes, foreign

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-29 Thread Jose Ildefonso Camargo Tolosa
Greetings, On Sat, Jan 28, 2012 at 12:51 PM, Jayashankar K B jayashankar...@lnties.com wrote: Hi, I downloaded the source code and cross compiled it into a relocatable package and copied it to the device. LTIB was the cross-compile tool chain that was used. Controller is  coldfire

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-28 Thread Jayashankar K B
Hi, The number of inserts into the database would be a minimum of 3000 records in one operation.. We do not have any stringent requirement of writing speed. So we could make do with a slower write speed as long as the CPU usage is not heavy... :) We will try reducing the priority and check

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-28 Thread Jayashankar K B
Hi, I downloaded the source code and cross compiled it into a relocatable package and copied it to the device. LTIB was the cross-compile tool chain that was used. Controller is coldfire MCF54418 CPU. Here is the configure options I used. ./configure

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-28 Thread Deron
Hello, One thing you may look at are the index and constraints on the relations. If you have multiple constraints or index this may add CPU time on each insert. You may try to drop the index, do a bulk load, and then recreate the index. This may (or may not) reduce the total time / CPU but

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-28 Thread Jeff Janes
On Fri, Jan 27, 2012 at 10:30 AM, Jayashankar K B jayashankar...@lnties.com wrote: Hi Heikki Linnakangas: We are using series of Insert statements to insert the records into database. Sending data in binary is not an option as the module that writes into DB has been finalized. We do not

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-28 Thread Claudio Freire
On Sat, Jan 28, 2012 at 2:21 PM, Jayashankar K B jayashankar...@lnties.com wrote: ./configure CC=/opt/freescale/usr/local/gcc-4.4.54-eglibc-2.10.54/m68k-linux/bin/m68k-linux-gnu-gcc CFLAGS='-fmessage-length=0 -fpack-struct -mcpu=54418 -msoft-float' --host=i686-pc-linux-gnu

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-28 Thread Mark Kirkwood
If you can batch the inserts into groups (of say 10 to 100) it might help performance - i.e: Instead of INSERT INTO table VALUES(...); INSERT INTO table VALUES(...); ... INSERT INTO table VALUES(...); do INSERT INTO table VALUES(...),(...),...,(...); This reduces the actual number of INSERT

[PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-27 Thread Jayashankar K B
Hi, We are having an embedded system with a freescale m68k architecture based micro-controller, 256MB RAM running a customized version of Slackware 12 linux. It's a relatively modest Hardware. We have installed postgres 9.1 as our database engine. While testing, we found that the Postgres

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-27 Thread Heikki Linnakangas
On 27.01.2012 15:34, Jayashankar K B wrote: Hi, We are having an embedded system with a freescale m68k architecture based micro-controller, 256MB RAM running a customized version of Slackware 12 linux. It's a relatively modest Hardware. Fascinating! We have installed postgres 9.1 as our

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-27 Thread Andy Colson
On 1/27/2012 10:47 AM, Heikki Linnakangas wrote: On 27.01.2012 15:34, Jayashankar K B wrote: Hi, We are having an embedded system with a freescale m68k architecture based micro-controller, 256MB RAM running a customized version of Slackware 12 linux. It's a relatively modest Hardware.

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-27 Thread Jayashankar K B
Hi Heikki Linnakangas: We are using series of Insert statements to insert the records into database. Sending data in binary is not an option as the module that writes into DB has been finalized. We do not have control over that. Hi Andy: As of now, there are no triggers in the table. Please

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-27 Thread Heikki Linnakangas
On 27.01.2012 20:30, Jayashankar K B wrote: Hi Heikki Linnakangas: We are using series of Insert statements to insert the records into database. Sending data in binary is not an option as the module that writes into DB has been finalized. We do not have control over that. That certainly

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-27 Thread Claudio Freire
On Fri, Jan 27, 2012 at 4:56 PM, Heikki Linnakangas heikki.linnakan...@enterprisedb.com wrote: I don't think there's anything particular in postgres that would make it a poor choice on a small system, as far as CPU usage is concerned anyway. But inserting rows in a database is certainly slower

Re: [PERFORM] Postgress is taking lot of CPU on our embedded hardware.

2012-01-27 Thread Scott Marlowe
On Fri, Jan 27, 2012 at 6:34 AM, Jayashankar K B jayashankar...@lnties.com wrote: Hi, We are having an embedded system with a freescale m68k architecture based micro-controller, 256MB RAM running a customized version of Slackware 12 linux. It’s a relatively modest Hardware. We have