puppet at the centre of everything

68
Puppet at the centre of everything

Upload: puppet-labs

Post on 27-Jun-2015

588 views

Category:

Technology


3 download

DESCRIPTION

"Puppet at the centre of everything" by David Mytton of Server Density at Puppet Camp London 2013. Find the video here: http://puppetlabs.com/community/puppet-camp

TRANSCRIPT

Page 1: Puppet at the Centre of Everything

Puppet at the centre of everything

Page 2: Puppet at the Centre of Everything

David Mytton

Woop Japan!

Page 3: Puppet at the Centre of Everything
Page 4: Puppet at the Centre of Everything

Server Density Architecture

•100 servers - Ubuntu 12.04

Page 5: Puppet at the Centre of Everything

Server Density Architecture

•100 servers - Ubuntu 12.04

•50% virtual

Page 6: Puppet at the Centre of Everything

Server Density Architecture

•100 servers - Ubuntu 12.04

•Nginx, Python, MongoDB

•50% virtual

Page 7: Puppet at the Centre of Everything

Server Density Architecture

•100 servers - Ubuntu 12.04

•Nginx, Python, MongoDB

•25TB data per month

•50% virtual

Page 8: Puppet at the Centre of Everything

Use cases

• Config

Page 9: Puppet at the Centre of Everything

Use cases

• Config

• Failover

Page 10: Puppet at the Centre of Everything

Use cases

• Config

• Code deploys

• Failover

Page 11: Puppet at the Centre of Everything

Use cases

• Config

• Code deploys

• System updates

• Failover

Page 12: Puppet at the Centre of Everything

• Base manifest

Config

Page 13: Puppet at the Centre of Everything
Page 14: Puppet at the Centre of Everything
Page 15: Puppet at the Centre of Everything

• Base manifest

Config

• Sub manifests

Page 16: Puppet at the Centre of Everything
Page 17: Puppet at the Centre of Everything

• base

• softlayer

• softlayer-dedicated

• rackspace

• ...

Page 18: Puppet at the Centre of Everything

Failover

• /etc/hosts

<%= metrics2IP %> alerts.honshuu.prod audit.honshuu.prod auth.honshuu.prod cloud.honshuu.prod datastore.honshuu.prod inventory.honshuu.prod ...

Page 19: Puppet at the Centre of Everything
Page 20: Puppet at the Centre of Everything
Page 21: Puppet at the Centre of Everything
Page 22: Puppet at the Centre of Everything
Page 23: Puppet at the Centre of Everything

Failover

• /etc/hosts

108.168.254.33 puppet

Page 24: Puppet at the Centre of Everything
Page 25: Puppet at the Centre of Everything

Expected

Dealing with outages

Page 26: Puppet at the Centre of Everything

Really test your vendors

Dealing with outages

Page 27: Puppet at the Centre of Everything

Simulations

Dealing with outages

Page 28: Puppet at the Centre of Everything

• Commit

Code deploys

Page 29: Puppet at the Centre of Everything
Page 30: Puppet at the Centre of Everything

• Commit

Code deploys

• Build

Page 31: Puppet at the Centre of Everything
Page 32: Puppet at the Centre of Everything

• Commit

Code deploys

• Build

• Deploy

Page 33: Puppet at the Centre of Everything
Page 34: Puppet at the Centre of Everything
Page 35: Puppet at the Centre of Everything
Page 36: Puppet at the Centre of Everything
Page 37: Puppet at the Centre of Everything

/opt/puppet/bin/mco puppetd runonce -I <host>

Page 38: Puppet at the Centre of Everything

• Commit

Code deploys

• Build

• Deploy

• Puppet run

Page 39: Puppet at the Centre of Everything
Page 40: Puppet at the Centre of Everything

Code deploys

Advantages

APIs

Page 41: Puppet at the Centre of Everything

Code deploys

Advantages

APIs

Already there

Page 42: Puppet at the Centre of Everything

Code deploys

Advantages

APIs

Already there

System facts

Page 43: Puppet at the Centre of Everything

Code deploys

Disadvantages

Slow

Page 44: Puppet at the Centre of Everything

Code deploys

Disadvantages

Slow

Puppet run already

Page 45: Puppet at the Centre of Everything

Code deploys

Disadvantages

Slow

Puppet run already

Eventually consistent

Page 46: Puppet at the Centre of Everything

System updates

• Bash script

Page 47: Puppet at the Centre of Everything

System updates

• Bash script

• Remote commands

Page 48: Puppet at the Centre of Everything
Page 49: Puppet at the Centre of Everything

System updates

• Bash script

• Remote commands

• Notifications

Page 50: Puppet at the Centre of Everything

System updates

• Bash script

• Remote commands

• Notifications

• Canaries

Page 51: Puppet at the Centre of Everything
Page 52: Puppet at the Centre of Everything

•Build master (buildbot): VM x2 CPU 2.0Ghz, 2GB RAM – $89/m

•Build slave (buildbot): VM x1 CPU 2.0Ghz, 1GB RAM – $40/m

•Staging load balancer: VM x1 CPU 2.0Ghz, 1GB RAM – $40/m

•Staging server 1: VM x2 CPU 2.0Ghz, 8GB RAM – $165/m

•Staging server 2: VM x1 CPU 2.0Ghz, 2GB RAM – $50/m

•Puppet master: VM x2 CPU 2.0Ghz, 2GB RAM – $89/m

Total: $473/m

Colo experiment

Page 53: Puppet at the Centre of Everything
Page 54: Puppet at the Centre of Everything

Colo experiment

•Dell 1U R415

•x2 8C AMD 2.8Ghz

•32GB RAM

Page 55: Puppet at the Centre of Everything

Colo experiment

•Dell 1U R415

•x2 8C AMD 2.8Ghz

•32GB RAM

•Dual PSU, NIC

Page 56: Puppet at the Centre of Everything

Colo experiment

•Dell 1U R415

•x2 8C AMD 2.8Ghz

•32GB RAM

•Dual PSU, NIC

•x4 1TB SATA hot swappable

Page 57: Puppet at the Centre of Everything

Dedicated?

Page 58: Puppet at the Centre of Everything

Dedicated?

•Hardware replacement

Page 59: Puppet at the Centre of Everything

Dedicated?

•Hardware replacement

•Managed/support

Page 60: Puppet at the Centre of Everything

Dedicated?

•Hardware replacement

•Managed/support

•Networking

Page 61: Puppet at the Centre of Everything

Colo?

Page 62: Puppet at the Centre of Everything

Colo?

•Hardware spec/value

Page 63: Puppet at the Centre of Everything

Colo?

•Hardware spec/value

•Total cost

Page 64: Puppet at the Centre of Everything

Colo?

•Hardware spec/value

•Total cost

•Internal skills?

Page 65: Puppet at the Centre of Everything

Colo?

•Hardware spec/value

•Total cost

•Internal skills?

•More fun?!

Page 66: Puppet at the Centre of Everything
Page 67: Puppet at the Centre of Everything

Colo: Power

•£300-350/kWh/m

•4.5A = £520/m

•9A = £900/m

Page 68: Puppet at the Centre of Everything

David Mytton

[email protected]

@davidmytton

Woop Japan!

blog.serverdensity.com