Date post: | 11-May-2015 |
Category: |
Technology |
Upload: | ronald-van-luttikhuizen |
View: | 879 times |
Download: | 1 times |
1 | x
Provisioning Fusion Middleware using
Puppet and Chef
Ronald van Luttikhuizen
3-April-2014 | OUGN 2014
2 | x
Ronald van Luttikhuizen • Managing Partner at Vennster
• Oracle ACE Director for Fusion Middleware and SOA
• Author of different articles, co-author Oracle SOA Book 11g book
• Upcoming book SOA Made Simple
• Architect, consultant, trainer for Oracle, SOA, EDA, Java
• More than 10 years of software development and architecture
experience
• Contact: [email protected]
• Blog: blog.vennster.nl
• Twitter: rluttikhuizen
3 | x
Agenda
● Demo | start
● Server provisioning
● Puppet
● Chef
● Demo | result
4 | x
DEMO
Start
5 | x
Demo VM (manager)
Chef Server Browser
console
VM (database01)
Chef Client
Oracle Database EE
VM (server01)
Chef Client
JDK
WLS 11g AS
WLS 11g MS1
RCU
SOA 11g
VM (server02)
Chef Client
JDK WLS 11g MS1
SOA 11g pro
visi
on
ing
Workstation knife
• Required packages • JDK, WLS, SOA Suite • Patches • Kernel params, users, entropy, etc.
• NM and Domain configuration • NFS share for JCA configuration • Deployment of test composites
6 | x
SERVER PROVISIONING
7 | x
• Automated installations and rollbacks • Inject environment variables, smoke-testing
• Automated builds, tests, and packaging from version control • Central archiving in repository or artifactory
• Automated provisioning of middleware • High frequency of changes to servers (e.g. patches)
• Automated provisioning of OS-ready images • Low frequency of changes to images
Server provisioning | introduction
Machine Provisioning
Server & Middleware Provisioning
Application Building & Packaging
Application Deployment
8 | x
Server provisioning | evolution
Artisan Server Crafting
Specific & Custom Scripts
Continuous management using
standard tools
9 | x
Server provisioning | the traditional way
Artisan server crafting
● Boring
● Stressful
● Error-prone
● Time-consuming
● Non-scalable & expensive
10 | x
WLS, OSB, SOA Suite Database Server
Operating System
WebLogic
OSB
SOA Suite
Domain creation
Initial Domain
setup
Operating system
Database
software
Database
creation
SOA Suite
Repository
40
337 Total actions
13
8
10
10
40
40
30
5
8
YUM + Packages / JVM /
Ulimits / Kernel / User /
Group / Directories
WebLogic / BSU /
NodeManager
OSB / OPatch
SOA Suite / OPatch
Create Domain
Logs / Security / JMS /
WebApps / DataSources /
Resource Adapters
Source: Roll Out a Complete Oracle Fusion Middleware Env in Less than 10min by Edwin Biemond
11 | x
Server provisioning | how it can be
Automated configuration management
● Describe a system once, apply as often as you want
● Automate the repetitive, focus on improvements
and “real” problems
● Predictable results
● (Near) real-time provisioning
● Keep servers in sync
12 | x
Server provisioning | infrastructure as code
Advantages
● Configuration is documentation and always up-to-date
● Configuration is version controlled
● Configurations are defined in a machine- and OS-independent domain
language so the manifests are portable and can be reused
● Change and test configuration, not the server, and re-apply
13 | x
PUPPET
Introduction to
14 | x
Puppet Example | Apache HTTP Server
package { "httpd":
name => "httpd.x86_64",
ensure => "present",
}
file { "http.conf":
path => "/etc/httpd/conf/httpd.conf",
owner => root,
group => root,
mode => 0644,
source => "puppet:///modules/apache/httpd.conf",
require => Package["httpd"],
}
service { "httpd":
ensure => running,
enable => true,
subscribe => File["http.conf"],
}
● Manifests
● Resources
• Name
• Attributes and
values
● Ordering and
dependencies
15 | x
More on Puppet | building blocks
● Variables and (custom) facts
● Node declarations
● Classes and Modules
● Defined resource types
● Templates
if $operatingsystem == 'CentOS'
node 'www1.example.com' {
include common
include apache
}
node 'db1.example.com' {
include common
include oraclexe
}
file { "http.conf":
path => "/etc/httpd/conf/httpd.conf",
owner => 'root',
group => 'root',
mode => '0644',
content => template('config/httpd.erb'),
}
16 | x
More on Puppet | architecture & runtime
versus
17 | x
More on Puppet | console
18 | x
More on Puppet | products, price, etc.
● Enterprise vs. Open Source
● Puppet Forge
● Market presence
● Pricing (27-nov-2013)
● Apache license
19 | x
If you want to know more about Puppet …
20 | x
CHEF
Introduction to
21 | x
Chef | architecture
Central Chef Server
Multiple Administrators
Repository
22 | x
Chef | terminology
● Node, Server, Workstation
● Chef-client asks Chef-server about the policy for the node
● Resources: a component and the desired state
● Recipes: describe resources and desired state
● Cookbooks: sets of recipes grouped together, also includes templates
and source files, etc.
● Run List: recipes from cookbooks you want to run
● LWRP: custom actions
23 | x
Example Recipe
paca
Policy says package
should be installed
This service should be
enabled on reboot, and
must be running
Template specifies the
contents required
Source: Chef Fundamentals Webinar 1 #LEARNCHEF
24 | x
Open Source Chef Console
25 | x
Chef in the wild
● Enterprise vs. Open Source
● Community & Popularity
● Chef Community Cookbooks
● Pricing (30-nov-2013)
26 | x
More about Chef
27 | x
Starting with Server Provisioning
● Chef versus Puppet versus …
• Support for OS & platforms
• Pricing model
• Language
• Dependencies and ordering of resources
• Hosting
● DTAP
● Idempotency
● Style guides & coding standards
● OSS versus Enterprise
● Plugins and tools
28 | x
DEMO
Result
29 | x
Demo VM (manager)
Chef Server Browser
console
VM (database01)
Chef Client
Oracle Database EE
VM (server01)
Chef Client
JDK
WLS 11g AS
WLS 11g MS1
RCU
SOA 11g
VM (server02)
Chef Client
JDK WLS 11g MS1
SOA 11g pro
visi
on
ing
Workstation knife
• Required packages • JDK, WLS, SOA Suite • Patches • Kernel params, users, entropy, etc.
• NM and Domain configuration • NFS share for JCA configuration • Deployment of test composites