- 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
- 6853 Total Views
- 3 Website Views
- 6850 Embedded Views
- Social Shares
- 6 Likes
- 0 Dislikes
- 0 Comments
- 0 Facebook
- 0 Twitter
- 0 Google+
- 7 accounts.odoo.com
- 9 onlinesync.odoo.com
- 208 troi-z.com
- 3 www.google.com
Keynote: Odoo 9 New Features41808 Views .
Odoo Mobile Development Framework & App build with it15973 Views .
Import and export data - Tips & Tricks11722 Views .
Odoo 9 New Design- The rationales behind it11701 Views .
How A/B testing can help you optimize your website11585 Views .
Open Source Licenses11442 Views .
Shipper integration - UPS, DHL, FedEx8202 Views .
UX best practices to create your module6513 Views .
Keynote: Odoo Strategy 20156493 Views .
Contributing to the Odoo Community Association (OCA)6404 Views .
Introduction to Odoo Warehouse Management6314 Views .
How to use Odoo in a Restaurant6011 Views .
Odoo 9: New Business Model5711 Views .
VOIP: One-click Button to Automate Calls5596 Views .
Odoo cms Performance Comparison and Optimisation5519 Views .
State of the Odoo JS framework5124 Views .
How to use Odoo in a service company4814 Views .
How to develop new views in Odoo 104774 Views .
First steps in Odoo dev4741 Views .