Table of Contents Preface..........................8 Intended Audience..........................8 Typographic Conventions........................8 Publishing History..........................10 Related Information..........................11 HP Encourages Your Comments......................12 1 Overview........................13 Introduction............................13 Reviewing the Toolkit...........................14 Planning the Deployment........................15 Selecting a Workstation........................15 Selecting a Boot Mechanism......................15 Configuring the Repository......................16 Using Repository Creation Scripts.....................16 2 Using the SSTK Deployment Workflow..............22 Setting Up a Model Server........................22 Creating a Server Profile........................22 Setting Up the Toolkit Environment.....................23...
Page 4
Using a USB Flash Device as External Media.................44 Using Network Boot..........................44 Setting Up a Linux Network Boot Server..................44 Setting Up a DHCP Server......................44 Setting Up a TFTP Server......................44 Populating the TFTP Directory....................45 Setting Up the HP Integrity Server for PXE-Enabled Boot.............45 Booting the HP Integrity Server From a PXE-Enabled NIC............45 6 Utilities Reference......................47 cfggen..............................47...
Page 5
Synopsis............................71 Description............................72 Format............................72 hpsetacpi............................72 Synopsis............................72 Description............................72 Examples............................72 hpshowdisk............................73 Synopsis............................73 Description............................73 Examples............................73 hwdisc..............................74 Synopsis............................74 Description............................74 Example............................75 hwquery...............................76 Synopsis............................76 Description............................76 Examples............................77 ifhw..............................77 Synopsis............................77 Description............................77 Examples............................78 parted..............................79 Synopsis............................79 Description............................79 Examples............................79 A Known Issues........................81 Pre-OS Linux Prompts Are Not Displayed...................81 Potential RHEL Deployment Errors.....................81 Installing RHEL4U4 with Disks Without Partition Tables..............81 IPMI Errors on RHEL4..........................81 Labeling Issue with RHEL4U5......................81...
Page 6
List of Tables SSTK Variables..........................34 SSTK Configuration Variables.......................35 Global Options..........................35 Image Options..........................36 SSTK Command Line Options......................36 The mkisofs Command Options....................41 cfggen Commands........................47 CLMChecking Options ........................49 conrep Options ...........................50 conrep Return Codes ........................51 cpqacuxe Options ........................53 Automatic Script File Options.......................54 Custom Script File Options......................57 Error Codes............................62 efibootmgr Options........................66 6-10...
Page 7
List of Examples cfggen list Command......................48 cfggen Display Command......................48 Sample conrep.dat file......................50 Sample conrep.xml File......................50 Sample hpia64imfo Utility Output....................71...
Preface This document provides instructions for configuring and using the SmartSetup Scripting Toolkit (SSTK) on HP Integrity servers running Linux. As of this publication, SSTK is supported on the following Linux distributions: • Red Hat Enterprise Linux (RHEL) □ RHEL4U4 (Backward compatible only □...
Page 9
[ERRORNAME] The name of an error, usually returned in the errno variable. The name of a keyboard key. Return and Enter both refer to the same key. Term The defined use of an important word or phrase. UserInput Commands and other text that you type. Variable The name of a placeholder in a command, function, or other syntax display that you replace with an actual value.
Publishing History The document publishing date and part number indicate the current edition of the document. The publishing date changes when a new edition is printed. Minor changes might be made at reprint without changing the publishing date. The document part number changes when extensive changes are made.
Manufacturing Supported OS Supported Versions Edition Publication Date Part Number Number RHEL4U5, RHEL4U6, and RHEL5U1 SLES9SP3 (Backward compatible only SLES9SP4, and SLES10SP1 5991-6250 Red Hat Enterprise Linux (RHEL) RHEL4U4 (Backward August 2007 SUSE Linux Enterprise Server (SLES) compatible only RHEL4U5, and RHEL5 SLES9SP3 (Backward compatible only ) and...
HP Encourages Your Comments HP encourages your comments concerning this document. We are committed to providing documentation that meets your needs. Send any errors found, suggestions for improvement, or compliments to: docsfeedback@hp.com Include the document title, manufacturing part number, and any comment, error found, or suggestion for improvement you have concerning this document.
1 Overview The HP SmartSetup Scripting Toolkit (SSTK) enables you to deploy a large number of HP Integrity servers rapidly and efficiently. Using SSTK, you can develop custom scripts that simplify server deployments by automating various hardware configuration and software installation operations. SSTK can set specific Extensible Firmware Interface (EFI) boot variables, create disk partitions, and tie into the standard unattended installation process to install the OS and selected applications.
SSTK is not an automated server deployment solution for everyone. The SSTK is an extensible framework for developing hardware configuration and software installation scripts. The SSTK is designed for administrators who have some expertise in unattended installations of RHEL or SLES and familiarity with HP Integrity servers.
• The SSTK boot device is a CD, a network share, or a USB flash device—holds files that allow servers to boot to the toolkit environment. You can also use the SSTK boot device to hold the repository of scripts, utilities, configuration files, OS files, and application files. •...
Configuring the Repository Every server that boots to the SSTK environment must have access to the repository of configuration files, scripts, utilities, OS files, driver files, and application files. The Linux boot loader configuration file, which must be manually edited as described in Chapter 4 (page 34), specifies the default location of the repository.
Page 17
As root, extract the SSTK-LinuxIntegrity-3.4.tgz package, located on your HP Integrity CD, into the directory location that to host the repository. For example, creating the repository in the repository directory you would use the following commands: cp SSTK-LinuxIntegrity-3.4.tgz /repository cd /repository tar zxvf SSTK-LinuxIntegrity-3.4.tgz Edit the /etc/fstab configuration file and append the following line to it: /dev/cdrom...
Page 18
Select Destination Directory and click OK. Select the destination directory by navigating to the correct directory, and then click Select CDROM Device and click OK. Select your CD/DVD device by navigating to the correct directory, and then click OK. Select Make Repository and click OK. The script creates the necessary directories, files, and symbolic links.
Page 19
To exit the script, select Exit and click OK. The repository structure created in the /repository/SSTKLnx3.3 directory is as follows: SSTKLnx3.3/ |-- SSTK_DeploymentGuide.pdf |-- SSTK_DeploymentGuide.txt |-- boot_files `-- efi `-- boot |-- bootia64.conf |-- bootia64.efi |-- elilo.conf |-- elilo.efi |-- linux `-- rootfs.gz |-- data_files |-- os...
2 Using the SSTK Deployment Workflow Server deployments using SSTK involve four main stages. This chapter provides a high level overview of the deployment workflow including the following topics: • “Setting Up a Model Server” (page 22) • “Creating a Server Profile” (page 22) •...
Setting Up the Toolkit Environment Setting up the toolkit environment involves the following tasks: Set up the toolkit launch: Setting up the toolkit launch involves editing a script and a configuration file that control the toolkit. The EFI loader launches the Linux boot loader, which executes a bootstrap script in the root file system.
Capturing Images To capture one image, use the following steps: Ensure that the source computer is booted and running SSTK. Edit the sstk.conf file on the repository, and then change the value of IMAGE_FILE variable to the name you want created as a result of this capture operation. The default value for IMAGE_FILE is linux.img.
Customizing the Toolkit Environment After you have gained some familiarity with the SSTK, you might find yourself eager to take advantage of its flexibility using your own scripts and customizations. HP suggests the following ways in which you can extend the capabilities of the toolkit environment. □...
Page 26
Configure the IPv6 static address: # ifconfig <network_interface> inet6 add <ipv6_addr> netmask <netmask_addr> up For example: # ifconfig eth3 inet6 3ffe:501:ffff:100:205:5dff:fea1:b73c/64 netmask 255.0.0.0 up Check the network interface status: # ifconfig Messages similar to the following should be displayed: eth3 Link encap:Ethernet HWaddr 00:17:A4:51:E5:77 inet6 addr: 3ffe:501:ffff:100:205:5dff:fea1:b73c/64 Scope:Global...
3 Creating a Server Profile A server profile is like the DNA of all the servers in the deployment. It includes the server EFI environment variables, the I/O configuration, the OS and drivers, and installed applications. The server profile is stored in the repository. This chapter describes how to create the server profile. Because you need to perform this task on the workstation using the SSTK, you begin by setting up this workspace.
Page 28
Select Error Console. Set the error console to the same as the output console device. Or, at the HP Integrity server (the model server and each target server) using the Legacy interface, perform the following steps: Select EFI Boot Manager > Boot Option Maintenance Menu. Select Select Active Console Input Devices.
Unpacking the Toolkit The SSTK software package is an archive that is provided in tar gzip file format. The archive expands into a file structure that also serves as a skeleton for the server profile: • Documentation includes this guide and a readme file with any breaking release information. •...
Page 30
software/EFI_TOOLS A placeholder directory, which you can populate with applications that are copied to the HP Service Partition and is installed after the OS is first loaded. Files placed under software\EFI_TOOLS are automatically copied to the HP Service Partition. • The os directory contains unattended configuration files for the Linux distributions.
Page 31
utilities into the RAMdisk, running I/O hardware inventory, and prompting the you to select a deployment task. This script launches Linux installation by creating linux-setup.sh and formatting disk partitions, specifying the Linux Setup boot option, and rebooting the server. This script edits the configuration in the RHEL rhel-setup.sh unattended configuration file and copies the RHEL boot image files to the ESP partition.
hpia64info The hpia64info utility, which displays information about Management Processor and system firmware. hwdisc The hardware discovery utility, which creates an inventory of the server and writes this data to a file. hwquery The hardware query utility, which reads the file created by the hardware discovery utility and provides this data in a usable form.
Page 33
NOTE: SSTK supports unattended OS installations on HP Integrity Virtual Machines. Setting Up an Unattended OS Installation...
4 Setting Up the Toolkit Environment Setting up the toolkit environment involves editing scripts that control the boot and operation of the toolkit. The EFI loader launches the Linux boot loader, which in turn executes a bootstrap script in the root file system. The bootstrap script invokes the main toolkit launch script, which uses a Linux setup script to trigger the OS installation.
Table 4-1 SSTK Variables (continued) Variable Name Description Sets the name of the Linux image file. IMAGE_FILE="" The default value is linux.img. Sets the log level. Set 1 for normal logging or zero (0 ) for extended logging. LOG_LEVEL=0 The default value is zero. Defines the ESP partition size.
Table 4-3 Global Options (continued) Global Option Description Specifies the number of tenths of seconds to wait before autobooting when not delay=number in interactive mode. Default is 0. Forces interactive mode. prompt Sets level of verbosity [0–5]. Default is 0 (no verbosity). verbose=number Sets global root filesystem for Linux/ia64.
Page 37
Table 4-5 SSTK Command Line Options (continued) SSTK Option Description USB—/dev/devicename Passes extra parameters to the mount command. ssstk_mount_options=string Specifies the name of main launch script. ssstk_script=filename Specifies the default response to the toolkit launch script prompt (readhwconfig, ssstk_action=string bash, capture, deploy, or linux). Reports the VESA/PCI bus speed in MHz to the IDE driver, where xx is between idebus=xx 20 and 66 inclusive.
NOTE: During the pre-boot portion of the Linux booting sequence, you may encounter a syntax error in each line of the script, which may indicate that there are extra line-feed characters in the boot loader file. If you modify the elilo.conf file using a Windows-based text editors, you must ensure that the modified script files are UNIX file format by using a utility to convert the script files to UNIX format (such as dos2unix) or by saving the file in UNIX file format.
Creates four partitions: EFI System Partition (ESP), HP Service Partition (HPSP), the Linux-swap partition, and the Linux partition. Formats these partitions. Copies the Linux distribution boot files to the ESP partition. Updates the unattended files. Creates a new boot option in the EFI boot manager, which starts the Linux Setup process. Reboots the server.
5 Setting Up the Boot Mechanism Setting up the boot mechanism involves one of the following options: creating a bootable CD or DVD, creating a bootable USB device, or setting up a network boot environment. This chapter shows you how to perform each task at a Linux system. This chapter addresses the following topics: •...
Creating a CD Build Directory Create a directory, enter: mkdir ./linuxbootCD Create a subdirectory to store the boot image, enter: mkdir ./linuxbootCD/boot Copy the boot image file, boot.img to the ./linuxbootCD/boot directory, enter: cp /bootable-image/boot.img ./linuxbootCD/boot Creating the ISO File The mkisofs command is used to create an ISO file.
Select one of the following options: • Enter readhwconfig to create a configuration file in the repository to save the hardware configuration of the Linux server in the repository, and then reboot the server. • Enter linux to execute the linux-setup.sh to install the Linux OS. •...
Page 43
Enter the EFI Boot Manager Menu and select Boot Configuration. Select Add Boot Option to add Removable Media Boot for the USB device. In the EFI Boot Manager, select the Linux USB device to boot from. Using a USB Flash Device...
Using a USB Flash Device as External Media Assuming the USB device is /dev/sda you can mount your USB device using the following command: mount –t msdos /dev/sda /mnt Using Network Boot The following sections show you how to set up and use a network boot environment Setting Up a Linux Network Boot Server This section contains instructions for performing a Linux boot over a network.
server = /usr/sbin/in.tftpd server_args = -s /tftpboot disable = yes per_source = 11 cps = 100 2 In this example, disabled is the default setting, and /tftpboot is the root directory for all client access. To enable the TFTP service on your server, edit the disable line to read: disable = no Populating the TFTP Directory Use the /tftpboot directory as the directory from which TFTP clients retrieve files.
Page 46
Enter the EFI Boot Manager and select the appropriate boot core LAN XX option. Use the Tab key to see the boot labels defined in the elilo.conf file. Perform one of the following actions: • Enter readhwconfig. This creates a configuration file in the repository to save the hardware configuration of the Linux server in the repository.
6 Utilities Reference This chapter contains reference information and usage examples for the utilities provided in the toolkit. In other words, the manpages associated with SSTK. You can get online help for each utility by using the -h or -? option. This chapter contains the following manpages: •...
Table 6-1 cfggen Commands (continued) Commands Description Turn ON and OFF a drive's Identify LED. LOCATE Display current volume status information. STATUS Bring a hard disk offline (in IM/IME volumes). SETOFFLINE Bring a hard disk online. SETONLINE The <parameters> are command specific values. To obtain command help, you can use cfggen <controller #>...
Device is a Hard disk Enclosure # Slot # Target ID State : Ready (RDY) Size (in MB)/(in sectors) : 57231/117210240 Manufacturer : ATA Model Number : FUJITSU MHT2060B Firmware Revision : 034E Serial No : NR0LT5625AAG Drive Type : SATA ------------------------------------------------------------------------ Enclosure information ------------------------------------------------------------------------...
conrep Synopsis conrep ( -l [-f <DAT FILENAME] [-F] | -s [–x <XML FILENAME>] [-f <DAT FILENAME>] | -c | -d | -h ) [-v] | -m Description The conrep utility replicates the configuration data stored in the EFI variables. It reads the EFI variables from the NVRAM of the model server and writes the results to a DAT file.
</section> <section name="EFI_Non-Cell_variables"> <ev>AutobootRetry</ev> </section> <section name="EFI_Cell_variables"> <ev>AutobootRetries</ev> </section> </conrep> Table 6-4 conrep Return Codes Value Meaning Cause Action conrep executed successfully Permission denied The user is not a system Log in as root to run conrep. administrator. Usage error An error occurred while using Run conrep -h to get help using conrep for some unexpected...
cpqacuxe Synopsis • Capture: CPQACUXE -C FILENAME [-internal | -external] -E FILENAME • Input: CPQACUXE -I FILENAME [-internal | -external] [reset] -E FILENAME • Input with reset: CPQACUXE -i-with-reset FILENAME [-internal | -external] [reset] -E FILENAME Description The cpqacuxe utility operates on the configuration of storage array controllers. The cpqacuxe utility enables the array configuration on one server to be replicated on other servers with similar array storage resources.
Sectors = 32 StripeSize = 256 ArrayAccelerator = Enabled ; HBA SSP Specifications HBA_WW_ID= 10000000C9272B34 ConnectionName= TestConn HostMode= Linux Table 6-5 cpqacuxe Options Option Description Specifies the capture file. The capture filename is optional. If no capture file is specified, -C FILENAME the default capture file is acucapt.ini in the ACU working directory.
These options can be specified in any order, but an option from another category of options cannot occur between any two options from this category. Automatic Script File Format The automatic script is used to apply automatic configuration rules to unconfigured or configured controllers.
Page 55
Table 6-6 Automatic Script File Options (continued) Option Value IOCabinet [N], IOBay [N], IOChassis [N],Slot [N], Cabinet [N], Cell [N]: The controller identified by the IPF Slot path information is used. Use of the -internal” and -external command line switches influences what is regarded as the first controller.
Table 6-6 Automatic Script File Options (continued) Option Value Specifies the Surface Scan Delay in seconds. This option is not required. If this option SurfaceScanDelay is not specified, the Surface Scan Delay remains unchanged. N: This value is a numeric value between 1 and 30 seconds. Specifies if Automatic Configuration should attempt to add spares.
Size = [N]|Max Sectors = 32|63 StripeSize = 8|16|32|64|128|256 ArrayAccelerator= Enable|Disable ResourceVolumeOwner= N LogicalDriveSSPState = Enable|Disable SSPAdaptersWithAccess = [N],[N]…|None PreferredPath = 1|2 ; HBA Options ; There can be multiple HBA specifications in the file HBA_WW_ID = WWN ConnectionName = UserDefinedName HostMode = Default|Windows|Windows(degrade |OpenVMS|Tru64|Linux|Solaris|Netware|HP|Windows_SP2_and_ Table 6-7 Custom Script File Options...
Page 58
Table 6-7 Custom Script File Options (continued) Option Value Specifies the RaidArrayID for controllers that support RaidArrayID. This is a RAIDArrayID user-defined string to identify controllers. Currently, RaidArrayIDs are only supported by Fibre and shared-storage controllers. "XXXXXXXXXXXXXXXXXXXX" Varying length string that can consist of any of the following characters: a-z A-Z 0-9 ! @ # * ( ) , - _ + : .
Page 59
Table 6-7 Custom Script File Options (continued) Option Value SSP only remains enabled if the SSPAdaptersWithAccess command specifies an adapter for one or more logical drives. If no adapters with access are specified for any logical drives, the SSP State reverts back to disabled. Specifies the preferred path mode when redundant array controllers are in an PreferredPathMode active-active configuration.
Page 60
Table 6-7 Custom Script File Options (continued) Option Value existing configuration to create a new logical drive. In most cases logical drives must appear in the configuration file in increasing order. Specifies the RAID level for the current logical drive. In Configure mode, the RAID RAID is the RAID for the new logical drive.
Page 61
Table 6-7 Custom Script File Options (continued) Option Value • RAID 5: 8, 16, 32, 64 (default is 16) • RAID ADG: 8, 16, 32, 64 (default is 16) Specifies the Array Accelerator setting for the logical drive. ArrayAccelerator • Enable: Enables the Array Accelerator for the logical drive. This is the default setting for new logical drives.
Table 6-7 Custom Script File Options (continued) Option Value • OpenVMS • TRU64 • Linux • Solaris • Netware • HP • Windows_SP2 Error Reporting When using the cpqacuxe utility, any errors that are encountered are logged to the error.ini file or the specified error file.
Page 63
Table 6-8 Error Codes (continued) Code Error Reason 2819 The controller specified is not specified correctly. Controller '%s' is invalid 2820 The controller specified was not detected. Could not detect Controller '%s' 2818 Invalid Method value. Invalid Method 2819 Invalid Controller value. Invalid Controller 2822 The specified Read Cache/Write Cache Ratio is not supported...
Page 64
Table 6-8 Error Codes (continued) Code Error Reason error does not occur. However, if the controller does not support migration, this error occurs. 2834 The Logical Drive ID is not valid. Invalid Logical Drive 2835 The Logical Drive command is missing from the script file. Logical Drive not specified Some commands were found that require a Logical Drive to work on.
Page 65
Table 6-8 Error Codes (continued) Code Error Reason 278-282, One or more controllers is locked by another machine or user. Controller is locked by another 2564 machine or user There was a problem saving one or more controller Error saving Controller configurations.
Table 6-8 Error Codes (continued) Code Error Reason 2860 The Resource Volume owner cannot be changed if it is a Cannot change Resource Volume configured logical drive. Owner 2861 The controller is not redundant or does not support Controller does not support redundancy settings.
Table 6-9 efibootmgr Options (continued) Options Description Explicitly set BootOrder. The values must be in hex. -o | --bootorder XXXX,YYYY,ZZZZ,... Delete BootOrder -O | --delete-bootorder Set boot manager timeout waiting for user input. -t | --timeout seconds Delete Timeout. -T | --delete-timeout Return version and exit.
Table 6-1 1 efibootmgr Command Line Input (continued) Command Line Input Result • BOOT LOADER: /efi/boot/bootia64.efi • LOAD OPTION: LINUX Generate a boot entry but do not save it in efibootmgr -c -L "Boot" -l /bootia64.efi --test NVRAM. The boot entry values are: bootentry.bin •...
getuuid Synopsis getuuid <disk> | -p| -t Description The getuuid utility retrieves the UUID (Universally Unique ID) used for identifying a storage device or a single partition. Table 6-13 getuuid Options Options Description Disk to from which information will be retrieved. <disk>...
Table 6-14 hpacucli Commands (continued) Commands Description The delete command deletes part of an existing configuration. delete The modify command changes the existing configuration modify The show command outputs information about a device or a list of devices show Examples controller slot=5 array A add drives=1:1-1:5 ctrl slot=1 create type=ld drives=1:1,1:2,1:3,1:5 raid=6 controller slot=5 delete...
Description The hpqlarep utility enables or disable the EFI or BIOS boot setting on QLogic 2G or 4G HBAs. Table 6-16 hpqlarep Options Options Description Saves the HBA configuration to <filename>. /s <filename> Loads the HBA configuration to <filename>. /l <filename> Format The configuration file for EFI boot setting has one of the following formats: For 2G HBAs:...
SSTK-v.3.2# ./hpsetacpi linux ACPI mode was properly set hpsetacpi 89 hpshowdisk Synopsis hpshowdisk -v | -h | -n | -I <idx> | -p| -d | -s Description The hpshowdisk utility helps with the identification of the disks recognized by the system. It can be very useful in situations where the system has lots of disks, typically on SAN architectures.
hwdisc Synopsis hwdisc -f[path]filename Description The hwdisc utility provides an inventory of the server being configured or captured. The hwdisc utility is executed by the server configuration script and captures the following information: • System Name • Serial Number • Asset Tag •...
Example hwdisc –f/mnt/data/hwdisc.xml This command generates the file hwdisc.xml in the /mnt/data location. A typical file generated by the hwdisc command is similar to the following: <!-- generated by Linux hwdisc for IPF version 2.01 --> <HWDiscovery Version="1.0"> <ServerInformation> <SystemName>server rx2600</SystemName> <SerialNumber>US21729947</SerialNumber>...
Table 6-20 hwquery Options (continued) Command Line Argument Description In this argument, variable is the name of an environment variable and <string> is variable=<string> a PCI device name or the name of an element from the hardware discovery file. Arguments must be in quotes if <string> contains spaces. The <string> name is case-sensitive.
Table 6-21 ifhw Options Option Description This argument specifies the hardware discovery file used to run the query. [path]hwdiscfilename This argument specifies the allboards.xml PCI device list file, which is used to convert [path]allboards.xml PCI IDs found in hardware discovery into device names, such as "Smart Array 6402 Controller."...
Table 6-22 Expressions (continued) Operator or Term Result The hardware discovery file is searched for string, and the corresponding value is the value HWQ:string of this term. string is case-sensitive. A literal string, used for comparison. string A literal number, used for comparison. number parted Synopsis...
Page 80
• To create a partition with a file system: mkpartfs PTYPE FTYPE START END PTYPE is partition type: primary, logical or extended. For GPT partition table only “primary” is used. FTYPE is file system type: fat16, fat32, ext2 and linux-swap. •...
A Known Issues This section provides information on the known issues when using SSTK. IMPORTANT: HP recommends that you review the readme file included with SSTK, which may contain late-breaking known issues for this release that could not be included in this document.
No MSA Storage Information Displayed by ACU The ACU does not capture configuration information from the Emulex HBA that connects to MSA storage so no information about the storage device is displayed by the ACU. This is a known issue with the ACU. To avoid this issue, configure Emulex boot devices with hplpcfg.
efibootmgr Utility Issues When using the efibootmgr utility, you should be aware of the following issues: • It is possible to create entries to nonexistent boot loaders. • The EFI interface menu is does not accurately indicate the Active/Inactive flag for the boot entries.