Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Excerpt

This page describes how to create a Windows base image.

These instructions should work regardless of the provisioning engine being used . If you are using these instructions to create an xCAT bare metal image, ignore the sections with titles beginning with VMware Only:. This document assumes familiarity with xCAT and VMware.

Terminology

  • Management node: Linux server with the following components installed:
  • Compute node: Refers to the target blade or virtual machine on which Windows is installed.
  • Provisioning engine: Software which is able to interact with the compute node making it possible to install an OS on it
    • VCL can utilize several different provisioning engines including xCAT, VMware Server, VMware ESX, and VMware ESXi.  xCAT is a cluster management tool used to install images on bare metal blades.
    • The provisioning engine may be a hypervisor if the compute nodes are virtual machines (VMware)
    • The provisioning engine may interact with the BladeCenter's management module if the compute nodes are IBM blades (xCAT)
    • The provisioning engine may utilize IPMI if the compute nodes support it (xCAT)

Requirements

You will need the following:

(xCAT, VMware, etc.).  Ignore the VMware Only sections if you are attempting to create an image using xCAT or some other bare metal provisioning engine. 


Requirements

You will need the following:

  • Windows installation ISO file
  • Windows product key or KMS server address

 The following must be done before an image can be captured:

  • A computer for the machine being captured Compute node has already been added to the VCL database
  • Windows installation ISO file
    Note: these instructions assume the Windows ISO file is loacated at the following location on the management node:
    /install/WinXP+SP3.iso
  • Windows product key owned by your organization
  • VMware Only:
    • A computer for the VM host machine on which the guest is running as been added to the VCL database
    • The guest VM has been assigned to the VM host

These instructions assume you have root access and are using a bash shell:

Panel

sudo bash

Add a New Image to the VCL Database

Add the image to the VCL database. A row needs to be added to the following tables:

  • image
  • imagerevision
  • resource

These rows need to be added to the database manually either by using SQL commands or phpMyAdmin.  The following SQL statements assume the following properties of the image:

  • Image ID: 7
  • Image name: vmwarewinxp-base7-v1
  • Image prettyname: No Apps (WinXP vmware)
  • OS: WinXP under VMWare - NOTE: If you are using something else, make sure you set OSid to correctly match the OS table.
Code Block

INSERT INTO `vcl`.`image` (
`id` ,
`name` ,
`prettyname` ,
`ownerid` ,
`platformid` ,
`OSid` ,
`imagemetaid` ,
`minram` ,
`minprocnumber` ,
`minprocspeed` ,
`minnetwork` ,
`maxconcurrent` ,
`reloadtime` ,
`deleted` ,
`test` ,
`lastupdate` ,
`forcheckout` ,
`maxinitialtime` ,
`project` ,
`size` ,
`architecture` ,
`description` ,
`usage` ,
`basedoffrevisionid`
)
VALUES (
'7' , 'vmwarewinxp-base7-v1', 'No Apps (WinXP vmware)', '1', '1', '16', NULL,
'512', '1', '1024', '100', NULL , '5', '0', '0', NOW(), '1', '0', 'vcl', '1500',
'x86', NULL , NULL , '0'
);
Code Block

 INSERT INTO `vcl`.`imagerevision` (
`id` ,
`imageid` ,
`revision` ,
`userid` ,
`datecreated` ,
`deleted` ,
`datedeleted` ,
`production` ,
`comments` ,
`imagename`
)
VALUES (
NULL , '7', '1', '1', NOW(), '0', NULL , '1', NULL , 'vmwarewinxp-base7-v1'
)
Code Block

 INSERT INTO `vcl`.`resource` (
`id` ,
`resourcetypeid` ,
`subid`
)
VALUES (
NULL , '13', '7'
)

VMware Only: Create a Virtual Machine

...

Follow the steps: Install & Configure Cygwin SSHD

Configure the Windows Default Profile (optional)

Follow the steps on Configure the Default Profile if you want to customize the default profile which will be used when users login to the image.

Insert an Imaging Reservation into the VCL Database

An imaging request needs to be manually inserted into the VCL database to begin the automated imaging process.  The imaging process performs several steps to prepare the VCL image to be captured and then initiates the capture.

You will need to know the management node ID and computer ID of the VM guest you are using.  The following SQL statements assume the following: 

  • Computer ID: 2 
  • Management node ID: 1
  • Image ID: 7
  • Image Revision ID: 7
Code Block

INSERT INTO `vcl`.`request` (
`id` ,
`stateid` ,
`userid` ,
`laststateid` ,
`logid` ,
`forimaging` ,
`test` ,
`preload` ,
`start` ,
`end` ,
`daterequested` ,
`datemodified`
)
VALUES (
'1' , '16', '1', '16', '', '1', '0', '0', NOW( ) , TIMESTAMPADD(MINUTE, 120, NOW()), NOW( ) , NULL
);
Code Block

 INSERT INTO `vcl`.`reservation` (
`id` ,
`requestid` ,
`computerid` ,
`imageid` ,
`imagerevisionid` ,
`managementnodeid` ,
`remoteIP` ,
`lastcheck` ,
`pw`
)
VALUES (
NULL , '1', '2', '7', '7', '1', NULL , NULL , NULL
);

 Start vcld:

Panel

service vcld start

Monitor the vcld.log file:

...

Run vcld -setup

  1. Run the following command on the management node:
    /usr/local/vcl/bin/vcld -setup
  2. Navigate the menu options
    (Note: the names and numbers of the menu items may not match your installation):
    1. Select a module to configure: VCL Image State Module
    2. Choose an operation: Capture Base Image
    3. Enter the VCL login name or ID of the user who will own the image:
      Enter your VCL user ID or the user ID of the user you want to own the image.  Pressing Enter without entering a user login ID will cause admin to be the owner of the new base image.
    4. Enter the hostname or IP address of the computer to be captured:
      Enter the name or private IP address of the computer which has already added to the VCL database.
    5. Select the OS to be captured:
      1. VMware Linux
      2. VMware Windows 2003 Server
      3. VMware Windows 7
      4. VMware Windows Server 2008
      5. VMware Windows Vista
      6. VMware Windows XP
    6. Image architecture:
      1. x86
      2. x86_64
    7. Use Sysprep:
      1. Yes
      2. No
      Sysprep is usually only required if the image will be loaded on bare metal computers with varying different hardware.
    8. Enter the name of the image to be captured:
      The name you enter is the name that will be displayed in the list of environments.  It may contain spaces but including other special characters is not recommended.

The following happen once you enter an image name and press enter:

  • A new image is added to the VCL database
  • An imaging request is added to the VCL database
  • The vcld -setup automatically initiates 'tail -f /var/log/vcld.log' to monitor the vcld log file.  The output should be displayed on the screen.

Watch the vcld logfile output to determine if the image capture process is successful or terminated because a problem occurred.  When the capture process terminates, there will either be a message near the end of the output saying "image capture successful" or there will be several WARNING messages, the last of which says something to the effect "image failed to be captured".  Further troubleshooting is required if the image fails to be captured.

Add the Base Image to an Image Group

The vcld -setup utility does not add the new base image to any image groups.  You must add the image to an image group using the VCL website after the image capture process is complete.  Reservations for the image cannot be made until this is done.  To add the image to an image group, browse to the VCL website and select Manage Images > Edit Image Grouping.