7. Scope
Automation + Culture = Agility
• Infrastructure Automation Approaches
• Infrastructure & Automation Best
Practices
• Cultural Pitfalls
Friday, November 16, 12
8. Scope
Automation + Culture = Agility
• Infrastructure Automation Approaches
• Infrastructure & Automation Best
Practices
• Cultural Pitfalls
• Making more awesome
Friday, November 16, 12
9. Scope
Automation + Culture = Agility
• Infrastructure Automation Approaches
• Infrastructure & Automation Best
Practices
• Cultural Pitfalls
• Making more awesome
What this talk is not
• Chef vs. Puppet
• Cloud All The Things!!!
• How to structure your
Organization
• Which Development Model to
adopt
Friday, November 16, 12
40. • Labor intensive
• Error prone
• Hard to reproduce
• Unsustainable
http://www.flickr.com/photos/pureimaginations/4805330106/
Manual Configuration
Friday, November 16, 12
41. • Typically very brittle
• Throw away, one off scripts
• grep sed awk perl
• curl | bash
http://www.flickr.com/photos/40389360@N00/2428706650/
Scripting
Friday, November 16, 12
42. • NFS mounts
• rdist
• scp-on-a-for-loop
• rsync on cron
http://www.flickr.com/photos/walkadog/4317655660
File Distribution
Friday, November 16, 12
43. for i in `cat servers.txt` ;
do scp ntp.conf root@
$i:/etc/ntpd.conf ; done
for i in `cat servers.txt` ;
do ssh root@$i /etc/
init.d/ntpd restart ; done
for i in `cat servers.txt` ;
do ssh root@$i
chkconfig ntpd on ; done
• ^ does not scale
http://www.flickr.com/photos/alexerde/3479006495
This used to be awesome.
Friday, November 16, 12
44. • Cluster SSH
• ISConf
• Golden Images
Execution Management
Friday, November 16, 12
46. Typical Boring Infrastructure
Jboss App
Memcache
Postgres Slaves
Postgres Master
NagiosGraphite
• Move SSH off port 22
• Lets put it on 2022
Friday, November 16, 12
47. Typical Boring Infrastructure
Jboss App
Memcache
Postgres Slaves
Postgres Master
NagiosGraphite
• Move SSH off port 22
• Lets put it on 2022
• edit /etc/ssh/sshd_config
Friday, November 16, 12
48. Typical Boring Infrastructure
Jboss App
Memcache
Postgres Slaves
Postgres Master
NagiosGraphite
• Move SSH off port 22
• Lets put it on 2022
• edit /etc/ssh/sshd_config
1 2
3
4
5
6
Friday, November 16, 12
52. Different IP Addresses?
Jboss App
Memcache
Postgres Slaves
Postgres Master
NagiosGraphite
• Invalid configs!
Friday, November 16, 12
53. Systems Integration
• Keep a list of current
resources
• Collect vast amounts of data
on those resources
• Quickly search through stacks
of current resource data
• Generate your Infrastructure
Topology from a current
source of truth
http://www.flickr.com/photos/fotos_medem/3399096196/
Friday, November 16, 12
54. So when this...
Jboss App
Memcache
Postgres Slaves
Postgres Master
NagiosGraphite
Friday, November 16, 12
60. Managing Complexity Today
How Do we Manage This
at Cloud Scale?
• Thousands of infrastructure
dependencies and
configurations needed for
each change.
• Huge Amounts of Time
• Increased Cost of
Correction of Manual Errors
• Huge Need for Talent
• Risk of Critical Skills
Shortage
Friday, November 16, 12
62. but it was “secret sauce”
Friday, November 16, 12
63. everyone else was here
... inexperienced & poorly equipped
for the world they must now
operate in.
Friday, November 16, 12
64. everyone else was here
... inexperienced & poorly equipped
for the world they must now
operate in.
Friday, November 16, 12
65. Infrastructure
"It is common to think in terms of individual
machines rather than view an entire
infrastructure as a combined whole"
“A good infrastructure, whether departmental,
divisional, or enterprise-wide, is a single loosely-
coupled virtual machine, with hundreds or
thousands of hard drives and CPU's.”
-- Bootstrapping an Infrastructure USENIX LISA ’98
Friday, November 16, 12
66. Infrastructure as Code
• Programmatically provision and
configure
• Treat like any other code base
• Gives you tools to manage
complexity while being flexible
enough to evolve with your
Infrastructure
• Reconstruct the business from
code repository, data backup, and
baremetal resources
Friday, November 16, 12
67. Declarative Syntax
• Define policy
• Say what, not how
• Abstraction between platforms
• Many positive side effects
Friday, November 16, 12
68. Idempotence
• You’ll hear this a lot
• Property of declarative interface
• Eliminates brittleness of
scripting
• Identity function: f(x)=x
• Safe to repeat
Friday, November 16, 12
69. Chef is a Tool
http://www.flickr.com/photos/wessexandy/7690486884/sizes/c/in/pool-96164123@N00/
Friday, November 16, 12
70. Wax Philosophical
• We are artists & masters of our
craft
• Everyone needs great tools
• Nobody remember’s Picasso’s
paintbrush
http://www.flickr.com/photos/vgm8383/2686128924/sizes/l/
Friday, November 16, 12
71. The core ideas in this talk:
Automation + Culture =
AGILITY!
Friday, November 16, 12
72. The core ideas in this talk:
Automation + Culture =
AGILITY!
Friday, November 16, 12
77. Traditional thinking
Dev’s job is to add new features
Ops’ job is to keep the site stable and fast
http://www.flickr.com/photos/stewart/461099066/
Slide Courtesy of John Allspaw - http://www.slideshare.net/jallspaw/10-deploys-per-day-dev-and-ops-cooperation-at-flickr
Friday, November 16, 12
78. Ops’ job is NOT to keep the site
stable and fast
Dev’s job is NOT to add new
features
Friday, November 16, 12
79. OUR job
is to ENABLE our business
Friday, November 16, 12
93. Slide Courtesy of John Allspaw - http://www.slideshare.net/jallspaw/ops-metametrics-the-currency-you-pay-for-change
Friday, November 16, 12
94. Image Courtesy of John Allspaw - http://www.slideshare.net/jallspaw/ops-metametrics-the-currency-you-pay-for-change
RAAAWR!!!
I’m SCARY!
Friday, November 16, 12
95. Slide Courtesy of John Allspaw - http://www.slideshare.net/jallspaw/ops-metametrics-the-currency-you-pay-for-change
Friday, November 16, 12
96. Slide Courtesy of John Allspaw - http://www.slideshare.net/jallspaw/ops-metametrics-the-currency-you-pay-for-change
Friday, November 16, 12
97. Images Courtesy of John Allspaw - http://www.slideshare.net/jallspaw/ops-metametrics-the-currency-you-pay-for-change
I can haz
cuddle?
Friday, November 16, 12
102. Stuff Suits Care About
• Visibility & Accountability
• Reduce Risk
• Business Agility
Friday, November 16, 12
103. Stuff Engineers care about
• Change when we need it
• Innovate Faster
• Constant Improvements
• Application & Site Resiliency
Friday, November 16, 12
106. Recap
•Step 1) Automate your Infrastructure
•Step 2) Bridge the Cultural Divide
Friday, November 16, 12
107. Recap
•Step 1) Automate your Infrastructure
•Step 2) Bridge the Cultural Divide
•Step 3) Profit!
Friday, November 16, 12
108. Recap
•Step 1) Automate your Infrastructure
•Step 2) Bridge the Cultural Divide
•Step 3) Profit!
•Automation + Culture = Agility
Friday, November 16, 12
109. Try it out!
• Hosted Chef is a SaaS product hosted by Opscode
• http://manage.opscode.com
• Our wiki: http://wiki.opscode.com
• Fast start guide:
• http://wiki.opscode.com/display/chef/Fast+Start+Guide
• Our Community site: http://community.opscode.com
• Cookbooks in our Github account: http://github.com/opscode/cookbooks
• The materials for our 3-day Chef Fundamentals class are online:
• https://github.com/opscode/chef-fundamentals
Friday, November 16, 12
110. Supported Platforms
• Ubuntu (10.04, 10.10, 11.04, 11.10, 12.04)
• Debian (5.x, 6.x)
• RHEL & CentOS (5.x, 6.x)
• Fedora 10+
• SUSE Enterprise (11.2)
• openSUSE (12.1)
• Solaris (5.9, 5.10, 5.11 -- x86 and SPARC)
• Mac OS X (10.4, 10.5, 10.6, 10.7)
• Windows 7
• Windows Server 2003 R2, 2008, 2008 R2
Friday, November 16, 12
111. Additional Resources
• OpscodeYoutube Channel:
• http://www.youtube.com/opscode
• Jesse Robbins, Changing Culture & Being a force for Awesome
• http://www.youtube.com/watch?v=OU8ihx3nT6I
• Matt Ray on Automating Continuous Deployment
• http://www.opscode.com/blog/2012/11/13/automating-continuous-
deployment-wchef/
• Continuous Delivery by Jez Humble & David Farley
• http://continuousdelivery.com/
Friday, November 16, 12
113. Questions?
• On freenode: #chef and #chef-hacking
• http://lists.opscode.com
• http://tickets.opscode.com
• http://help.opscode.com
• @opscode and @opscode_status on Twitter
Friday, November 16, 12