Troubleshooting the OpenERP 7 database - hangs / locks?

Asked by Dave Burkholder

I have a problem that is embarassingly open-ended. I'm using OpenERP 7 and experiencing very frequent lockups / program hanging. The activity is always related to creating new records; never when only reading records or navigating OE7.

I can be creating new contacts or invoices, receiving customer payments, creating new Journal accounts; whatever. When suddenly instead of OE 7 responding instantly to a mouse click, there's no response for a few seconds till the "Loading" spinner appears. Then it'll never go away.

I've discovered that the following remedies help, in descending order of importance.
1. service openerp-server restart (this helps very occasionaly; almost not worth mentioning).
2. service openerp-server stop / service postgresql restart / service openerp-server start (moderately more effective than #1)
3. service openerp-server stop / re-index postgres database / service openerp-server start (resolves the issue 95% of the time)
4. service openerp-server stop / vaccuum & reindex postgres database / service openerp-server start (resolves issue 100% of times that #3 didn't.)

So I'm glad to have detected that much of a pattern, but it's enormously frustrating. This happens 2-3 times per 15 minute session.

System specs
I'm running OE 7 on Kubuntu 12.04.1, with an AMD 925 X4 CPU / 8 GB RAM / OCZ Agility 3 SSD Drive. Postgres 9.1.7

Any help here on what to troubleshoot? I've tried tailing the OE server logs, but when these problems exist, I often don't even see the log entry for the corresponding mouse click creating the record. So it seems very much database related.

Question information

Language:
English Edit question
Status:
Solved
For:
Odoo Server (MOVED TO GITHUB) Edit question
Assignee:
No assignee Edit question
Solved by:
Dave Burkholder
Solved:
Last query:
Last reply:
Revision history for this message
Dave Burkholder (akxws32zf-dave-j0p9h616h) said :
#1

For whoever comes along and reads this, my problem was that the defaults of Postgresql were set to low. I spent some time tweaking the conf file defaults and ever since, my OE 7 instance has been 100% reliable.

This link was very helpful. http://blip.tv/djangocon/secrets-of-postgresql-performance-5572403

Revision history for this message
Rafael Beckel (rafaelbeckel) said :
#2

Thanks for posting this ;)