A journey on the automation path.
Notes on how to migrate existing infrastructures to automation and how to introduce configuration management tools like Puppet, Chef, CFEngine on manually managed systems.
CNIC Information System with Pakdata Cf In Pakistan
Raise the bar!
1. Raise the Bar!
Alessandro Franceschi
@alvagante
github.com/example42
OSS4B 2013
A journey towards
infrastructure automation
2. they tell us
infrastructures are
like this...
Automated Systems Provisioning
Centrally Managed and Configured
Massively Continuos Deployments
Predictive Data Analysis
Groundbreaking Monitoring Visualization
Auto Scaling in Multiple DataCenters
Virtualized and Cloudified
(Chaos) monkeys driven
3. but our infrastructure
is more like this...
Semi automatic systems provisioning
An hell of old, not updated, heterogenous OS
Configurations managed by hand or scripts
Deployments are a continuous warfare
We collect logs you don't check
Monitoring is a **** to maintain
More or less fully Virtualized
Some Cloud experiments
Self Destroying (no need of monkeys)
4. What can we do?
Hold on.
Where are we?
Look around.
Choose a path.
Move.
Step by step.
5. Where are we?
Where things fail?
Where time is wasted?
What works?
What's critical
What's strategical?
What are the available skills?
Learn from failure, and
learn from success.
6. Choose a Path
Analyze and discuss solutions
Share vision and goals
Draw a general roadmap
Be ready for corrections
Choose the tool:
Puppet, Chef, CFEngine...
No tool?
No automation, no reason to talk here
7. Step by Step
Train the team
Get help from experts
Do or Know It Yourself
Use public code, when possible
Communicate, always
Step the dots, then connect them
Test, act, verify.
Reiterate.
8. Scenarios
Brand new project:
New systems, new infrastructure, no legacy.
Infrastructure migration:
New systems to replace existing ones, some legacies.
Infrastructure update:
Automation on existing systems.
9. Brand New Project
Easier and most liked solution
More freedom on technological choices
Brand new OS and stacks, possibly homogenous
Clean setups from scratch
Sound design from the foundations
No mess with current production
Faster and smoother deployment times
10. Infrastructure Migration
Existing systems still not centrally managed
Migration of existing stacks to new systems
All new nodes should be fully managed
Define a standard baseline
Create the stacks / roles you need
Enlarge coverage of application stacks
Start from what is more used and needed
11. Migration evaluations
How easily and quickly can be done
How stable are systems
What maintenance efforts they require
Number of nodes involved
Migration risks and impact
What's worth to automate
Future benefits
12. Infrastructure update
Harder and more dangerous
Probably different OS to manage
Undetermined existing setup procedures
Manual configurations accumulated over time
Evaluate agent setup on older systems
Evalutate effort and benefits, for edge cases
Evaluate the migration alternative for common cases
13. Infrastructure update
We need a gradual approach
Define a minimal baseline to apply to all nodes
Be careful of OS variations
Raise the Bar, step by step:
Vertically: adding services to the minimal baseline
Horizontally: covering more OS and adding nodes
14. Priorities
Automate servers deployment (*)
Automate common systems configurations (*)
Automate your most important stacks (*)
Refine testing and apps deploy, then automate (*)
Automate or delegate monitoring
Integrate what already works well
(*) Time spent here is rarely wasted.
15. Configurations Rollout
Notify users of the ongoing changes
Have a test environment
Test effects on any single different OS
Propagate the configurations
Watch logs and reports
Don't be surprised of skeletons
Review and patch uncovered configurations
16. Mind-set change
When infrastructure is code:
- you need to version it
- you can test it
- you use it (as many times as necessary)
- you refine it over time
- you, sysadm, are a developer
and you don't mess up with the runtime.
17. Raise higher the bar
Useful Monitoring/Logging
Visualization and correlation of infrastructure data
Continuos delivery as frequent as you need
Improved stability, scalability, redundancy
... whatever makes your infrastructures smarter
18. Now, RUN!
Automation means:
- repeatability
- consistency
- scaling
- reduced human errors
- velocity
- more time to do interesting things