[GENERAL] My index doesn't write anymore but read

2015-05-17 Thread ben.play
Hi all, We have a large database with postgre 9.3 (>300 Gb) and our queries are (really) long for 6 days without changing anything. After seeing our log, I saw that the same query on an old data was quick but the same query with new data are really slow. Let me show you a sample of my query on

Re: [GENERAL] My index doesn't write anymore but read

2015-05-18 Thread ben.play
Thank you for your quick answer ! And ... you are a genius :) A simple "analyse " resolved my problem. Do We have to do it regularly ? Thank you a lot ! -- View this message in context: http://postgresql.nabble.com/My-index-doesn-t-write-anymore-but-read-tp5849689p5849699.html Sent from

Re: [GENERAL] My index doesn't write anymore but read

2015-06-01 Thread ben.play
Thank your William for your help. After 1 week, I do not see any improvement. Worse, I have to manually run "ANALYSE" daily. Here is my config : My bloat for this table is 1.04151. What does it mean exactly ? Why do we have to analyse the table daily ? Is it normal ? Thank you so much for y

[GENERAL] Which replication is the best for our case ?

2015-06-29 Thread ben.play
Hi guys, We have a PG database with more than 400 GB of data. At this moment, a cron runs each ten minutes and updates about 10 000 lines with complex algorithms in PHP. Each time the cron runs, the website is almost down because some queries have to make an update on the FULL table... Theref

Re: [GENERAL] Which replication is the best for our case ?

2015-06-30 Thread ben.play
Hi guys, Thank you a lot for your answers. In fact, I tried to write the easiest explanation of my problem in order to be understood... My project is developed with Symfony and Doctrine (BERK, i know ...). The project has more than 2 years and Doctrine makes some bad decisions and lock all the

Re: [GENERAL] Which replication is the best for our case ?

2015-07-01 Thread ben.play
In fact, the cron job will : -> select about 10 000 lines from a big table (>100 Gb of data). 1 user has about 10 lines. -> each line will be examinate by an algorithm -> at the end of each line, the cron job updates a few parameters for the user (add some points for example) -> Then, it inserts

[GENERAL] Log all queries before migration ?

2016-07-29 Thread ben.play
Hi guys, We have some storage problem on our dedicated server and we have to migrate. Do you know how can I log all queries in order to have no downtime during migration ? I tried many options on the conf, but i never find the good one. I didn't find out to generate .sql file with all queries.

Re: [GENERAL] Log all queries before migration ?

2016-08-03 Thread ben.play
Hi guys, In fact, I would like to copy a table and then, when everything is finish, execute all inserts and updates since the beginning of the copy. The biggest problem with the log at this time it's the query. All my queries are not runnable. When I log, I see this kind of queries : "duratio