SlideShare a Scribd company logo
Speeding up the snail
Marcus Deglos
and making Drupal scale
Who is Marcus?
Software engineer
with Ibuildings
Drupal contributor
PADI scuba diving
instructor
The problem with frameworks
The cost of the
framework:
- include files
- function calls
- database queries
So why use Drupal?
• Quicker to develop
• Easier to maintain
Turbo-charging your site
Optimising the stackTuning
Drupal
Adding hardware
Benchmarks
Optimising the stack
• Apache
• PHP
• MySQL
• APC extension
• Varnish
Apache
• Pre-fork vs Worker
mode
• Number of servers /
clients
• Impact of .htaccess
/ AllowOverride
• Impact of SuExec
Optimising the stack
PHP
• CGI vs Apache
Module vc FastCGI
• php.ini:
– Memory limit -
choose for stability
– register_long_
arrays
Optimising the stack
Database
• Optimising the database
– Monitoring with the slow query log
– Add (and remove) indices based on usage
– Consider table types: MYISAM vs INNODB
• Optimising the service
– Custom compilation
– Configuring my.cnf
• Consider your hardware
Optimising the stack
APC
• APC is an op-code
cache
• Install and forget?
• Monitor APC use
• APC tuning
– APC memory usage
– APC stat: checks if
files are modified
– APC filters
Optimising the stack
Varnish
• Varnish is an HTTP
accelerator
• Requires D7,
Pressflow, or a
patch to Drupal
core
• New mindset for
personalising
content - think ESI
Optimising the stack
Tuning Drupal
• Drupal page
cache
• Optimise JS /
CSS
• Memcached
• Using the Drupal
cache
Tuning Drupal
• admin/settings/performance
• Page caching improves performance for
anonymous users
• CSS and JS aggregation improves front-end
performance
Admin : performance settings
Tuning Drupal
Memcached
• Direct replacement for Drupal’s DB cache
• To setup:
– Install the Drupal module
– Configure settings.php
– Install the memcached daemon
– Install the PECL extension
• Minimal tuning (multiple cache ‘bins’)
Tuning Drupal
Using cache_get and cache_set
• Use a static cache for simple queries
static $foo = null;
• Use cache_get and cache_set for
complex objects:
– Multiple DB queries
– Slow remote resources (e.g. SOAP)
Adding hardware
• Separate the web server, database
server and HTTP accelerator onto their
own dedicated hardware
• Horizontal scaling: double the hardware
= double the performance?
• Hunt the bottleneck
• Scale with the cloud - Project Mercury
Benchmarking
• ab
• Jmeter
• Online services
Real world performance
Real world performance
Page cache
Real world performance
Memcache
Real world performance
APC
Real world performance
Varnish
Real world performance
Summary
• Page cache: 2x - 8x
• Memcache: 2.5x
• APC: 1x - 2x
• Varnish: 50x ?
Final thoughts
• Off the shelf :
Pressflow, Zend
Community
Server
• Quick wins:
– Page cache
– Memcache
– APC
– Varnish
That’s all folks!
Image attribution - CC via Flickr
• SNAIL (nutmeg66)
http://www.flickr.com/photos/rachel_s/29060
95941/
• SCUBA - FISH SCHOOL (tobze)
http://www.flickr.com/photos/tobze/2137899
342/
• BALL AND CHAIN (Fred Dawson)
http://www.flickr.com/photos/fwp-
dawson/520311773/
• SPOILER (icathing)
http://www.flickr.com/photos/icathing/26603
225/
• SERVER RACK (Jamison_Judd)
http://www.flickr.com/photos/jamisonjudd/24
33102356/
• GRAPH (tracer.ca)
http://www.flickr.com/photos/tracer/3249533
12/
• STACK (Wonderlane)
http://www.flickr.com/photos/wonderlane/23
63603984/
• TUNING (Crashmaster007)
http://www.flickr.com/photos/crashmaster/33
44052447/
• ROAD END (Joseph Hatfield)
http://www.flickr.com/photos/jhat/218880745
0/
• TORTOISE NAP (MaestroBen)
http://www.flickr.com/photos/maestroben/36
9200383/
• CAMERA (Burnt Pixel)
http://www.flickr.com/photos/keithwj/365098
384/
• QUESTIONS (Stefan Baudy)
http://www.flickr.com/photos/-
bast-/349497988/
• SERVER FARM (sugree)
http://www.flickr.com/photos/sugree/302464
0027/
• CAT (fofurasfelinas)
http://www.flickr.com/photos/fofurasfelinas/1
297744859/
Thanks for coming!
Rate this talk
http://joind.in/620
Download slides
from slideshare
@manarth

More Related Content

What's hot

Memcache
MemcacheMemcache
Memcache
Abhinav Singh
 
Caching with Varnish
Caching with VarnishCaching with Varnish
Caching with Varnishschoefmax
 
Roy foubister (hosting high traffic sites on a tight budget)
Roy foubister (hosting high traffic sites on a tight budget)Roy foubister (hosting high traffic sites on a tight budget)
Roy foubister (hosting high traffic sites on a tight budget)WordCamp Cape Town
 
Cassandra as Memcache
Cassandra as MemcacheCassandra as Memcache
Cassandra as Memcache
Edward Capriolo
 
The secret life of a dispatcher (Adobe CQ AEM)
The secret life of a dispatcher (Adobe CQ AEM)The secret life of a dispatcher (Adobe CQ AEM)
The secret life of a dispatcher (Adobe CQ AEM)
Venugopal Gummadala
 
Caching with Memcached and APC
Caching with Memcached and APCCaching with Memcached and APC
Caching with Memcached and APC
Ben Ramsey
 
Architecting cloud
Architecting cloudArchitecting cloud
Architecting cloud
Tahsin Hasan
 
Aem dispatcher – tips & tricks
Aem dispatcher – tips & tricksAem dispatcher – tips & tricks
Aem dispatcher – tips & tricks
Ashokkumar T A
 
Memcached Presentation
Memcached PresentationMemcached Presentation
Memcached Presentation
Asif Ali
 
Drupal performance optimization Best Practices
Drupal performance optimization Best PracticesDrupal performance optimization Best Practices
Drupal performance optimization Best Practices
Ratnesh kumar, CSM
 
[MathWorks] Versioning Infrastructure
[MathWorks] Versioning Infrastructure[MathWorks] Versioning Infrastructure
[MathWorks] Versioning InfrastructurePerforce
 
How to scale your web app
How to scale your web appHow to scale your web app
How to scale your web app
Georgio_1999
 
WE18_Performance_Up.ppt
WE18_Performance_Up.pptWE18_Performance_Up.ppt
WE18_Performance_Up.pptwebhostingguy
 
03 h base-2-installation_andshell
03 h base-2-installation_andshell03 h base-2-installation_andshell
03 h base-2-installation_andshell
dntth0601
 
DrupalCampLA 2011: Drupal backend-performance
DrupalCampLA 2011: Drupal backend-performanceDrupalCampLA 2011: Drupal backend-performance
DrupalCampLA 2011: Drupal backend-performance
Ashok Modi
 
SQL Server Integration Services Tips & Tricks
SQL Server Integration Services Tips & TricksSQL Server Integration Services Tips & Tricks
SQL Server Integration Services Tips & TricksGuillermo Caicedo
 
Pure Speed Drupal 4 Gov talk
Pure Speed Drupal 4 Gov talkPure Speed Drupal 4 Gov talk
Pure Speed Drupal 4 Gov talk
Bryan Ollendyke
 
Install Wordpress in Ubuntu Linux by Tushar B. Kute
Install Wordpress in Ubuntu Linux by Tushar B. KuteInstall Wordpress in Ubuntu Linux by Tushar B. Kute
Install Wordpress in Ubuntu Linux by Tushar B. Kute
Tushar B Kute
 
Content Storage With Apache Jackrabbit
Content Storage With Apache JackrabbitContent Storage With Apache Jackrabbit
Content Storage With Apache JackrabbitJukka Zitting
 

What's hot (20)

Memcache
MemcacheMemcache
Memcache
 
Caching with Varnish
Caching with VarnishCaching with Varnish
Caching with Varnish
 
Roy foubister (hosting high traffic sites on a tight budget)
Roy foubister (hosting high traffic sites on a tight budget)Roy foubister (hosting high traffic sites on a tight budget)
Roy foubister (hosting high traffic sites on a tight budget)
 
Cassandra as Memcache
Cassandra as MemcacheCassandra as Memcache
Cassandra as Memcache
 
The secret life of a dispatcher (Adobe CQ AEM)
The secret life of a dispatcher (Adobe CQ AEM)The secret life of a dispatcher (Adobe CQ AEM)
The secret life of a dispatcher (Adobe CQ AEM)
 
Caching with Memcached and APC
Caching with Memcached and APCCaching with Memcached and APC
Caching with Memcached and APC
 
Architecting cloud
Architecting cloudArchitecting cloud
Architecting cloud
 
5-WebServers.ppt
5-WebServers.ppt5-WebServers.ppt
5-WebServers.ppt
 
Aem dispatcher – tips & tricks
Aem dispatcher – tips & tricksAem dispatcher – tips & tricks
Aem dispatcher – tips & tricks
 
Memcached Presentation
Memcached PresentationMemcached Presentation
Memcached Presentation
 
Drupal performance optimization Best Practices
Drupal performance optimization Best PracticesDrupal performance optimization Best Practices
Drupal performance optimization Best Practices
 
[MathWorks] Versioning Infrastructure
[MathWorks] Versioning Infrastructure[MathWorks] Versioning Infrastructure
[MathWorks] Versioning Infrastructure
 
How to scale your web app
How to scale your web appHow to scale your web app
How to scale your web app
 
WE18_Performance_Up.ppt
WE18_Performance_Up.pptWE18_Performance_Up.ppt
WE18_Performance_Up.ppt
 
03 h base-2-installation_andshell
03 h base-2-installation_andshell03 h base-2-installation_andshell
03 h base-2-installation_andshell
 
DrupalCampLA 2011: Drupal backend-performance
DrupalCampLA 2011: Drupal backend-performanceDrupalCampLA 2011: Drupal backend-performance
DrupalCampLA 2011: Drupal backend-performance
 
SQL Server Integration Services Tips & Tricks
SQL Server Integration Services Tips & TricksSQL Server Integration Services Tips & Tricks
SQL Server Integration Services Tips & Tricks
 
Pure Speed Drupal 4 Gov talk
Pure Speed Drupal 4 Gov talkPure Speed Drupal 4 Gov talk
Pure Speed Drupal 4 Gov talk
 
Install Wordpress in Ubuntu Linux by Tushar B. Kute
Install Wordpress in Ubuntu Linux by Tushar B. KuteInstall Wordpress in Ubuntu Linux by Tushar B. Kute
Install Wordpress in Ubuntu Linux by Tushar B. Kute
 
Content Storage With Apache Jackrabbit
Content Storage With Apache JackrabbitContent Storage With Apache Jackrabbit
Content Storage With Apache Jackrabbit
 

Viewers also liked

Análise - Esquadrão Verde Tang
Análise - Esquadrão Verde TangAnálise - Esquadrão Verde Tang
Análise - Esquadrão Verde Tang
Meiriane Jacobsen
 
WorkCover Case Review 2015 RJA
WorkCover Case Review 2015 RJAWorkCover Case Review 2015 RJA
WorkCover Case Review 2015 RJARohan Armstrong
 
Diccionario pictórico
Diccionario pictóricoDiccionario pictórico
Diccionario pictórico
Vivian Valverde
 
Git
Git Git
ECON220 PORT PROJ ROUGH DRAFT
ECON220 PORT PROJ ROUGH DRAFTECON220 PORT PROJ ROUGH DRAFT
ECON220 PORT PROJ ROUGH DRAFTApril Metcalf
 
Victoria Grendell Resume-updated 2015
Victoria Grendell Resume-updated 2015Victoria Grendell Resume-updated 2015
Victoria Grendell Resume-updated 2015Victoria Grendell
 
Contrato informatico
Contrato informaticoContrato informatico
Contrato informatico
marie2018
 
Manejo de medicamentos en el hogar 3
Manejo de medicamentos en el hogar 3Manejo de medicamentos en el hogar 3
Manejo de medicamentos en el hogar 3
Nilda Armijo
 
Grasscutter farming
Grasscutter farmingGrasscutter farming
Grasscutter farming
Prince john
 
Fitxak 4 hizki direktoak
Fitxak 4 hizki direktoakFitxak 4 hizki direktoak
Fitxak 4 hizki direktoak
Gontzal
 

Viewers also liked (16)

Resume Roscoe 2016
Resume Roscoe 2016Resume Roscoe 2016
Resume Roscoe 2016
 
FJarin_resume
FJarin_resumeFJarin_resume
FJarin_resume
 
Jaffar Naqvi CV
Jaffar Naqvi CVJaffar Naqvi CV
Jaffar Naqvi CV
 
Ruckus_prof
Ruckus_profRuckus_prof
Ruckus_prof
 
Análise - Esquadrão Verde Tang
Análise - Esquadrão Verde TangAnálise - Esquadrão Verde Tang
Análise - Esquadrão Verde Tang
 
WorkCover Case Review 2015 RJA
WorkCover Case Review 2015 RJAWorkCover Case Review 2015 RJA
WorkCover Case Review 2015 RJA
 
Diccionario pictórico
Diccionario pictóricoDiccionario pictórico
Diccionario pictórico
 
Valentine's 2016 Resume
Valentine's 2016 ResumeValentine's 2016 Resume
Valentine's 2016 Resume
 
Git
Git Git
Git
 
Ruby RussonR
Ruby RussonRRuby RussonR
Ruby RussonR
 
ECON220 PORT PROJ ROUGH DRAFT
ECON220 PORT PROJ ROUGH DRAFTECON220 PORT PROJ ROUGH DRAFT
ECON220 PORT PROJ ROUGH DRAFT
 
Victoria Grendell Resume-updated 2015
Victoria Grendell Resume-updated 2015Victoria Grendell Resume-updated 2015
Victoria Grendell Resume-updated 2015
 
Contrato informatico
Contrato informaticoContrato informatico
Contrato informatico
 
Manejo de medicamentos en el hogar 3
Manejo de medicamentos en el hogar 3Manejo de medicamentos en el hogar 3
Manejo de medicamentos en el hogar 3
 
Grasscutter farming
Grasscutter farmingGrasscutter farming
Grasscutter farming
 
Fitxak 4 hizki direktoak
Fitxak 4 hizki direktoakFitxak 4 hizki direktoak
Fitxak 4 hizki direktoak
 

Similar to Speeding Up The Snail

Big Data Day LA 2016/ Big Data Track - How To Use Impala and Kudu To Optimize...
Big Data Day LA 2016/ Big Data Track - How To Use Impala and Kudu To Optimize...Big Data Day LA 2016/ Big Data Track - How To Use Impala and Kudu To Optimize...
Big Data Day LA 2016/ Big Data Track - How To Use Impala and Kudu To Optimize...
Data Con LA
 
Fundamentals of performance tuning PHP on IBM i
Fundamentals of performance tuning PHP on IBM i  Fundamentals of performance tuning PHP on IBM i
Fundamentals of performance tuning PHP on IBM i
Zend by Rogue Wave Software
 
DrupalCampLA 2014 - Drupal backend performance and scalability
DrupalCampLA 2014 - Drupal backend performance and scalabilityDrupalCampLA 2014 - Drupal backend performance and scalability
DrupalCampLA 2014 - Drupal backend performance and scalability
cherryhillco
 
AWS (Hadoop) Meetup 30.04.09
AWS (Hadoop) Meetup 30.04.09AWS (Hadoop) Meetup 30.04.09
AWS (Hadoop) Meetup 30.04.09
Chris Purrington
 
High Performance Drupal
High Performance DrupalHigh Performance Drupal
High Performance Drupal
Chapter Three
 
Architectures, Frameworks and Infrastructure
Architectures, Frameworks and InfrastructureArchitectures, Frameworks and Infrastructure
Architectures, Frameworks and Infrastructureharendra_pathak
 
Designing enterprise drupal
Designing enterprise drupalDesigning enterprise drupal
Designing enterprise drupal
Jason Burnett
 
Cassandra Summit 2014: Apache Cassandra Best Practices at Ebay
Cassandra Summit 2014: Apache Cassandra Best Practices at EbayCassandra Summit 2014: Apache Cassandra Best Practices at Ebay
Cassandra Summit 2014: Apache Cassandra Best Practices at Ebay
DataStax Academy
 
Introduction to memcached
Introduction to memcachedIntroduction to memcached
Introduction to memcached
Jurriaan Persyn
 
071410 sun a_1515_feldman_stephen
071410 sun a_1515_feldman_stephen071410 sun a_1515_feldman_stephen
071410 sun a_1515_feldman_stephen
Steve Feldman
 
Migrating enterprise workloads to AWS
Migrating enterprise workloads to AWSMigrating enterprise workloads to AWS
Migrating enterprise workloads to AWSTom Laszewski
 
Apache Performance Tuning: Scaling Out
Apache Performance Tuning: Scaling OutApache Performance Tuning: Scaling Out
Apache Performance Tuning: Scaling Out
Sander Temme
 
Anthony Somerset - Site Speed = Success!
Anthony Somerset - Site Speed = Success!Anthony Somerset - Site Speed = Success!
Anthony Somerset - Site Speed = Success!
WordCamp Cape Town
 
Moving to the Cloud: AWS, Zend, RightScale
Moving to the Cloud: AWS, Zend, RightScaleMoving to the Cloud: AWS, Zend, RightScale
Moving to the Cloud: AWS, Zend, RightScalemmoline
 
Cloud - High Availability @ Low Cost - Workshop - Gurpreet ahuja
Cloud - High Availability @ Low Cost - Workshop - Gurpreet ahujaCloud - High Availability @ Low Cost - Workshop - Gurpreet ahuja
Cloud - High Availability @ Low Cost - Workshop - Gurpreet ahuja
ResellerClub
 
Configuring Apache Servers for Better Web Perormance
Configuring Apache Servers for Better Web PerormanceConfiguring Apache Servers for Better Web Perormance
Configuring Apache Servers for Better Web Perormance
Spark::red
 
Performance_Out.pptx
Performance_Out.pptxPerformance_Out.pptx
Performance_Out.pptx
sanjanabal
 

Similar to Speeding Up The Snail (20)

Drupal performance
Drupal performanceDrupal performance
Drupal performance
 
Big Data Day LA 2016/ Big Data Track - How To Use Impala and Kudu To Optimize...
Big Data Day LA 2016/ Big Data Track - How To Use Impala and Kudu To Optimize...Big Data Day LA 2016/ Big Data Track - How To Use Impala and Kudu To Optimize...
Big Data Day LA 2016/ Big Data Track - How To Use Impala and Kudu To Optimize...
 
Fundamentals of performance tuning PHP on IBM i
Fundamentals of performance tuning PHP on IBM i  Fundamentals of performance tuning PHP on IBM i
Fundamentals of performance tuning PHP on IBM i
 
DrupalCampLA 2014 - Drupal backend performance and scalability
DrupalCampLA 2014 - Drupal backend performance and scalabilityDrupalCampLA 2014 - Drupal backend performance and scalability
DrupalCampLA 2014 - Drupal backend performance and scalability
 
AWS (Hadoop) Meetup 30.04.09
AWS (Hadoop) Meetup 30.04.09AWS (Hadoop) Meetup 30.04.09
AWS (Hadoop) Meetup 30.04.09
 
Performance out
Performance outPerformance out
Performance out
 
High Performance Drupal
High Performance DrupalHigh Performance Drupal
High Performance Drupal
 
Architectures, Frameworks and Infrastructure
Architectures, Frameworks and InfrastructureArchitectures, Frameworks and Infrastructure
Architectures, Frameworks and Infrastructure
 
Designing enterprise drupal
Designing enterprise drupalDesigning enterprise drupal
Designing enterprise drupal
 
Cassandra Summit 2014: Apache Cassandra Best Practices at Ebay
Cassandra Summit 2014: Apache Cassandra Best Practices at EbayCassandra Summit 2014: Apache Cassandra Best Practices at Ebay
Cassandra Summit 2014: Apache Cassandra Best Practices at Ebay
 
Introduction to memcached
Introduction to memcachedIntroduction to memcached
Introduction to memcached
 
071410 sun a_1515_feldman_stephen
071410 sun a_1515_feldman_stephen071410 sun a_1515_feldman_stephen
071410 sun a_1515_feldman_stephen
 
Migrating enterprise workloads to AWS
Migrating enterprise workloads to AWSMigrating enterprise workloads to AWS
Migrating enterprise workloads to AWS
 
Apache Performance Tuning: Scaling Out
Apache Performance Tuning: Scaling OutApache Performance Tuning: Scaling Out
Apache Performance Tuning: Scaling Out
 
Anthony Somerset - Site Speed = Success!
Anthony Somerset - Site Speed = Success!Anthony Somerset - Site Speed = Success!
Anthony Somerset - Site Speed = Success!
 
Moving to the Cloud: AWS, Zend, RightScale
Moving to the Cloud: AWS, Zend, RightScaleMoving to the Cloud: AWS, Zend, RightScale
Moving to the Cloud: AWS, Zend, RightScale
 
Cloud - High Availability @ Low Cost - Workshop - Gurpreet ahuja
Cloud - High Availability @ Low Cost - Workshop - Gurpreet ahujaCloud - High Availability @ Low Cost - Workshop - Gurpreet ahuja
Cloud - High Availability @ Low Cost - Workshop - Gurpreet ahuja
 
Configuring Apache Servers for Better Web Perormance
Configuring Apache Servers for Better Web PerormanceConfiguring Apache Servers for Better Web Perormance
Configuring Apache Servers for Better Web Perormance
 
Performance_Out.pptx
Performance_Out.pptxPerformance_Out.pptx
Performance_Out.pptx
 
2 7
2 72 7
2 7
 

More from Marcus Deglos

Vagrant crash course
Vagrant crash courseVagrant crash course
Vagrant crash course
Marcus Deglos
 
Drupal haters gonna hate
Drupal haters gonna hateDrupal haters gonna hate
Drupal haters gonna hate
Marcus Deglos
 
With one click
With one clickWith one click
With one click
Marcus Deglos
 
Panels rocks!
Panels rocks!Panels rocks!
Panels rocks!
Marcus Deglos
 
Where in the world
Where in the worldWhere in the world
Where in the world
Marcus Deglos
 

More from Marcus Deglos (6)

Vagrant crash course
Vagrant crash courseVagrant crash course
Vagrant crash course
 
Drupal haters gonna hate
Drupal haters gonna hateDrupal haters gonna hate
Drupal haters gonna hate
 
With one click
With one clickWith one click
With one click
 
Panels rocks!
Panels rocks!Panels rocks!
Panels rocks!
 
SSO To go
SSO To goSSO To go
SSO To go
 
Where in the world
Where in the worldWhere in the world
Where in the world
 

Recently uploaded

Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
Dorra BARTAGUIZ
 
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Product School
 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
Elena Simperl
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance
 
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
Product School
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a button
DianaGray10
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
Prayukth K V
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Product School
 
Essentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with ParametersEssentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with Parameters
Safe Software
 
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Tobias Schneck
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and Grafana
RTTS
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
DianaGray10
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
Kari Kakkonen
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Thierry Lestable
 
Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*
Frank van Harmelen
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
KatiaHIMEUR1
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
Thijs Feryn
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
James Anderson
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Albert Hoitingh
 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
Elena Simperl
 

Recently uploaded (20)

Elevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object CalisthenicsElevating Tactical DDD Patterns Through Object Calisthenics
Elevating Tactical DDD Patterns Through Object Calisthenics
 
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
Unsubscribed: Combat Subscription Fatigue With a Membership Mentality by Head...
 
Knowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and backKnowledge engineering: from people to machines and back
Knowledge engineering: from people to machines and back
 
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdfFIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
FIDO Alliance Osaka Seminar: Passkeys and the Road Ahead.pdf
 
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
AI for Every Business: Unlocking Your Product's Universal Potential by VP of ...
 
Connector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a buttonConnector Corner: Automate dynamic content and events by pushing a button
Connector Corner: Automate dynamic content and events by pushing a button
 
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 previewState of ICS and IoT Cyber Threat Landscape Report 2024 preview
State of ICS and IoT Cyber Threat Landscape Report 2024 preview
 
Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...Designing Great Products: The Power of Design and Leadership by Chief Designe...
Designing Great Products: The Power of Design and Leadership by Chief Designe...
 
Essentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with ParametersEssentials of Automations: Optimizing FME Workflows with Parameters
Essentials of Automations: Optimizing FME Workflows with Parameters
 
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
Kubernetes & AI - Beauty and the Beast !?! @KCD Istanbul 2024
 
JMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and GrafanaJMeter webinar - integration with InfluxDB and Grafana
JMeter webinar - integration with InfluxDB and Grafana
 
UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4UiPath Test Automation using UiPath Test Suite series, part 4
UiPath Test Automation using UiPath Test Suite series, part 4
 
DevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA ConnectDevOps and Testing slides at DASA Connect
DevOps and Testing slides at DASA Connect
 
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
Empowering NextGen Mobility via Large Action Model Infrastructure (LAMI): pav...
 
Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*Neuro-symbolic is not enough, we need neuro-*semantic*
Neuro-symbolic is not enough, we need neuro-*semantic*
 
Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !Securing your Kubernetes cluster_ a step-by-step guide to success !
Securing your Kubernetes cluster_ a step-by-step guide to success !
 
Accelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish CachingAccelerate your Kubernetes clusters with Varnish Caching
Accelerate your Kubernetes clusters with Varnish Caching
 
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
GDG Cloud Southlake #33: Boule & Rebala: Effective AppSec in SDLC using Deplo...
 
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
Encryption in Microsoft 365 - ExpertsLive Netherlands 2024
 
When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...When stars align: studies in data quality, knowledge graphs, and machine lear...
When stars align: studies in data quality, knowledge graphs, and machine lear...
 

Speeding Up The Snail

  • 1. Speeding up the snail Marcus Deglos and making Drupal scale
  • 2. Who is Marcus? Software engineer with Ibuildings Drupal contributor PADI scuba diving instructor
  • 3. The problem with frameworks The cost of the framework: - include files - function calls - database queries
  • 4. So why use Drupal? • Quicker to develop • Easier to maintain
  • 5. Turbo-charging your site Optimising the stackTuning Drupal Adding hardware Benchmarks
  • 6. Optimising the stack • Apache • PHP • MySQL • APC extension • Varnish
  • 7. Apache • Pre-fork vs Worker mode • Number of servers / clients • Impact of .htaccess / AllowOverride • Impact of SuExec Optimising the stack
  • 8. PHP • CGI vs Apache Module vc FastCGI • php.ini: – Memory limit - choose for stability – register_long_ arrays Optimising the stack
  • 9. Database • Optimising the database – Monitoring with the slow query log – Add (and remove) indices based on usage – Consider table types: MYISAM vs INNODB • Optimising the service – Custom compilation – Configuring my.cnf • Consider your hardware Optimising the stack
  • 10. APC • APC is an op-code cache • Install and forget? • Monitor APC use • APC tuning – APC memory usage – APC stat: checks if files are modified – APC filters Optimising the stack
  • 11. Varnish • Varnish is an HTTP accelerator • Requires D7, Pressflow, or a patch to Drupal core • New mindset for personalising content - think ESI Optimising the stack
  • 12. Tuning Drupal • Drupal page cache • Optimise JS / CSS • Memcached • Using the Drupal cache
  • 13. Tuning Drupal • admin/settings/performance • Page caching improves performance for anonymous users • CSS and JS aggregation improves front-end performance Admin : performance settings
  • 14. Tuning Drupal Memcached • Direct replacement for Drupal’s DB cache • To setup: – Install the Drupal module – Configure settings.php – Install the memcached daemon – Install the PECL extension • Minimal tuning (multiple cache ‘bins’)
  • 15. Tuning Drupal Using cache_get and cache_set • Use a static cache for simple queries static $foo = null; • Use cache_get and cache_set for complex objects: – Multiple DB queries – Slow remote resources (e.g. SOAP)
  • 16. Adding hardware • Separate the web server, database server and HTTP accelerator onto their own dedicated hardware • Horizontal scaling: double the hardware = double the performance? • Hunt the bottleneck • Scale with the cloud - Project Mercury
  • 23. Real world performance Summary • Page cache: 2x - 8x • Memcache: 2.5x • APC: 1x - 2x • Varnish: 50x ?
  • 24. Final thoughts • Off the shelf : Pressflow, Zend Community Server • Quick wins: – Page cache – Memcache – APC – Varnish
  • 26. Image attribution - CC via Flickr • SNAIL (nutmeg66) http://www.flickr.com/photos/rachel_s/29060 95941/ • SCUBA - FISH SCHOOL (tobze) http://www.flickr.com/photos/tobze/2137899 342/ • BALL AND CHAIN (Fred Dawson) http://www.flickr.com/photos/fwp- dawson/520311773/ • SPOILER (icathing) http://www.flickr.com/photos/icathing/26603 225/ • SERVER RACK (Jamison_Judd) http://www.flickr.com/photos/jamisonjudd/24 33102356/ • GRAPH (tracer.ca) http://www.flickr.com/photos/tracer/3249533 12/ • STACK (Wonderlane) http://www.flickr.com/photos/wonderlane/23 63603984/ • TUNING (Crashmaster007) http://www.flickr.com/photos/crashmaster/33 44052447/ • ROAD END (Joseph Hatfield) http://www.flickr.com/photos/jhat/218880745 0/ • TORTOISE NAP (MaestroBen) http://www.flickr.com/photos/maestroben/36 9200383/ • CAMERA (Burnt Pixel) http://www.flickr.com/photos/keithwj/365098 384/ • QUESTIONS (Stefan Baudy) http://www.flickr.com/photos/- bast-/349497988/ • SERVER FARM (sugree) http://www.flickr.com/photos/sugree/302464 0027/ • CAT (fofurasfelinas) http://www.flickr.com/photos/fofurasfelinas/1 297744859/
  • 27. Thanks for coming! Rate this talk http://joind.in/620 Download slides from slideshare @manarth