- 1. An introduction to important aspects of a correct deployment, and 2 examples
- 2. Some advice on how should you be monitoring your Odoo deployment: which metrics in particular, and why it matters.
- 3. Finally, a few tips to help you analyze and troubleshoot a performance situation without wasting hours.
Further information about each topic can be found in more comprehensive talks of previous Odoo Experience, such as:
2. 1 Deploying
10. 3 Optimizing
7. 2 Measuring & Monitoring
11. Update your deployment regularly
1. Performance Olivier Dony @odony Tips & Tricks
15. Summary 1 Plan and deploy properly, scale as needed 2 Setup precise monitoring 3 Update, Sample, Optimize This is the basic checklist for performance investigation! Tech support @ www.odoo.com/help
14. Sample the system while running Odoo Workers Send SIGQUIT to dump worker stacks: kill -3 <odoo_worker_pid> + Easy to send from htop + Repeat to analyze long running transactions
8. Watch your deployment’s performance PostgreSQL : transactions / minute Odoo : requests / minute, avg duration Disk : response time, IOPS System : load, I/O wait, memory Network : connections, bandwidth Establish your performance baseline
13. Sample the system while running PostgreSQL Install pg_activity to watch the database + htop-like for PostgreSQL + Running/Waiting/Blocking queries + Read/Write per second + Pause, kill queries, etc. + CPU/Memory/Load
6. Deployment Architecture Recommendations Setup a reverse proxy in front of Odoo + SSL Termination + Gzip + Serve static assets + Load balancing + Block access to DB manager Backend (DB): max I/O, RAM and Speed 64GB + SSD + 3.5GHz Base CPU speed Frontend (HTTP): max Speed and # Cores 6c/12t 3.5GHz Base CPU speed
3. Deployment Architecture Rules of thumb Activate multi-worker to use your fancy hardware! Worker soft memory limit Dedicated RAM Max = How many workers processes? 1 per CPU core , x2 for recycling Soft limit = 1GB RAM = 24GB e.g. = 24 workers Min = 6 (typical browser keepalive pool size) + Enforce limits + Recycle processes + Perform better + Sync changes How many requests/second? ~ 6-7 x Workers e.g. 24 workers = 160 r/s How many users? ~ 5-10 per Worker e.g. 24 active workers = 180 users
9. Watch your deployment’s performance PostgreSQL : transactions / minute Odoo : requests / minute, avg duration Disk : response time, IOPS System : load, I/O wait, memory Network : connections, bandwidth Suggested tool: Munin Built-in plugins for most key metrics Writing plugins is trivial Constant storage footprint (rrdtool) day week month year Configurable limits/warnings Exampleplugins Nginx times: https://git.io/vP3Sj Odoo times: https://git.io/vP3h9 Establish your performance baseline
4. Deployment Architecture Scaling: example 1 16c /32t Xeon E5 2640v3 – 2.6GHz 64 GB RAM Odoo Server W orkers: 20 100 users 10000 visitors/day Odoo Server (B) W orkers: 20 r e p l i c a t o n Backend + Frontend
12. Optimizing your Deployment PostgreSQL Verify the usual server settings: effective_cache_size, work_mem, shared_buffers See also documentation: https://wiki.postgresql.org/wiki/Performance_Optimization Log slow queries: log_min_statement_duration = 500 Then watch slow queries in PostgreSQL log file Use EXPLAIN ANALYZE <query> to verify the plan See also https://explain.depesz.com Verify statistics and vacuuming (autovacuum!) Create missing indexes carefully (composite, order, etc.) Create missing FK indexes to fix slow deletion
5. Deployment Architecture Scaling: example 2 6c /12t Xeon E5 1650v3 – 3.5GHz 64 GB RAM DB + File Server 300 users 25000 visitors/day Odoo Workers: 10 Odoo Workers: 10 Odoo Workers: 10 Load Balancer 4c /8t Xeon E5 1630v3 - 3.7GHz 32 GB RAM 3 X NFS NFS NFS + replicaton of backend Backend Frontend
- 7152 Total Views
- 5318 Website Views
- 1834 Embedded Views
- Social Shares
- 0 Likes
- 0 Dislikes
- 0 Comments
- 0 Facebook
- 0 Twitter
- 0 Google+
- 2 tecnativa.com
- 8 www.tecnativa.com
10 Rules for Safer Code4022 Views .
Odoo vs resto de plataformas ecommerce (2016)3371 Views .
Odoo 10 - Performance3360 Views .
Odoo VOIP presentaion3346 Views .
Deploy own runbot3057 Views .
Being a manager at Odoo3027 Views .
The Odoo Culture2940 Views .
Odoo Enterprise: Details of the Services and SLA2763 Views .
The art of persuading decision makers2749 Views .