High Performance for Small Sites John Bickar, Stanford - - PowerPoint PPT Presentation

high performance for small sites
SMART_READER_LITE
LIVE PREVIEW

High Performance for Small Sites John Bickar, Stanford - - PowerPoint PPT Presentation

High Performance for Small Sites John Bickar, Stanford Web Services 1 What is a small site? Shared hos=ng Limited/no access to Linux/Apache layer


slide-1
SLIDE 1

High ¡Performance ¡for ¡Small ¡Sites ¡ ¡

John ¡Bickar, ¡Stanford ¡Web ¡Services ¡

1

slide-2
SLIDE 2

Small ¡VPS ¡

What ¡is ¡a ¡“small ¡site?” ¡

Shared ¡hos=ng ¡ Limited/no ¡access ¡to ¡Linux/Apache ¡layer ¡ Cannot ¡install ¡Varnish, ¡memcache, ¡etc. ¡

slide-3
SLIDE 3

What ¡is ¡a ¡“small ¡site?” ¡

If ¡you ¡run: ¡ ¡ $ sudo apt-get install varnish ¡ And ¡it ¡returns, ¡“user ¡not ¡sufficiently ¡super,” ¡you ¡ might ¡have ¡a ¡small ¡site. ¡

slide-4
SLIDE 4

YOUR ¡SLOW ¡DRUPAL ¡SITE ¡

slide-5
SLIDE 5
slide-6
SLIDE 6
slide-7
SLIDE 7
slide-8
SLIDE 8

What you want.

slide-9
SLIDE 9
slide-10
SLIDE 10

What you can make your users think you have.

slide-11
SLIDE 11

What you’re still not going to get.

slide-12
SLIDE 12

The ¡Crea=on ¡of ¡a ¡Slow ¡Drupal ¡Site ¡

A ¡play ¡in ¡four ¡acts ¡

slide-13
SLIDE 13

ACT ¡I: ¡INCEPTION ¡

slide-14
SLIDE 14

“We ¡need ¡a ¡Drupal!” ¡

slide-15
SLIDE 15

ACT ¡II: ¡CREATION ¡

slide-16
SLIDE 16

Work, ¡work, ¡work ¡

slide-17
SLIDE 17

ACT ¡III: ¡EXPANSION ¡

slide-18
SLIDE 18

“That’s ¡great!” ¡ “Can ¡we ¡add…” ¡ Events ¡ Contact ¡form ¡ Restricted ¡content ¡ Room ¡reserva=ons ¡ Seventeen ¡more ¡roles ¡ Publishing ¡workflow ¡ Ten ¡more ¡content ¡types ¡ Slap ¡Chop ¡ George ¡Foreman ¡grill ¡ Custom ¡breadcrumbs ¡ Custom ¡.tpl.php ¡ Custom ¡web ¡app ¡ Mobile ¡device ¡detec=on ¡ Field-­‑level ¡permissions ¡ GI ¡Joe ¡with ¡the ¡kung-­‑fu ¡grip ¡ Discussion ¡forums ¡

slide-19
SLIDE 19

ACT ¡IV: ¡DECELERATION ¡

slide-20
SLIDE 20
slide-21
SLIDE 21

May ¡5th, ¡2012 ¡ 21

Ini=al ¡Assessment ¡

Hos=ng ¡Op=ons ¡ Traffic ¡ Resources ¡ Priori=es ¡

slide-22
SLIDE 22

May ¡5th, ¡2012 ¡ 22

Assessing ¡Performance ¡ Bo^lenecks ¡

When? ¡ Where? ¡ What? ¡ Who? ¡ Why? ¡

slide-23
SLIDE 23

May ¡5th, ¡2012 ¡ 23

General ¡Tips ¡

Delete ¡unnecessary ¡modules ¡ Disable ¡unnecessary ¡modules ¡

slide-24
SLIDE 24
slide-25
SLIDE 25
slide-26
SLIDE 26
slide-27
SLIDE 27

May ¡5th, ¡2012 ¡ 27

General ¡Tips ¡

Use ¡them ¡ Drupal ¡core ¡performance ¡se`ngs ¡ admin/se`ngs/performance ¡(D6) ¡ admin/config/development/performance ¡(D7) ¡

slide-28
SLIDE 28

May ¡5th, ¡2012 ¡ 28

Tes=ng ¡Tools ¡

YSlow ¡ Inspector ¡in ¡Chrome, ¡Safari ¡ ApacheBench ¡

slide-29
SLIDE 29

May ¡5th, ¡2012 ¡ 29

Advanced ¡Performance ¡-­‑ ¡Caching ¡

Cache ¡Rules ¡Everything ¡Around ¡Me ¡ Cache ¡gets ¡stale ¡

slide-30
SLIDE 30

May ¡5th, ¡2012 ¡ 30

Advanced ¡Performance ¡-­‑ ¡Caching ¡

cron ¡

32 * * * * curl -sS http://www.example.com/foo > \ /dev/null

slide-31
SLIDE 31

May ¡5th, ¡2012 ¡ 31

Advanced ¡Performance ¡-­‑ ¡Caching ¡

Views ¡caching ¡ Panels ¡caching ¡ Boost ¡ AuthCache ¡

slide-32
SLIDE 32

Prove ¡it ¡

techcommons.stanford.edu ¡ Homepage ¡load ¡=me ¡with ¡uncached ¡ View: ¡ 9.7 ¡seconds ¡

slide-33
SLIDE 33

Prove ¡it ¡

techcommons.stanford.edu ¡ Homepage ¡load ¡=me ¡ager ¡enabling ¡ Views ¡caching: ¡ 2.8 ¡seconds ¡

slide-34
SLIDE 34

Prove ¡it ¡

techcommons.stanford.edu ¡ Homepage ¡load ¡=me ¡ager ¡enabling ¡ Boost ¡caching: ¡ 117 ¡milliseconds ¡

slide-35
SLIDE 35

May ¡5th, ¡2012 ¡ 35

Advanced ¡Performance ¡-­‑ ¡ Debugging ¡

Devel ¡

slide-36
SLIDE 36
slide-37
SLIDE 37
slide-38
SLIDE 38
slide-39
SLIDE 39

May ¡5th, ¡2012 ¡ 39

Summary ¡

Know ¡thy ¡users ¡ ¡ ¡

Keep ¡Calm ¡ And ¡ DRUPAL ¡ON ¡

Know ¡thy ¡content ¡ Know ¡thy ¡traffic ¡

slide-40
SLIDE 40

Appendix ¡

Linkies: ¡

  • h^p://techcommons.stanford.edu/topics/web-­‑development/benchmarking-­‑site-­‑performance-­‑apachebench ¡
  • h^p://techcommons.stanford.edu/topics/drupal/boost ¡ ¡
  • h^p://techcommons.stanford.edu/topics/drupal/improving-­‑drupal-­‑performance-­‑and-­‑speed-­‑leland-­‑servers ¡ ¡