What does it mean to provision a virtual machine?
Solution 1
Definitions and Examples
From the definition of Puppet:
Puppet is a configuration management system that allows you to define the state of your IT infrastructure, then automatically enforces the correct state.
Vagrant allows you to use provisioners like shell scripts, Puppet, Chef, or Ansible to configure your machine as part of the provisioning process:
Provisioners in Vagrant allow you to automatically install software, alter configurations, and more on the machine as part of the vagrant up process.
In general, if you want to automate the setup or configuration of a node, virtual or not, then a configuration management tool that supports hardware and/or OS provisioning is what you need.
Solution 2
Provisioning generally means a functional state - something past a vanilla server creation.
A typical example is: Provision a web server or provision 20 web servers. In practice that means: - Create 20 servers. - Install packages necessary to serve up web traffic - Possibly create a load balancer - (maybe) Join all of these boxes to a load balancer
Example of said via Chef Provisioning (from:https://github.com/vinyar/tokyo_chef_provisioning)
## Setting up empty array
elb_instances = []
## Generic name
name = 'stack_example'
## machine_batch allows parallel creation of machines
machine_batch 'hello_world' do
1.upto(20) do |n|
## Just a variable to make things easier
instance = "#{name}-webserver-#{n}"
## Machine resource is used to create a single server
machine instance do
machine_options ({
bootstrap_options: {
:instance_type => "t1.micro",
image_id: 'ami-b6bdde86',
:key_name => "stack_key"},
:ssh_username => "root"})
recipe "webserver"
tag "#{name}-webserver"
converge true
end
## Populating array with instance name on each loop.
elb_instances << instance
end
end
## Creating load balancer
load_balancer "#{name}-webserver-lb" do
load_balancer_options({
:availability_zones => ["us-west-2a", "us-west-2b", "us-west-2c"],
:listeners => [{:port => 80, :protocol => :http, :instance_port => 80, :instance_protocol => :http }],
})
## Passing array as a list of machines to the load balancer
machines elb_instances
end
user1956609
Updated on June 07, 2022Comments
-
user1956609 almost 2 years
I see the word "provisioning" used everywhere with virtualization but I can't seem to find a clear definition of it on google. Does it involve just setting up the guest operating system and allotting resources to it, or does it include downloading software and updates as well? Or does it include even more than that, like setting up shared folders and configurations?