Bosh Basics
• Inner vs. outer shell
• Bosh = Bosh outer shell
What is Bosh?
„BOSH is an open source tool chain for release engineering, deployment, and lifecycle management of large-scale
distributed services.“
http://docs.cloudfoundry.org/bosh/understanding-bosh.html
IaaS - OpenStack
VIRTUAL DATACENTER
VIRTUAL MACHINE
MicroBosh
Router
STORAGE
Storage Node Storage Node Storage Node
HDD HDD
HDD HDD
HDD HDD
HDD HDD
HDD HDD
HDD HDD
HDD HDD
HDD HDD
HDD HDD
Bosh API
Storage Volume
Operating System
Bosh Agent
VIRTUAL MACHINE
Bosh CLI $> bosh deploy
IaaS API
Bosh Deployment
Stemcell Release Manifest
A Bosh-Deployment depends on 1 .. *
Stemcells
• VM template
• Bosh clones new VMs from stemcells
• Stemcell = OS + Bosh Agent
• Bosh Agent acts on the VM
• Stemcells are infrastructure and OS specific (VMware + Ubuntu, OpenStack + CentOS, etc.)
A Bosh-Deployment is described by a Release
• = collection of
• source code
• configuration files
• startup scripts
• software packages
• jobs
A Release contains 1 .. * Jobs
• Jobs = Processes to be run
• = set of configuration files
• + scripts
• > run process from a package, e.g. mysqld
A Release contains 1 .. * Package
• Package
• src code
• compile script
• install script
A Bosh Deployment’s settings are contained in a
Manifest
• defines the layout and properties of a deployment
• infrastructure configuration
• network architecture
• VM dimensions, used stemcells (OS)
• bosh cli pushed manifest to Bosh director
• > Bosh director creates a deployment
Bosh Deployment Workflow
• Upload stemcell
• Upload a release
• Set deployment with a manifest
• Execute deployment
Benefits from Bosh’s design
• Switch deployment between clouds
• Keep the same release
• Use a stemcell specific to the new cloud
• Adapt the manifest
• Scaling-out a Bosh deployed system
• Keep the same release
• Use the same stemcell
• Change the manifest
• Update or roll-back Bosh deployed system
• Use a newer or older release version
• Use the same stemcell
• Use the same manifest
Bosh Design Principles
BOSH Deployments are Predictable
• Src code is compiled in a freshly created VMs
• VMs always contain exact the software, specified in the release
• No left-overs of prior deployments as new VMs are used.
BOSH Deployments are Repeatable
Executing a specific Bosh deployment always leads to exact same deployed
system.
BOSH Deployments are Self-Healing
Bosh Health Monitor
• Bosh Health Monitor…
• monitors processes running on the VMs managed by Bosh
• Compares desired vs. actual state
• Bosh can recreated processes and VMS on failure.
PaaS Process Failure
Anynines Operations Manager (Bosh) Anynines IaaS (OpenStack)
CF Health Manager (Process)
Bosh Agent
VIR
TU
AL
MA
CH
INE
Process Monitor
CF DEA (Process)
VIR
TU
AL
MA
CH
INE
Bosh Agent Process Monitor
Bosh Health Monitor
Bosh Director
NATS Message Bus
Infrastructure Level Self-Healing
CF DEA (Process)
VIR
TU
AL
MA
CH
INE
Bosh Agent Process Monitor
CF DEA (Process)
Process Monitor
PaaS VM Failure
Anynines Operations Manager (Bosh) Anynines IaaS (OpenStack)
CF Health Manager (Process)
Bosh Agent
VIR
TU
AL
MA
CH
INE
Process Monitor
CF DEA (Process)
VIR
TU
AL
MA
CH
INE
Bosh Agent Process Monitor
CF DEA (Process)
VIR
TU
AL
MA
CH
INE
Bosh Agent Process Monitor
Bosh Health Monitor
Bosh Director
NATS Message Bus
CF DEA (Process)
VIR
TU
AL
MA
CH
INE
Bosh Agent Process Monitor
Infrastructure Level Self-Healing
Anynines Operations Manager (Bosh) Anynines IaaS (OpenStack)
CF Health Manager (Process)
Bosh Agent
VIR
TU
AL
MA
CH
INE
Process Monitor
CF DEA (Process)
VIR
TU
AL
MA
CH
INE
Bosh Agent Process Monitor
Bosh Health Monitor
Bosh Director
NATS Message Bus
Infrastructure Level Self-Healing
CF DEA (Process)
VIR
TU
AL
MA
CH
INE
Bosh Agent Process Monitor
CF DEA (Process)
VIR
TU
AL
MA
CH
INE
Bosh Agent Process MonitorBosh Agent
Links & Sources
• Open Source Bosh Documentation http://docs.cloudfoundry.org/bosh/
• Understanding Bosh http://docs.cloudfoundry.org/bosh/understanding-bosh.html
• Bosh Source Code on github.comhttps://github.com/cloudfoundry/bosh
Recommended