SlideShare a Scribd company logo
1 of 15
Download to read offline
HIGH PERFORMANCE
                 WordPress
                  Iliya Polihronov
                  WordCamp San Francisco 2012

Saturday, August 4, 12
Iliya
       Polihronov
       Systems Wrangler
       Automattic




       polihronov.wordpress.com
       slideshare.net/vnsavage
                @vnsavage

Saturday, August 4, 12
WordPress.com
            Numbers

             ‣ 115 million pageviews per day

             ‣ 2.6 billion requests per day

             ‣ over 200 plugins

             ‣ 500ms per page


Saturday, August 4, 12
Notable Users




Saturday, August 4, 12
Services Installation
            Nginx                   wiki.nginx.org/Install

            PHP-FPM                 Compile PHP with --enable-fpm

            For Debian Squeeze
            $ gpg --keyserver   hkp://keys.gnupg.net --recv-keys E9C74FEEA2098A6E
            $ gpg --keyserver   hkp://keys.gnupg.net --recv-keys ABF5BD827BD9BF62
            $ gpg -a --export E9C74FEEA2098A6E | apt-key add -
            $ gpg -a --export ABF5BD827BD9BF62 | apt-key add -
            $ echo 'deb http://nginx.org/packages/debian/ squeeze nginx' >> /etc/apt/sources.list
            $ echo 'deb http://packages.dotdeb.org squeeze-php54 all' >> /etc/apt/sources.list
            $ apt-get update
            $ apt-get install nginx php5-cli php5-fpm php5-cgi php5-mysql php5-memcache




Saturday, August 4, 12
Services Installation
            APC                php.net/manual/en/apc.installation.php


            MySQL              percona.com/doc/percona-server/5.5/installation.html


            Memcached                   memcached.org


            For Debian Squeeze
            $ gpg --keyserver   hkp://keys.gnupg.net --recv-keys 1C4CBDCDCD2EFD2A
            $ gpg -a --export CD2EFD2A | apt-key add -
            $ echo ‘deb http://repo.percona.com/apt squeeze main’ >> /etc/apt/sources.list
            $ apt-get update
            $ apt-get install php5-apc memcached percona-server-server-5.5 percona-server-client-5.5




Saturday, August 4, 12
Nginx Configuration
            /etc/nginx/nginx.conf

            worker_processes 8;
            worker_connections 2048;
            keepalive_timeout 30;

            gzip on;
            gzip_types text/css text/javascript application/x-javascript application/json text/xml;
            gzip_min_length 500;
            gzip_comp_level 5;

            location ~ .(css|js|jp(e)?g|gif|png|swf|ico)$   {
               expires 1y;
            }

            fastcgi_buffer_size 32k;
            fastcgi_buffers 256 4k;

            /etc/init.d/nginx

            ulimit -n 65536

            Full configuration at polihronov.wordpress.com


Saturday, August 4, 12
PHP-FPM and APC
            /etc/php5/fpm/pool.d/www.conf

            pm = dynamic
            pm.max_children = 40
            pm.start_servers = 5
            pm.min_spare_servers = 5
            pm.max_spare_servers = 10
            listen.backlog = 512

            /etc/php5/conf.d/20-apc.ini

            extension="apc.so"
            apc.enabled = 1
            apc.shm_size = 32M

            /etc/php5/fpm/php.ini

            output_buffering = 4096




Saturday, August 4, 12
MySQL Configuration
            /etc/mysql/my.cnf

            key_buffer = 256M
            sort_buffer_size = 4M
            read_buffer_size = 4M
            innodb_buffer_pool_size = 256M
            innodb_log_buffer_size = 8M

            tmp_table_size = 32M
            max_heap_table_size = 32M

            table_cache = 128
            thread_cache = 64

            query_cache_type = 1
            query_cache_limit = 1M
            query_cache_size = 32M

            InnoDB - for tables with lots of reads and writes
            mysqlreport - inspect important MySQL status values




Saturday, August 4, 12
Optimizing your
            WordPress Install

            ‣ Keep it up to date

            ‣ Avoid unnecessary plugins

            ‣ Avoid slow plugins
                  http://wordpress.org/extend/plugins/p3-profiler



Saturday, August 4, 12
Caching

            Memcached Object Cache
            http://wordpress.org/extend/plugins/memcached/




            WP Super Cache
            http://wordpress.org/extend/plugins/wp-super-cache/

            ‣ Custom permalinks, like /%year/%monthnum%/%postname%/
            ‣ Enable all the recommended settings



Saturday, August 4, 12
Benchmarks
            Virtual machine on a laptop, using Apache Benchmark (ab):


            Without APC

               11.07 REQUESTS/SEC

            With APC

                 48.39 REQUESTS/SEC

            With APC and Caching

                                                16,140.70 REQUESTS/SEC


Saturday, August 4, 12
At a Larger Scale

                         INTERNET

                                                  Load Balancers




                                    Web Servers   Caching Servers   Web Servers




                                     Memcached
                                                        Master-Slave MySQL

Saturday, August 4, 12
Questions?
                         HIGH PERFORMANCE
                         WordPress

Saturday, August 4, 12
Iliya
       Polihronov
       Systems Wrangler
       Automattic




       polihronov.wordpress.com
       slideshare.net/vnsavage
                @vnsavage

Saturday, August 4, 12

More Related Content

What's hot

Asfws 2014 slides why .net needs ma-cs and other serial(-ization) tales_v2.0
Asfws 2014 slides why .net needs ma-cs and other serial(-ization) tales_v2.0Asfws 2014 slides why .net needs ma-cs and other serial(-ization) tales_v2.0
Asfws 2014 slides why .net needs ma-cs and other serial(-ization) tales_v2.0
Cyber Security Alliance
 

What's hot (20)

Lets make a better react form
Lets make a better react formLets make a better react form
Lets make a better react form
 
Logs/Metrics Gathering With OpenShift EFK Stack
Logs/Metrics Gathering With OpenShift EFK StackLogs/Metrics Gathering With OpenShift EFK Stack
Logs/Metrics Gathering With OpenShift EFK Stack
 
Mastering the Sling Rewriter
Mastering the Sling RewriterMastering the Sling Rewriter
Mastering the Sling Rewriter
 
Introduction to Nexus Repository Manager.pdf
Introduction to Nexus Repository Manager.pdfIntroduction to Nexus Repository Manager.pdf
Introduction to Nexus Repository Manager.pdf
 
Asfws 2014 slides why .net needs ma-cs and other serial(-ization) tales_v2.0
Asfws 2014 slides why .net needs ma-cs and other serial(-ization) tales_v2.0Asfws 2014 slides why .net needs ma-cs and other serial(-ization) tales_v2.0
Asfws 2014 slides why .net needs ma-cs and other serial(-ization) tales_v2.0
 
Exception handling
Exception handlingException handling
Exception handling
 
Introduction to VueJS & Vuex
Introduction to VueJS & VuexIntroduction to VueJS & Vuex
Introduction to VueJS & Vuex
 
왜 쿠버네티스는 systemd로 cgroup을 관리하려고 할까요
왜 쿠버네티스는 systemd로 cgroup을 관리하려고 할까요왜 쿠버네티스는 systemd로 cgroup을 관리하려고 할까요
왜 쿠버네티스는 systemd로 cgroup을 관리하려고 할까요
 
Angular 2 observables
Angular 2 observablesAngular 2 observables
Angular 2 observables
 
Kubernetes #1 intro
Kubernetes #1   introKubernetes #1   intro
Kubernetes #1 intro
 
Overview of secret management solutions and architecture
Overview of secret management solutions and architectureOverview of secret management solutions and architecture
Overview of secret management solutions and architecture
 
Nginx Deep Dive Kubernetes Ingress
Nginx Deep Dive Kubernetes IngressNginx Deep Dive Kubernetes Ingress
Nginx Deep Dive Kubernetes Ingress
 
Prometheus
PrometheusPrometheus
Prometheus
 
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교 및 구축 방법
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교  및 구축 방법[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교  및 구축 방법
[오픈소스컨설팅] 쿠버네티스와 쿠버네티스 on 오픈스택 비교 및 구축 방법
 
Modern JS with ES6
Modern JS with ES6Modern JS with ES6
Modern JS with ES6
 
Rest api with node js and express
Rest api with node js and expressRest api with node js and express
Rest api with node js and express
 
Spring beans
Spring beansSpring beans
Spring beans
 
[Russia] MySQL OOB injections
[Russia] MySQL OOB injections[Russia] MySQL OOB injections
[Russia] MySQL OOB injections
 
[2019] HTTP API 설계 후회 고민
[2019] HTTP API 설계 후회 고민[2019] HTTP API 설계 후회 고민
[2019] HTTP API 설계 후회 고민
 
Le Wagon - React 101
Le Wagon - React 101Le Wagon - React 101
Le Wagon - React 101
 

Viewers also liked

Viewers also liked (20)

WCSF 2012 - All You Can Eat Content Types
WCSF 2012 - All You Can Eat Content TypesWCSF 2012 - All You Can Eat Content Types
WCSF 2012 - All You Can Eat Content Types
 
bbPress - WCSF 2012
bbPress - WCSF 2012bbPress - WCSF 2012
bbPress - WCSF 2012
 
WordPress SEO Revisited by Lou Anne McKeefery of Be Found
WordPress SEO Revisited by Lou Anne McKeefery of Be FoundWordPress SEO Revisited by Lou Anne McKeefery of Be Found
WordPress SEO Revisited by Lou Anne McKeefery of Be Found
 
Git Version Control for the Complete N00b by Adam LaBarge
Git Version Control for the Complete N00b by Adam LaBargeGit Version Control for the Complete N00b by Adam LaBarge
Git Version Control for the Complete N00b by Adam LaBarge
 
WordPress Gallery tutorial
WordPress Gallery tutorialWordPress Gallery tutorial
WordPress Gallery tutorial
 
Is Your (Client's) Website Ready for 2017?
Is Your (Client's) Website Ready for 2017?Is Your (Client's) Website Ready for 2017?
Is Your (Client's) Website Ready for 2017?
 
WordPress and Business Intelligence
WordPress and Business IntelligenceWordPress and Business Intelligence
WordPress and Business Intelligence
 
State of Mobile
State of MobileState of Mobile
State of Mobile
 
Designing for The Modern Web
Designing for The Modern WebDesigning for The Modern Web
Designing for The Modern Web
 
WordPress State of the Word 2012
WordPress State of the Word 2012WordPress State of the Word 2012
WordPress State of the Word 2012
 
Nginx & php fpm - the webserver you might actually like - php usergroup berlin
Nginx & php fpm - the webserver you might actually like - php usergroup berlinNginx & php fpm - the webserver you might actually like - php usergroup berlin
Nginx & php fpm - the webserver you might actually like - php usergroup berlin
 
WordPress for Nonprofits Using CiviCRM
WordPress for Nonprofits Using CiviCRMWordPress for Nonprofits Using CiviCRM
WordPress for Nonprofits Using CiviCRM
 
PHP conference Berlin 2015: running PHP on Nginx
PHP conference Berlin 2015: running PHP on NginxPHP conference Berlin 2015: running PHP on Nginx
PHP conference Berlin 2015: running PHP on Nginx
 
Sallie Goetsch: Making the Events Calendar Sit Up and Beg
Sallie Goetsch: Making the Events Calendar Sit Up and BegSallie Goetsch: Making the Events Calendar Sit Up and Beg
Sallie Goetsch: Making the Events Calendar Sit Up and Beg
 
PhpStorm for WordPress
PhpStorm for WordPressPhpStorm for WordPress
PhpStorm for WordPress
 
Rob La Gatta; Making the Events Calendar Sit Up and Beg
Rob La Gatta; Making the Events Calendar Sit Up and BegRob La Gatta; Making the Events Calendar Sit Up and Beg
Rob La Gatta; Making the Events Calendar Sit Up and Beg
 
WordPress Comments (November Meetup)
WordPress Comments (November Meetup)WordPress Comments (November Meetup)
WordPress Comments (November Meetup)
 
Making WordPress Easier to Use
Making WordPress Easier to UseMaking WordPress Easier to Use
Making WordPress Easier to Use
 
AWS Cloudfront Howto
AWS Cloudfront HowtoAWS Cloudfront Howto
AWS Cloudfront Howto
 
Real Developer Tools for WordPress by Stefan Didak
Real Developer Tools for WordPress by Stefan DidakReal Developer Tools for WordPress by Stefan Didak
Real Developer Tools for WordPress by Stefan Didak
 

Similar to High Performance WordPress

Site Performance - From Pinto to Ferrari
Site Performance - From Pinto to FerrariSite Performance - From Pinto to Ferrari
Site Performance - From Pinto to Ferrari
Joseph Scott
 
Website releases made easy with the PEAR installer, OSCON 2009
Website releases made easy with the PEAR installer, OSCON 2009Website releases made easy with the PEAR installer, OSCON 2009
Website releases made easy with the PEAR installer, OSCON 2009
Helgi Þormar Þorbjörnsson
 

Similar to High Performance WordPress (20)

Award-winning technology: Oxid loves the query cache
Award-winning technology: Oxid loves the query cacheAward-winning technology: Oxid loves the query cache
Award-winning technology: Oxid loves the query cache
 
How to install and configure LEMP stack
How to install and configure LEMP stackHow to install and configure LEMP stack
How to install and configure LEMP stack
 
Site Performance - From Pinto to Ferrari
Site Performance - From Pinto to FerrariSite Performance - From Pinto to Ferrari
Site Performance - From Pinto to Ferrari
 
Caching and tuning fun for high scalability
Caching and tuning fun for high scalabilityCaching and tuning fun for high scalability
Caching and tuning fun for high scalability
 
Nginx [engine x] and you (and WordPress)
Nginx [engine x] and you (and WordPress)Nginx [engine x] and you (and WordPress)
Nginx [engine x] and you (and WordPress)
 
Scaling WordPress
Scaling WordPressScaling WordPress
Scaling WordPress
 
10 Million hits a day with WordPress using a $15 VPS
10 Million hits a day  with WordPress using a $15 VPS10 Million hits a day  with WordPress using a $15 VPS
10 Million hits a day with WordPress using a $15 VPS
 
Running PHP on nginx
Running PHP on nginxRunning PHP on nginx
Running PHP on nginx
 
Sofia WP User Group Presentation
Sofia WP User Group PresentationSofia WP User Group Presentation
Sofia WP User Group Presentation
 
Caching and tuning fun for high scalability @ FOSDEM 2012
Caching and tuning fun for high scalability @ FOSDEM 2012Caching and tuning fun for high scalability @ FOSDEM 2012
Caching and tuning fun for high scalability @ FOSDEM 2012
 
Scale Apache with Nginx
Scale Apache with NginxScale Apache with Nginx
Scale Apache with Nginx
 
Nginx pres
Nginx presNginx pres
Nginx pres
 
Cache all the things - A guide to caching Drupal
Cache all the things - A guide to caching DrupalCache all the things - A guide to caching Drupal
Cache all the things - A guide to caching Drupal
 
Web Front End Performance
Web Front End PerformanceWeb Front End Performance
Web Front End Performance
 
161208
161208161208
161208
 
PHP on Heroku: Deploying and Scaling Apps in the Cloud
PHP on Heroku: Deploying and Scaling Apps in the CloudPHP on Heroku: Deploying and Scaling Apps in the Cloud
PHP on Heroku: Deploying and Scaling Apps in the Cloud
 
Grâce aux tags Varnish, j'ai switché ma prod sur Raspberry Pi
Grâce aux tags Varnish, j'ai switché ma prod sur Raspberry PiGrâce aux tags Varnish, j'ai switché ma prod sur Raspberry Pi
Grâce aux tags Varnish, j'ai switché ma prod sur Raspberry Pi
 
Website releases made easy with the PEAR installer, OSCON 2009
Website releases made easy with the PEAR installer, OSCON 2009Website releases made easy with the PEAR installer, OSCON 2009
Website releases made easy with the PEAR installer, OSCON 2009
 
Converting Your Dev Environment to a Docker Stack - php[world]
Converting Your Dev Environment to a Docker Stack - php[world]Converting Your Dev Environment to a Docker Stack - php[world]
Converting Your Dev Environment to a Docker Stack - php[world]
 
OSCP Preparation Guide @ Infosectrain
OSCP Preparation Guide @ InfosectrainOSCP Preparation Guide @ Infosectrain
OSCP Preparation Guide @ Infosectrain
 

Recently uploaded

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 

Recently uploaded (20)

Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
Apidays Singapore 2024 - Scalable LLM APIs for AI and Generative AI Applicati...
 
Real Time Object Detection Using Open CV
Real Time Object Detection Using Open CVReal Time Object Detection Using Open CV
Real Time Object Detection Using Open CV
 
GenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdfGenAI Risks & Security Meetup 01052024.pdf
GenAI Risks & Security Meetup 01052024.pdf
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
Mastering MySQL Database Architecture: Deep Dive into MySQL Shell and MySQL R...
 
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
Apidays Singapore 2024 - Building Digital Trust in a Digital Economy by Veron...
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
ICT role in 21st century education and its challenges
ICT role in 21st century education and its challengesICT role in 21st century education and its challenges
ICT role in 21st century education and its challenges
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
Apidays New York 2024 - Accelerating FinTech Innovation by Vasa Krishnan, Fin...
 
2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...2024: Domino Containers - The Next Step. News from the Domino Container commu...
2024: Domino Containers - The Next Step. News from the Domino Container commu...
 
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
Apidays New York 2024 - The Good, the Bad and the Governed by David O'Neill, ...
 
Ransomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdfRansomware_Q4_2023. The report. [EN].pdf
Ransomware_Q4_2023. The report. [EN].pdf
 
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
Emergent Methods: Multi-lingual narrative tracking in the news - real-time ex...
 

High Performance WordPress

  • 1. HIGH PERFORMANCE WordPress Iliya Polihronov WordCamp San Francisco 2012 Saturday, August 4, 12
  • 2. Iliya Polihronov Systems Wrangler Automattic polihronov.wordpress.com slideshare.net/vnsavage @vnsavage Saturday, August 4, 12
  • 3. WordPress.com Numbers ‣ 115 million pageviews per day ‣ 2.6 billion requests per day ‣ over 200 plugins ‣ 500ms per page Saturday, August 4, 12
  • 5. Services Installation Nginx wiki.nginx.org/Install PHP-FPM Compile PHP with --enable-fpm For Debian Squeeze $ gpg --keyserver hkp://keys.gnupg.net --recv-keys E9C74FEEA2098A6E $ gpg --keyserver hkp://keys.gnupg.net --recv-keys ABF5BD827BD9BF62 $ gpg -a --export E9C74FEEA2098A6E | apt-key add - $ gpg -a --export ABF5BD827BD9BF62 | apt-key add - $ echo 'deb http://nginx.org/packages/debian/ squeeze nginx' >> /etc/apt/sources.list $ echo 'deb http://packages.dotdeb.org squeeze-php54 all' >> /etc/apt/sources.list $ apt-get update $ apt-get install nginx php5-cli php5-fpm php5-cgi php5-mysql php5-memcache Saturday, August 4, 12
  • 6. Services Installation APC php.net/manual/en/apc.installation.php MySQL percona.com/doc/percona-server/5.5/installation.html Memcached memcached.org For Debian Squeeze $ gpg --keyserver hkp://keys.gnupg.net --recv-keys 1C4CBDCDCD2EFD2A $ gpg -a --export CD2EFD2A | apt-key add - $ echo ‘deb http://repo.percona.com/apt squeeze main’ >> /etc/apt/sources.list $ apt-get update $ apt-get install php5-apc memcached percona-server-server-5.5 percona-server-client-5.5 Saturday, August 4, 12
  • 7. Nginx Configuration /etc/nginx/nginx.conf worker_processes 8; worker_connections 2048; keepalive_timeout 30; gzip on; gzip_types text/css text/javascript application/x-javascript application/json text/xml; gzip_min_length 500; gzip_comp_level 5; location ~ .(css|js|jp(e)?g|gif|png|swf|ico)$ { expires 1y; } fastcgi_buffer_size 32k; fastcgi_buffers 256 4k; /etc/init.d/nginx ulimit -n 65536 Full configuration at polihronov.wordpress.com Saturday, August 4, 12
  • 8. PHP-FPM and APC /etc/php5/fpm/pool.d/www.conf pm = dynamic pm.max_children = 40 pm.start_servers = 5 pm.min_spare_servers = 5 pm.max_spare_servers = 10 listen.backlog = 512 /etc/php5/conf.d/20-apc.ini extension="apc.so" apc.enabled = 1 apc.shm_size = 32M /etc/php5/fpm/php.ini output_buffering = 4096 Saturday, August 4, 12
  • 9. MySQL Configuration /etc/mysql/my.cnf key_buffer = 256M sort_buffer_size = 4M read_buffer_size = 4M innodb_buffer_pool_size = 256M innodb_log_buffer_size = 8M tmp_table_size = 32M max_heap_table_size = 32M table_cache = 128 thread_cache = 64 query_cache_type = 1 query_cache_limit = 1M query_cache_size = 32M InnoDB - for tables with lots of reads and writes mysqlreport - inspect important MySQL status values Saturday, August 4, 12
  • 10. Optimizing your WordPress Install ‣ Keep it up to date ‣ Avoid unnecessary plugins ‣ Avoid slow plugins http://wordpress.org/extend/plugins/p3-profiler Saturday, August 4, 12
  • 11. Caching Memcached Object Cache http://wordpress.org/extend/plugins/memcached/ WP Super Cache http://wordpress.org/extend/plugins/wp-super-cache/ ‣ Custom permalinks, like /%year/%monthnum%/%postname%/ ‣ Enable all the recommended settings Saturday, August 4, 12
  • 12. Benchmarks Virtual machine on a laptop, using Apache Benchmark (ab): Without APC 11.07 REQUESTS/SEC With APC 48.39 REQUESTS/SEC With APC and Caching 16,140.70 REQUESTS/SEC Saturday, August 4, 12
  • 13. At a Larger Scale INTERNET Load Balancers Web Servers Caching Servers Web Servers Memcached Master-Slave MySQL Saturday, August 4, 12
  • 14. Questions? HIGH PERFORMANCE WordPress Saturday, August 4, 12
  • 15. Iliya Polihronov Systems Wrangler Automattic polihronov.wordpress.com slideshare.net/vnsavage @vnsavage Saturday, August 4, 12