Living withoutyour Linemen             OSCON Portland, OR: June 27, 2011, 5pm
Not aboutAutomatticI’m not in Systems and OperationsAutomattic doesn’t work this way
Me = Typical Engineer• Mercurial/   Tempermental• Lack of Attention to   Detail• Can’t multitask
Me = Least Qualifiedto be Lecturing You   Typical Engineer except in one way
Who am I?
Who am I?Me (and others) on a deck of           cards
PHPTerroristHave a nice Chay!
“…when I created the      Web”          — (not) A l Gore
Cha yism  http://phpdoc.info/chayism                            /                                 One ounce of Terry      ...
Chayism  http://phpdoc.info/chayism                               /
Terry Chay does not   walk, or run, or     Chayism  drive, or take an                          http://phpdoc.info/chayism ...
1500 Lines Of   Code  PHP Advent 2009           http://phpadvent.org/2009/                                      1500-lines...
John Henry of     C++
1500 Lines of   Code/Day    (max)        “Except Java”Java: It only takes three years to put in a hard days work!
Outliers        Malcolm Gladwell   10,000 Hours of Diligent          Practicehttp://www.amazon.com/g                      ...
Talent is      Overrated           Geoff Colvin10,000 Hours = 20/week week  * every week * 10 years!http://www.amazon.com/...
1500 lines of codeHalf a Million Line codebase = Peak Day, Every Day, 1Year
Terry Chay doesnt write code, he just    Chayism   thinks it, andminions do it for him     http://phpdoc.info/chayism     ...
Part 1 Why: ThreeObservations
1. SiteOps are your   offensive line   http://terrychay.com/artic                              le/special-    sysadmin-app...
Quarterback  Site Architect
Running Back   Programmer
Wide Receiver   Programmer
Offensive Line  System Operations
Keep YourLine Happy   Last Friday in Julyhttp://www.sysadminday.co                            m/
2. Story of (Ruby on)        Rails
“The Hottest Hacker on      the Earth.”             — WIRED                 Wired 14.04 page 3
“Fuck You.”               nemeier Hansson   —D avid Hei                    David 3:16
“fuckity fuck fucking     fuck fuck.”      —E XPLICIT TAG                    #TCFC +=5
“coding these web appsthemselves involves a lot   of swearing—a lot ofblood, sweat and swear.”               —Me          ...
“Fuck You.”               nemeier Hansson   —D avid Hei                    David 3:16
“I can’t run Rails inmod_ruby on Apache on    a shared host”                 h o has ev er tried       —A nyone w         ...
“Fuck You.”               nemeier Hansson   —D avid Hei                    David 3:16
“Read/Writes as websites  grow don’t scale evenly with    Moore’s Law, so a bigger    machine isn’t solving my     databas...
“Fuck You.”               nemeier Hansson   —D avid Hei                    David 3:16
“Fuck Comcast.”              —Me          Every time the intertubes                                      get tied
The Internet doesnt  go down, Terry       Chayism Chays laptop justgoes into sleep mode     http://phpdoc.info/chayism    ...
“Fucking AT&T.”                        —Me      Every time I use my cell ph                                 one in San Fra...
“Fuck Steve Jobs.   *blargh!*”         —Me               My upgrade to Lion
The real reasontheres no spyware     Chayismfor MacOS is thatits afraid of Terry     http://phpdoc.info/chayism           ...
“$haystack, $needle or $needle, $haystack? I  fucking hate PHP!”           —Me               In UR Website, c0ding UR sh  ...
Terry Chay beat theInternet... with only   Chayism    one quarter           http://phpdoc.info/chayism                    ...
Rock and Hard Place   Scylla and Charybdis
“80% of the effects comefrom 20% of the causes”               — Pareto                http://en.wikipedia.org/wik         ...
“Ruby is really good at what it does. The problem is that for  what Ruby [on Rails] does  really well, I can downloadMatt ...
Rails FAILs?1. (Software   Architectural)   Frameworks FAIL2. Ruby on Rails is a   (software   archiitectural)   framework...
Innovator’s     Dilemma    Clayton M. Christensen    Disruptive Technologieshttp://www.amazon.com/g                       ...
“[Disruptive Technologies] offered      less of what customers inestablished markets wanted and so  could rarely be initia...
“[Disruptive Technologies] suck.”            —(s horter)                Christi anson       C layton                      ...
“The S3 data storage that  Amazon and SmugMugshowed is impressive, but  the EC2 cloud stuff was   the most interesting, be...
iPod 2002     iPod Shuffle 2005   iPhone 2007(Hard Drive)    (first flash RAM)     (“today”)
Shared HostingManaged Hosting   AWS   Colocation
“Rails: It succeeds because it sucks.”                    est imatin g Rails        —M e, Mis                             ...
CruiseControl.rb   Continuous integration
Capistrano   Automated deployment
Vagrant   Automated virtualization
Puppet   Automated configuration
GitHub   Repo as a Service
Heroku   Managed RAILS cloud
3. Story of PHP
PHP’s S3• Simplicity• Scalability• Straighforwardness
“A project done in Java will cost 5 times as much, taketwice as long, and be harder to maintain than a projectdone in a sc...
“That a Java servlet performs better   than a PHP script, under optimal  conditions [has] nothing to do with   scalability...
“PHP is not about purity in CS principles or architecture; it is about solving the ugly web problem with an    admittedly ...
“PHP: It succeeds because it sucks.”                       —Me                          Simplicity + Scalability +        ...
Rock and Hard    PlaceYour drinking habits make me  very, very worried for the        future of PHP
AJAX  Rich sites do the UI in   Javascript and thecommunication via JSON
Speed      MemcachedBefore: PHP waits for dBNow: Performance and      Profiling
Terry Chay doesnt profile his code, he   Chayismjust commands it to     run better.         http://phpdoc.info/chayism     ...
Terry Chayssemicolons make     Chayismthat line of code  74% faster          http://phpdoc.info/chayism                   ...
HipHopConverts PHP to C++
Part 2  What: ThreeInfrastructures
1. Your Infrastructure   on a Shared Host
Lesson: Do More with Less
2. Infrastructure as a      Computer
“The datacenter is the      new box.”             son Ho ffman,        — Ja              Joyent                   http://p...
3. Infrastructure as a        Service
Traditional                  CloudPredict and purchase            ElasticShared->Colocation        Economies of Scale   Pa...
Facebook Open   Compute    Project    http://www.facebook.com/n                               otes/facebook-engineering/bu...
Open-source Data Center Design      Commodity Hardware    Power and cost efficiencies
“It’s usually in abusiness’ best interests  to commoditize its    complements.”           M arco A rment          —       ...
“Whenever iPhone succeeds, Google    succeeds.”         aniel A legre,     —D               -Pacific       f Goog le Asia H...
Infrastructure as  a Commodity    http://www.readwriteweb.c                              om/cloud/2011/04/        what-fac...
Part 3How: Three Levels of   Application
1. Infrastructure as a        Service
Slicehost
Start your own shit• database, Memcache, load balancing• svn/git/GitHub• trac, stats, (and other internal tools)• deployme...
Gentoo is for Ricers
Amazon Web Services
AWS Free                               http://aws.amazon.com/fre                                                        e/...
Three Tiers             EC2, S3, Database (RDS,   Base                   SimpleDB…)              CloudFront, Route 53, Ser...
“Basically [AWS] is  programmable  infrastructure”            f Barr,  Senior       —Jef        Eva  ngelis t AWS         ...
“Why Amazons cloud Titanic went down.”          —CNN             http://money.cnn.com/201                                 ...
2. Platform as a Service
dotCloudhttp://www.dotcloud.com/
Orchestra.io   http://orchestra.io/
ZippyKid http://zippykid.com/
Value adds• Language specification• Framework specialization/optimization• Application specialization• (ex. Expose tools fo...
3. Start Here -> Finish     Somewhere
Programmer as  Operations; Operations as Programmer   (DevOps)     http://en.wikipedia.org/wik                            ...
Start(up) yourself
yism  Security is low priority for Terry  Chay because he      Chaknows the internets     http://phpdoc.info/chayism      ...
PHP was never  about PHPWithout PHP, LAMP would just be LAM(e).
Battle   Woundshttp://terrychay.com/artic                           le/    cuts-and-scars.shtml
Cha yism         http://phpdoc.info/chayism                                   / When Terry Chay throws $10k into the air, ...
Haipingis smarter than you.
Tales of Virality            Terry Chay     OSCON (Business Track)August 28, 2011, 5PM (Room E146)
Terry Chay doesnt  get stage fright.     Stages getfrightened of Terry        Chay.
Terry Chay doesnt                                           get stage fright.@tychay                  http://             ...
Contact Me                                          Terry Chay doesnt                                           get stage ...
Contact Me                                                   Terry Chay doesnt                                            ...
Contact Me                                                    Terry Chay doesnt                                           ...
2011 07 Living without your Linemen—OSCON
2011 07 Living without your Linemen—OSCON
Upcoming SlideShare
Loading in …5
×

2011 07 Living without your Linemen—OSCON

2,704 views

Published on

http://www.oscon.com/oscon2011/public/schedule/detail/18893

If a website architect is the quarterback, then site operations is the offensive line—overworked, underappreciated, and only noticed when it fails. They make you look good. However, four years ago cloud computing networks like Amazon Web Services and Slicehost have appeared. While deficiencies in frameworks in other languages have forced those worlds to adopt Infrastructure-as-a-Service, the PHP world—with it’s ultra-cheap shared-hosting (on one end) and tradition of dominance on some of the most trafficked websites (on the other)—has been slow to move. But as the technology continues to disrupt, modern web engineers will be expected to use their programming skills to not only build, but also provision and maintain fast, scalable websites.

The efficiencies of a web-based language and experience in scalable website architecture offer a unique opportunity for programmers to transfer their skills when wearing a sysop hat. Not to mention some of the best libraries for programming them are written in PHP! When going from a small pet project to a go-live site, maybe we can learn to live without our linemen.

Published in: Technology
0 Comments
0 Likes
Statistics
Notes
  • Be the first to comment

  • Be the first to like this

No Downloads
Views
Total views
2,704
On SlideShare
0
From Embeds
0
Number of Embeds
17
Actions
Shares
0
Downloads
4
Comments
0
Likes
0
Embeds 0
No embeds

No notes for slide
  • Abstract:\nIf a website architect is the quarterback, then site operations is the offensive line—overworked, underappreciated, and only noticed when it fails. They make you look good. However, four years ago cloud computing networks like Amazon Web Services and Slicehost have appeared. While deficiencies in frameworks in other languages have forced those worlds to adopt Infrastructure-as-a-Service, the PHP world—with it’s ultra-cheap shared-hosting (on one end) and tradition of dominance on some of the most trafficked websites (on the other)—has been slow to move. But as the technology continues to disrupt, modern web engineers will be expected to use their programming skills to not only build, but also provision and maintain fast, scalable websites.\n\nThe efficiencies of a web-based language and experience in scalable website architecture offer a unique opportunity for programmers to transfer their skills when wearing a sysop hat. Not to mention some of the best libraries for programming them are written in PHP! When going from a small pet project to a go-live site, maybe we can learn to live without our linemen.\n\n
  • The need for rich sites\n
  • I meant to say, “When I created the website.” Geez! One slip of the tougue is like hanging chad in your mouth.\n
  • \n
  • Because WordPress started before IaaS existed, Automattic runs systems in a more standard manner. Instead this is the experiences I have advising friends startups. (If you want to see how Automattic runs, talk to Barry Abrahamson. My extent of Automattic’s structure stops at, “Barry! I think I broke something!”)\n
  • \n
  • I DON’T think I can do your job, like some of the people you’ve worked with. ;-)\n
  • I’m a PHP Programmer. At ZendCon, a PHP conference, in 2006, the host made these.\n\nhttp://www.flickr.com/photos/calevans/285999927/in/set-72157594355906012/\n
  • I’m a PHP Programmer. At ZendCon, a PHP conference, in 2006, the host made these.\n\nhttp://www.flickr.com/photos/calevans/285999927/in/set-72157594355906012/\n
  • And it occurred to me when someone puts your face on a deck of cards you must be a terrorist. (I guess he put these so that the Java Strike Force could hunt us down and kill us.) So, if some of what I say shocks you or seems a little extreme, you’ve been warned!\n\nhttp://www.flickr.com/photos/papernapkin/740945436/\n
  • Let me explain a running theme: during a presentation at a PHP conference a number of years ago I said this… I meant to say, “When I created the website.” Geez! One slip of the tongue is hanging chad in your mouth.\n
  • That inspired some in the community to put up this website (the PHP IRC channel robot also does this). Clearly, according to phpdoc (and the #php-* IRC robots), I am awesome. :-)\n
  • Here is another. Apparently I didn’t need to fly to get to Portland… (That’s enough Keynote transitions).\n
  • Start with the opening keynote. Three takeaways\n1) Lots on discussion of the performance of PHP: xdebug/cachegrind, inclued, HipHop analyser\n2) Diagram of a modern web stack\n3) Architecture considerations and deployment strategies\n
  • Let’s preface each section with an anecdote. This one concerns an article I wrote during Christmas of 2009.\n
  • A few startups ago, I worked with a guy who was a better programmer than any of us.\n\nOne day, we got into an argument over a piece of open source import code — written in Python — that he had ported to C++. He had just finished telling me how much faster he had made it, when I asked, “What’s the point in that? Now that you’ve rewritten it, you own the maintenance of it. There is no evidence this code is even the bottleneck.” \n\nAhmdahl's Law\n\nThe point? The code was crap, and he had fixed it — the massive improvement in efficiency was an added bonus.\n\n“Look you’re right. It’s true I prefer to use a crappy, ugly, underperformant language like PHP, and you crank out C++ like John Henry drives steel. But, while you’re busting code with a hammer in each hand, I’m the guy with the steam-powered jackhammer. Sure, you win, but your heart will burst, and you’ll die.”\n\n“And here’s the thing,” I added with a devilish grin, “There’s only one you; there are a lot of people like me out there.”\n\nImage from: http://www.postalmuseum.si.edu/artofthestamp/subpage%20table%20images/artwork/legends/John%20Henry/BIGjohnhenry.htm\n
  • My friend said. “J2EE programmers only write five lines of code a day.” He’s a Java programmer so he added “They’re give REALLY GOOD lines.”\n\nImage: http://www.flickr.com/photos/tychay/1388234558/\n
  • Here was a popular book from 2008. One interesting point Malcolm Gladwell makes is that it takes 10,000 hours of diligent practice to achieve mastery in nearly anything of worth. Pretty soon everyone is tweeting, all I have to do is spend 10k ours on it and I’ll master it.\n\nImage: http://www.flickr.com/photos/tychay/1388234558/\n
  • But let’s break that down. Gladwell stole this from this book, but he deliberately misrepresents how much 10k hours is. Also, not just any practice (diligent practice is hard!). He makes 10k hours sound achievable, but it isn’t—its 10 years of work doing somehing nobody, even masters like Bobby Fisher, Tiger Woods, YoYo Ma find unenjoyable.\n\nImage: http://www.flickr.com/photos/tychay/1388234558/\n
  • Similarly let’s look at what 1500 lines of code/day means. The Net result is I think C++ is crap because it only does 3 lines of (work) assembly for every line of code. PHP does much more (less efficiently).\n
  • Either choose what you spend to spend your time coding wisely or get a lot of people with chainsaws\n
  • \n
  • This is an analogy a co-worker once told me.\n
  • “You’re the architect, so you’re like the quarterback”\n
  • “I’m a programmer so I’m like the Running Back\n
  • …or wide Receiver.” I guess the difference between a Wide Receiver and a Running Back is one is back-end engineering and the other is front-end engineering. (Which is which? I don’t know.)\n
  • And Systems is like the big burley guys up front. They make you look good.\n\nYou don’t notice them until the site goes down (get a holding penalty)\n\nHow many times have I had to field questions about “what do these people do? I dont’ see them working?” And I have to explain, “You don’t want them to look like they’re working. If they do, something is VERY wrong.”\n\nStory about an Christmas e-mail.\n
  • “Have you tried turning it off and on?”\n\nThe Big Difference between SiteOps and an Offensive line is treating SiteOps won’t eat you out of house and home.\n
  • \n
  • There is someone from the Ruby on Rails world who should remain nameless. Let’s call him …“DHH.” This guys is the Jesus of the Ruby World—if Jesus shaved off his beard and starting dressing like a hipster.\n\n\nImage from: http://www.flickr.com/photos/x180/503574487/\nQuote From: http://www.wired.com/wired/archive/14.04/start.html?pg=3\n
  • And, according to his talks, he has only two words for me (and you).\n\nThe Gospel According to David.\n
  • Now, I’ve been known to swear on occasion . Sometimes I feel you could just replace all my talks with a recording of me saying “fuckity fuck fucking fuck fuck” (coincidentally, this is exactly what it sounds like when I’m conding).\n
  • But there is a world of difference between saying this…\n
  • And someone saying this to me (and you). This is awful because it ends debate.\n
  • And someone saying this to me (and you). It’s bad because it removes all room for debate and discussion. For instance: “Hey, I can’t run Rails in mod_ruby on Apache because of shared memory collisio.”\n
  • “Fuck You.” \n
  • “Hey, reads and writes on your website growth don’t scale evenly with Moore’s Law so you can’t simply buy a bigger machine to solve your problems.”\n
  • “Fuck You.” “Fuck You” is the “Your Momma” of the Rails world.\n
  • That isn’t to say I never give a directed fuck.\n
  • \n
  • That isn’t to say I never give a directed fuck.\n
  • That isn’t to say I never give a directed fuck.\n
  • I mean the guy should be thanking me. :-)\n
  • Even with PHP itself!\n
  • …Oh wait, maybe I am.\n\n(It must be true, I read it on the internet.)\n
  • Frameworks (like Rails) need to navigate stuck between a Rock and a Hard Place\n\nhttp://sarahdeming.typepad.com/spiralstaircase/2009/10/monsters-of-the-week-scylla-and-charybdis.html\n
  • The Rock is Pareto’s principle. It means as your codebase matures, 80% of your time will be spent on 20% of the code… that the Framework doesn’t handle (correctly). In that case you’re better off building a framework that works.\n
  • The hard place is maybe something pre-built solves your problem already.\n
  • Maybe the problem is already mappable to a forum software and you can download Phorum. Look how much work went into it.\n
  • So given the reasoning that Frameworks fail and Ruby on Rails is a framework. The Transitive Property of FAIL means that Rails FAILS. How is this wrong?\n
  • It gets back to this Harvard B-school (B stands for bullshit) book.\n\nImage: http://www.flickr.com/photos/tychay/1388234558/\n
  • Hard drive manufactures fell to smaller version, mainframes to the miniframe, miniframe to the workstation, workstations to the PC, Sears to WalMart, US Steel vs. small steel mills fail not because of failure to innovate, but because of the appearance of a disruptive technology\n
  • In all examples he gives the salient feature of a “disruptive technology” is that it is inferior to the one it replaces. The problem is even in the 1997 book (written during the dotCom boom) he mentioned a lot of examples of disruptive technologies (like Pets.com). Most of them are in the dead pool today.\n
  • So you might be thinking… Ahh Ruby on Rails is disruptive. No! That’s not it. Instead, Amazon’s Elastic Compute Cloud: Truly disruptive. On the same days as I got my hands on the PHP terrorist cards I showed on the beginning, this was what I was said during an interview. It is truely unique to be able to see a disruptive technology right from the outset. But cloud computing truly is. It’s inferior and more expensive (to scale) than colocation, but the writing was on the wall even then.\n
  • Now compare to IaaS.\n\n1. Starts out more expensive/worse (hell yes!)\n2. Different attributes far from mainstream\n3. Eventually supplants existing system? (OpenStack, OpenCompute -> Nebula announced today)\n
  • Now compare to IaaS (and the keynote talk today)\n\n1. Starts out more expensive/worse (hell yes!)\n2. Different attributes far from mainstream\n3. Eventually supplants existing system? (OpenStack, OpenCompute -> Nebula announced today)\n\nNote that shared hosting, managed hosting and colo aren’t going away, they’re shifting to the extremes. We still have supercomputers and compute clouds in a PC/laptop world. Apple still makes the iPod and even a model with a hard drive in it.\n
  • Since Rails doesn’t work in shared hosts (remember that joke earlier?), they adopted EC2 (and other things)! And now they are thriving: Capistrano, Ruby version so CruiseControl, GitHub, Heroku… All of it owes it’s life to the disruption of IaaS. And Rails owes its newfound niche to its deficiency in a shared hosting environment.\n
  • \n
  • \n
  • \n
  • \n
  • Yes, People can do stupid things like try to (re)write Map-Reduce in Rails (without a Reduce function), but that attitude allows them to adopt new things like Git and give us GitHub. The previous examples are Ruby, this is Ruby on Rails.\n
  • A big value add in IaaS.\n
  • \n
  • This is why I choose PHP and why it has become the most popular web-language in the world. It’s our S3.\n
  • SIMPLICITY Basically: It’s so simple any moron can learn it.\n
  • SCALABLE Basically: Shared nothing means it has nothing to hang yourself with.\n
  • STRAIGHTFORWARD Basically: PHP was only designed to solve the web problem. Solve other problems with something else (and link to it in PHP).\n
  • This is the dirty little secret of web development: anyone can string together a “SELECT * from users where email=?”, what’s so hard about web development? So if you boil those S3 down to a single S, PHP too succeeds because it sucks. But that suckiness has 40 million developers worldwide!\n
  • And now, PHP is ready for it’s own Schylla and Charibdis.\n\nImage from: http://www.flickr.com/photos/davidcoallier/2207776375/\n
  • The need for rich ajax driven sites obsoletes traditional advantages fo templating\n
  • PHP is an embedded templating language. What is the advantage of a template when everything is in Ajax?\n\nReference: http://antigonemythology.wikispaces.com/file/view/ajax.jpg/33165025/ajax.jpg\n
  • Profiling PHP is now a big deal because speed of PHP is becomming the bottleneck\n
  • means PHP is no longer waiting on the database. PHP is now the bottleneck. The language need to be performant and developers need to profile. (Note most developers don’t know how to profile code (in PHP it’s with XHProf and kCacheGrind/XDebug) or how to optimize their builds to be performant (replacing Apache with NginX/PHP FPM or using HipHop).\n\nReference: http://web1syndication.com/wp-content/uploads/2010/05/speed.jpg\n
  • …except me.\n
  • I’ll just chuck in some semicolons.\n
  • Why did PHP 6 failed? It failed due to lack of participation. Nobody gave a shit about i18n and all the stuff people wanted (the stuff that helps in performance or building rich Ajax driven websites) was put in PHP 5.2 and 5.3\n
  • Let’s talk about the “language needs to be performant part.” We’ll do this with an introductory vignette to part 2. A person at Facebook invented HipHop. Explain how this is different from a JIT (Java, dotNet, JRuby, etc.)\n
  • \n
  • \n
  • This part we discuss the three infrastructures of operations.\n
  • This is how PHP became popular. Look at WordPress: 1 click to install on Dreamhost, GoDaddy and the like. (And remember your problem may be mappable to wordpress)\n
  • They’re taking away your O-line. Nowadays your ops team looks like this year’s Pittsburgh Steelers. The most difficult part of programming is not in the code, it is in the process. You have to do more with less: We have less testing, so we can release more often. We automate it so we can eliminate user-testing… we had to become more agile for releasing… Now we’ll have to become more agile at hosting. Shared hosting was the start of PHP, but it isn’t it’s end.\n
  • Point is automating deployment and testing so you can be agile?\nReleasing often (story of Tagged)\nWhat does that mean?\n
  • Most of the discussion isn't in the code, it's in the process. The process is the most ignored part of programming.\n
  • This is how a modern high-performance and scalable website (like Facebook) is built.\n
  • CPU, RAM, Disk -> Web Server, Memcached, Database.\n\nSomeday you’ll be buying datacenter like you buy a PC (only it’s in the cloud). Or maybe it’s that you’re now buying PC like you buy everything else (Think DropBox or BackBlaze—one of which is built on Amazon Cloud services).\n\nWe consume the same thing already today, they’re called web services. Now simply make the infrastructure a service…\n
  • Oh yeah your PC connecting to the internet? That’s your website consuming web services. Remember PCs before the internet? They were islands: Ask yourself why you liked Lorna’s talk.\n
  • …this is the cloud computing thing\n
  • From “Host Your Web-Site in the Cloud” by Jeff Barr of Amazon\n\nThe big thing is the new model which is pay as you go. It may be more expensive at scale, but you don’t have to anticipate growth with CAPEX.\n
  • Before we get to the last part, I want to revisit that “data center is a box” and something that happened recently. Facebook launched the “Facebook Open Compute Project”. What is it?\n
  • Announcement: http://www.facebook.com/notes/facebook-engineering/building-efficient-data-centers-with-the-open-compute-project/10150144039563920\n\nCommodity hardware: http://joyeur.com/2011/04/07/facebooks-open-compute-the-dc-is-the-new-server-and-the-rise-of-the-taiwanese-tigers/\n\nhttp://www.readwriteweb.com/cloud/2011/04/what-facebooks-opencompute-mea.php\n
  • “On a large scale like this … “opening” something is almost always an effort to commoditize it, leveling the playing field as much as possible and marginalizing competitive advantages that others might have had. [ QUOTE ABOVE ] “Nobody “opens” the parts of their business that make them money, maintain barriers to competitive entry, or otherwise provide significant competitive advantages”\n
  • Microsoft and Open PC hardware (eliminated dependency on IBM (and Intel))\nGoogle and applications (browser), platforms (Android), web tech (video) because search business:\nApple and apps\n(I actually don’t look at it as iPhone versus Android. iPhone is a very strong driver of query growth for Google. We also monetize apps through the iPhone…we actually benefit from iPhone’s growth.”)\n
  • “But the benefits of commoditization in this area to Facebook are very small…My best guess is that this is primarily for recruiting engineering talent” —Marco Arment.\n\nHe’s wrong with that part. The benefit is to turn Infrastructure into a Commodity. (Dependence on Amazon tools)\n\nRockerfeller and Trains. Impact on people who build large datacenter, Facebook free to move to Amazon services.\n\nWhat is being open sourced? Infrastructure\nOpen Source -> Commoditize your complement\nTherefore: Infrastructure as a Commodity\n\nIf you are a operations person now, then you better get into programming or your next job application will be to a company like Joyent or Amazon.\n
  • \n
  • \n
  • This is what I use. Bought out by RackSpace. There are others\n
  • You can go this route but it is a lot of work.\nOn the plus side, since you manage everything you have the least dependencies and are positioned right now to move to wherever is cheapest.\n
  • Just don’t make your server look like this.\nOops I offended the one person in the room who uses Gentoo.\nBut look you dont want some person like me using your OS: Look I recompiled everything with CFLAGS=-O9\n
  • \n
  • \n
  • The way to look at the tiers is: you need the base, the services are a nice convenience, and you should probably avoid the management as other competing companies (built on the Base) will do it better/cheaper.\n\nEC2\nS3\nDatabase (RDS, SimpleDB,etc)\n\nAmazon Cloudfrount\nAmazon Route 53\nAmazon Messaging: SQS, SNS\nAmazon Flexible Payment Systems (FPS): their version of PayPal API\nAmazon Mechanical Turk\n\nAWS Management Console\nAWS Elastic Beanstalk - Java.war file creates EC2, etc. instances\nAWS toolkit for Eclipse, Java, PHP etc.\nAWS Virtual Private Cloud (isolated network)\n\n
  • This is where programming comes in.\nThere are libraries for this.\n
  • \n
  • Story of 365Main going down. Story of WP outages\n\nYet, like the famous ocean liner, Amazon's cloud crashed that week, taking with it Reddit, Quora, FourSquare, Hootsuite, parts of the New York Times, ProPublica and about 70 other sites\n
  • \n
  • Automated deploymnet (many platforms)\n
  • This is trying to be the Heroku of the PHP world.\n\nBasically you just point it to your PHP repository and it handles the rest.\nAdd ons\n- Job queue\n- Error logging\n- Couchdb\n- Memcached\n- Mongodb\n\nIt even supports Frameworks like:\nFrameworks:\n- Zend Frameowork\n- Symphony\n- Lithum\n- Solar PHP\n- FRAPI\n\nFramework optimization handled by them is a huge possible performance gain where they can give you more bang for your Amazon buck than you can yourself. Just like Heroku does with Rails.\n
  • Frameworks:\n- Zend Frameowork\n- Symphony\n- Lithuum\n- Solar PHP\n- FRAPI\n
  • A bit about Frameworks advantages (like Rails)\n
  • Vid Luther. Built on AWS. WordPress.\n
  • \n
  • \n
  • Operations requires programming\nProgramming no longer has operations.\nPersonality makes for different peeps\n
  • What is the barrier to entry now? vs. when you needed servers and colocation?\n
  • Actually this one is true. Security is a low priority and I use services like BackBlaze and DropBox (one basically an Amazon S3 instances)\n
  • Built on AWS\n
  • Built on AWS\n
  • \n
  • Performance is important and the performance outside PHP itslef\n
  • A Java person says, “Look at it this way, Java is like a knife. A knife can do many things: a good one is essential for cooking, it can cut open packages, cut a cord, and it really comes in handy in a fist-fight. Java can do a lot of things and do them very well.”\nA PHP person, if they had to fight, would rather have something that is designed to solve that one problem, and solve it well.\nA PHP person says, “That knife is nice, but I’d rather have a gun.”\n
  • \n
  • \n
  • It’s on the business track, so after seeing this PHP programmer try to be an system adminstrator, now you see an engineer talk to biz guys.\n\n
  • @tychay\ntychay@php.net\nhttp://terrychay.com/\n\nhttp://joind.in/talk/view/3351\n\nPromise to blog more\n
  • @tychay\ntychay@php.net\nhttp://terrychay.com/\n\nhttp://joind.in/talk/view/3351\n\nPromise to blog more\n
  • @tychay\ntychay@php.net\nhttp://terrychay.com/\n\nhttp://joind.in/talk/view/3351\n\nPromise to blog more\n
  • @tychay\ntychay@php.net\nhttp://terrychay.com/\n\nhttp://joind.in/talk/view/3351\n\nPromise to blog more\n
  • @tychay\ntychay@php.net\nhttp://terrychay.com/\n\nhttp://joind.in/talk/view/3351\n\nPromise to blog more\n
  • @tychay\ntychay@php.net\nhttp://terrychay.com/\n\nhttp://joind.in/talk/view/3351\n\nPromise to blog more\n
  • @tychay\ntychay@php.net\nhttp://terrychay.com/\n\nhttp://joind.in/talk/view/3351\n\nPromise to blog more\n
  • @tychay\ntychay@php.net\nhttp://terrychay.com/\n\nhttp://joind.in/talk/view/3351\n\nPromise to blog more\n
  • So all the speakers at this conference need to send my my cut stat! (That goes double for you, Paul) Triple?\n
  • 2011 07 Living without your Linemen—OSCON

    1. 1. Living withoutyour Linemen OSCON Portland, OR: June 27, 2011, 5pm
    2. 2. Not aboutAutomatticI’m not in Systems and OperationsAutomattic doesn’t work this way
    3. 3. Me = Typical Engineer• Mercurial/ Tempermental• Lack of Attention to Detail• Can’t multitask
    4. 4. Me = Least Qualifiedto be Lecturing You Typical Engineer except in one way
    5. 5. Who am I?
    6. 6. Who am I?Me (and others) on a deck of cards
    7. 7. PHPTerroristHave a nice Chay!
    8. 8. “…when I created the Web” — (not) A l Gore
    9. 9. Cha yism http://phpdoc.info/chayism / One ounce of Terry Chay contains seven pounds of awesome
    10. 10. Chayism http://phpdoc.info/chayism /
    11. 11. Terry Chay does not walk, or run, or Chayism drive, or take an http://phpdoc.info/chayism airplane to a place. / He simply uses aKeynote transition.
    12. 12. 1500 Lines Of Code PHP Advent 2009 http://phpadvent.org/2009/ 1500-lines-of- code-by-terry-chay
    13. 13. John Henry of C++
    14. 14. 1500 Lines of Code/Day (max) “Except Java”Java: It only takes three years to put in a hard days work!
    15. 15. Outliers Malcolm Gladwell 10,000 Hours of Diligent Practicehttp://www.amazon.com/g p/product/ 0316017922?tag=terrych ay-20
    16. 16. Talent is Overrated Geoff Colvin10,000 Hours = 20/week week * every week * 10 years!http://www.amazon.com/g p/product/ 0316017922?tag=terrych ay-20
    17. 17. 1500 lines of codeHalf a Million Line codebase = Peak Day, Every Day, 1Year
    18. 18. Terry Chay doesnt write code, he just Chayism thinks it, andminions do it for him http://phpdoc.info/chayism /
    19. 19. Part 1 Why: ThreeObservations
    20. 20. 1. SiteOps are your offensive line http://terrychay.com/artic le/special- sysadmin-appreciation-day. shtml
    21. 21. Quarterback Site Architect
    22. 22. Running Back Programmer
    23. 23. Wide Receiver Programmer
    24. 24. Offensive Line System Operations
    25. 25. Keep YourLine Happy Last Friday in Julyhttp://www.sysadminday.co m/
    26. 26. 2. Story of (Ruby on) Rails
    27. 27. “The Hottest Hacker on the Earth.” — WIRED Wired 14.04 page 3
    28. 28. “Fuck You.” nemeier Hansson —D avid Hei David 3:16
    29. 29. “fuckity fuck fucking fuck fuck.” —E XPLICIT TAG #TCFC +=5
    30. 30. “coding these web appsthemselves involves a lot of swearing—a lot ofblood, sweat and swear.” —Me http://shiflett.org/blog/2006 / aug/blood-sweat-and-swea r- terry-chay-on-pro-php-podc ast
    31. 31. “Fuck You.” nemeier Hansson —D avid Hei David 3:16
    32. 32. “I can’t run Rails inmod_ruby on Apache on a shared host” h o has ev er tried —A nyone w http://blog.dreamhost.com / 2008/01/07/how-ruby-on-r ails- could-be-much-better/
    33. 33. “Fuck You.” nemeier Hansson —D avid Hei David 3:16
    34. 34. “Read/Writes as websites grow don’t scale evenly with Moore’s Law, so a bigger machine isn’t solving my database problems.” e who h as built—Anyon http://terrychay.com/artic th real le/ bsite wi sharting-on-sharding.shtm l a we growth (hock ey stick)
    35. 35. “Fuck You.” nemeier Hansson —D avid Hei David 3:16
    36. 36. “Fuck Comcast.” —Me Every time the intertubes get tied
    37. 37. The Internet doesnt go down, Terry Chayism Chays laptop justgoes into sleep mode http://phpdoc.info/chayism /
    38. 38. “Fucking AT&T.” —Me Every time I use my cell ph one in San Francisco
    39. 39. “Fuck Steve Jobs. *blargh!*” —Me My upgrade to Lion
    40. 40. The real reasontheres no spyware Chayismfor MacOS is thatits afraid of Terry http://phpdoc.info/chayism / Chay
    41. 41. “$haystack, $needle or $needle, $haystack? I fucking hate PHP!” —Me In UR Website, c0ding UR sh it
    42. 42. Terry Chay beat theInternet... with only Chayism one quarter http://phpdoc.info/chayism /
    43. 43. Rock and Hard Place Scylla and Charybdis
    44. 44. “80% of the effects comefrom 20% of the causes” — Pareto http://en.wikipedia.org/wik i/ Pareto_principle
    45. 45. “Ruby is really good at what it does. The problem is that for what Ruby [on Rails] does really well, I can downloadMatt Mullenweg’s WordPress” —Me http://terrychay.com/artic le/is-ruby- the-dog-and-php-the-dogfoo d.shtml
    46. 46. Rails FAILs?1. (Software Architectural) Frameworks FAIL2. Ruby on Rails is a (software archiitectural) framework.3. Ergo…
    47. 47. Innovator’s Dilemma Clayton M. Christensen Disruptive Technologieshttp://www.amazon.com/g p/product/ 0060521996?tag=terrych ay-20
    48. 48. “[Disruptive Technologies] offered less of what customers inestablished markets wanted and so could rarely be initially employed there. They offered a differentpackage of attributes valued only inemerging markets remote from, and unimportant to, the mainstream.” Chris tianson—Clayton Innovator’s Dilemma
    49. 49. “[Disruptive Technologies] suck.” —(s horter) Christi anson C layton Innovator’s Dilemma
    50. 50. “The S3 data storage that Amazon and SmugMugshowed is impressive, but the EC2 cloud stuff was the most interesting, because it is disruptive.” sting Thing @ ost Intere —The M ZendCon Fall 2006
    51. 51. iPod 2002 iPod Shuffle 2005 iPhone 2007(Hard Drive) (first flash RAM) (“today”)
    52. 52. Shared HostingManaged Hosting AWS Colocation
    53. 53. “Rails: It succeeds because it sucks.” est imatin g Rails —M e, Mis Capistrano, CruisceControl.rb, GitHub, a gajillion admin consoles fo r AWS
    54. 54. CruiseControl.rb Continuous integration
    55. 55. Capistrano Automated deployment
    56. 56. Vagrant Automated virtualization
    57. 57. Puppet Automated configuration
    58. 58. GitHub Repo as a Service
    59. 59. Heroku Managed RAILS cloud
    60. 60. 3. Story of PHP
    61. 61. PHP’s S3• Simplicity• Scalability• Straighforwardness
    62. 62. “A project done in Java will cost 5 times as much, taketwice as long, and be harder to maintain than a projectdone in a scripting language such as PHP or Perl.” ip Gree nspun —Phill http://blogs.law.harvard.e du/ philg/2003/09/20/
    63. 63. “That a Java servlet performs better than a PHP script, under optimal conditions [has] nothing to do with scalability. The point is can your application continue to deliver consistent performance as volumeincreases. PHP delegates all the ‘hard stuff’ to other systems.” H arry F uecks — http://blogs.sitepoint.com/t he- j2ee-guy-still-doesnt-get-php /
    64. 64. “PHP is not about purity in CS principles or architecture; it is about solving the ugly web problem with an admittedly ugly, but extremely functional and convenient solution. If you are looking for purity, you are inthe wrong boat. Get out now before you get hit by a wet cat!” Ras mus Lerdorf — http://news.php.net/article. php? group=php.internals&articl e=2715
    65. 65. “PHP: It succeeds because it sucks.” —Me Simplicity + Scalability + Straightforward = Suck = Success!
    66. 66. Rock and Hard PlaceYour drinking habits make me very, very worried for the future of PHP
    67. 67. AJAX Rich sites do the UI in Javascript and thecommunication via JSON
    68. 68. Speed MemcachedBefore: PHP waits for dBNow: Performance and Profiling
    69. 69. Terry Chay doesnt profile his code, he Chayismjust commands it to run better. http://phpdoc.info/chayism /
    70. 70. Terry Chayssemicolons make Chayismthat line of code 74% faster http://phpdoc.info/chayism /
    71. 71. HipHopConverts PHP to C++
    72. 72. Part 2 What: ThreeInfrastructures
    73. 73. 1. Your Infrastructure on a Shared Host
    74. 74. Lesson: Do More with Less
    75. 75. 2. Infrastructure as a Computer
    76. 76. “The datacenter is the new box.” son Ho ffman, — Ja Joyent http://pro.gigaom.com/ 2010/11/the-data-center-is - the-new-box-are-you-ready /
    77. 77. 3. Infrastructure as a Service
    78. 78. Traditional CloudPredict and purchase ElasticShared->Colocation Economies of Scale Pay for server Pay as you go Capitalize No up-front investment Fixed Cost Variable CAPEX OPEXdiscreet allocations fine-grained allocation disassociated costs associated costs staging, RAAD experimentation is cheap9
    79. 79. Facebook Open Compute Project http://www.facebook.com/n otes/facebook-engineering/build ing-efficient- data-centers-with-the-open -compute-
    80. 80. Open-source Data Center Design Commodity Hardware Power and cost efficiencies
    81. 81. “It’s usually in abusiness’ best interests to commoditize its complements.” M arco A rment — http://www.marco.org/201 1/04/09/ facebooks-open-compute-p roject
    82. 82. “Whenever iPhone succeeds, Google succeeds.” aniel A legre, —D -Pacific f Goog le Asia Head o http://www.adnews.com.au/ news/ google-we-want-iphone-to-gr ow
    83. 83. Infrastructure as a Commodity http://www.readwriteweb.c om/cloud/2011/04/ what-facebooks-opencompu te-mea.php
    84. 84. Part 3How: Three Levels of Application
    85. 85. 1. Infrastructure as a Service
    86. 86. Slicehost
    87. 87. Start your own shit• database, Memcache, load balancing• svn/git/GitHub• trac, stats, (and other internal tools)• deployment solution like Capistrano (Ruby)
    88. 88. Gentoo is for Ricers
    89. 89. Amazon Web Services
    90. 90. AWS Free http://aws.amazon.com/fre e/• 750 hours of Amazon EC2 Linux Micro Instance usage (613 MB of memory and 32-bit and 64-bit platform support) – enough hours to run continuously each month*• 750 hours of an Elastic Load Balancer plus 15 GB data processing*• 10 GB of Amazon Elastic Block Storage, plus 1 million I/Os, 1 GB of snapshot storage, 10,000 snapshot Get Requests and 1,000 snapshot Put Requests*
    91. 91. Three Tiers EC2, S3, Database (RDS, Base SimpleDB…) CloudFront, Route 53, Services SQS, SMS, FPS, Mechanical Turk Managment Console, ElasticManagement Beanstalk, Toolkit for Eclipse,Virtual Private Cloud
    92. 92. “Basically [AWS] is programmable infrastructure” f Barr, Senior —Jef Eva ngelis t AWS http://www.amazon.com/g p/product/ 0980576830?tag=terrych ay-20
    93. 93. “Why Amazons cloud Titanic went down.” —CNN http://money.cnn.com/201 1/04/22/ technology/amazon_ec2_c loud_outage/?
    94. 94. 2. Platform as a Service
    95. 95. dotCloudhttp://www.dotcloud.com/
    96. 96. Orchestra.io http://orchestra.io/
    97. 97. ZippyKid http://zippykid.com/
    98. 98. Value adds• Language specification• Framework specialization/optimization• Application specialization• (ex. Expose tools for optimization, deployment, continuous testing, etc.)• (ex. NginX + PHP-FPS (fastcgi) over Apache)• (ex. HipHop compile and optimization for
    99. 99. 3. Start Here -> Finish Somewhere
    100. 100. Programmer as Operations; Operations as Programmer (DevOps) http://en.wikipedia.org/wik i/DevOps
    101. 101. Start(up) yourself
    102. 102. yism Security is low priority for Terry Chay because he Chaknows the internets http://phpdoc.info/chayism / got his back[ups]
    103. 103. PHP was never about PHPWithout PHP, LAMP would just be LAM(e).
    104. 104. Battle Woundshttp://terrychay.com/artic le/ cuts-and-scars.shtml
    105. 105. Cha yism http://phpdoc.info/chayism / When Terry Chay throws $10k into the air, he doesntbother picking it up
    106. 106. Haipingis smarter than you.
    107. 107. Tales of Virality Terry Chay OSCON (Business Track)August 28, 2011, 5PM (Room E146)
    108. 108. Terry Chay doesnt get stage fright. Stages getfrightened of Terry Chay.
    109. 109. Terry Chay doesnt get stage fright.@tychay http:// Stages get terrychay.com/ frightened of Terry “I promise to blog Chay. tychay@php.net more.”
    110. 110. Contact Me Terry Chay doesnt get stage fright.@tychay http:// Stages get terrychay.com/ frightened of Terry “I promise to blog Chay. tychay@php.net more.”
    111. 111. Contact Me Terry Chay doesnt get stage fright. @tychay http:// Stages get terrychay.com/ frightened of Terry “I promise to blog Chay. tychay@php.net more.” http://www.oscon.com/ Leave aoscon2011/public/schedule/ comment! detail/18893
    112. 112. Contact Me Terry Chay doesnt get stage fright. @tychay http:// Stages get terrychay.com/ frightened of Terry “I promise to blog Chay. tychay@php.net more.” http://www.oscon.com/ Leave a oscon2011/public/schedule/ comment! detail/18893 Slides fromhttp://www.slideshare.net/tychay this talk posted soon!

    ×