Redpaper Vasfi Gucer Francesco Latino Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment In this document we describe how to get a bare metal machine work with a Linux operating system using one of the main features of Tivoli® Provisioning Manager for OS Deployment: the deployment of a profile. We also create software packages that are automatically installed on the target computer after the deployment process. We assume that you have a working Tivoli Provisioning Manager for OS Deployment environment. For information about how to install Tivoli Provisioning Manager for OS Deployment, you can refer to Deployment Guide Series: Tivoli Provisioning Manager for OS Deployment V5.1, SG24-7397. This document has the following sections: “Introduction and general requirements” on page 2 “Creating an unattended setup profile” on page 3 “Creating software packages” on page 12 “The deployment process” on page 23 “Cloning a machine” on page 30 “Deploying the cloned profile” on page 37 © Copyright IBM Corp. 2007. All rights reserved. ibm.com/redbooks 1 Introduction and general requirements The first step is to choose what to deploy. With Tivoli Provisioning Manager for OS Deployment, you can either clone a machine or you can create an unattended setup profile. The former option copies the operating system together with the installed software from a source machine to a destination machine. The latter performs an automatic installation of an operating system as though you are at the machine with the installation CDs. We start this chapter with the steps to perform an unattended installation of a Linux profile with some software packages that will be deployed on a bare metal machine. Next, we describe the cloning process of a Linux machine and the customizing of the captured image. According to the Tivoli Provisioning Manager for Operating System Deployment Guide (Fix Pack 1), SC32-2582, the UNIX/Linux® supported operating systems for deployments are as follows: Linux Fedora Core: Fedora3, Fedora4 (cloning + setup) RedHat Enterprise Linux (RHEL): versions 3, 4 (cloning + setup) SuSE Linux Professional: versions 8, 9 (cloning + setup) SuSE Linux Enterprise Server (SLES): version 9 (cloning + setup) Debian GNU-Linux 3.1 (Sarge) (cloning ONLY) Sun Solaris™ (Sparc): versions 8, 9, 10 (cloning + setup) For both the unattended set up and the cloning deployments, we use Red Hat Enterprise Linux 4, AS Update 3. In terms of Tivoli Provisioning Manager for OS Deployment, we will do the following: Create an unattended Linux installation profile using RHEL 4 installation CDs. Clone a machine having the RHEL 4 operating system. For a target machine, the official requirements are as follows: PXE-compliant bootrom, either version 2.00 and above Minimal CPU: PentiumR type level Minimal RAM memory: 128 MB Video Electronics Standards Association (VESA) release 2.0 or later, compliant Video BIOS to get high resolution (VGA fallback is always possible in case of incompatibility). However, Tivoli Provisioning Manager for OS Deployment can also work on headless machines. 2 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Either a traditional Advanced Technology Attachment (ATA) drive with Ultra™ Direct Memory Access (DMA) support if speed is required or a BIOS-supported hard drive. Desktop Management Interface (DMI) support for collecting hardware information, such as model and serial number. To meet these requirements, we use machines equipped with at least 8 GB of disk space since the Linux installation and the hidden partition used by Tivoli Provisioning Manager for OS Deployment during the deploy may have problems with hard disk of lower capacity. Creating an unattended setup profile In order to create a new unattended profile, perform the following steps: 1. Select OS Deployment → Profiles, and then choose the New Profile item. The Web Interface Extension component is needed for this procedure. If you have not installed this in your system you will get the message shown in Figure 1. Figure 1 The Web interface extension is needed when creating new profiles 2. If the Web interface extension is running on your machine, you can proceed to creating a new profile. Configure the profile to do the following: – Be a Linux unattended setup profile – Set correctly the partitions in order to have the following: • A swap partition of 1GB • A boot partition of 256 MB • A root partition on the remaining disk space – Set KDE as the desktop environment Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 3 – Install some basic software (RPMs provided in the installation CDs) – Set correctly the language and regional settings 3. The first window of the wizard asks you the operating system that will be contained in the profile. Select the Linux system profile option as shown in Figure 2. Figure 2 Choosing the OS on the Profile Wizard 4. In the next Profile Wizard window, choose the Unattended setup, as shown in Figure 3 on page 5. This is because we want to install a new operating system using the installation CDs. Since one of the main purposes of Tivoli Provisioning Manager for OS Deployment is to make the installation process simpler and faster, the profile wizard will continue prompting the installation parameters in order to avoid the manual intervention on the client machine after the deploy now command is submitted. All these parameters that are needed to install an operating system on a bare metal machine are automatically provided to the process without any user intervention at a later time. Moreover, Tivoli Provisioning Manager for OS Deployment allows users to modify these configuration parameters after the completion of the wizard. 4 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 3 Choosing the Unattended setup option in the Profile Wizard 5. As we are installing the system on a bare metal machine, we need to configure the partition layout. We will accept the default configuration, which is created in the following order: – A SWAP partition of 1024 MB. – A separate partition where the “/boot” filesystem is mounted of 256 MB. – A partition (formatted as ext3) on the remaining disk size where the root file system is mounted. We suggest allocating 100% of the remaining disk size to the root file system as shown in Figure 4 on page 6 and setting it in the last position of the disk in order to avoid insufficient space problems. This failure may arise both by the Linux unattended installation or by the deployment process. We experienced it when setting the root partition to a fixed 4 GB size. Allocating all the disk space for the last root partition should prevent both the problems since the following applies: – The Linux installation has all the available disk blocks for copying binaries (8GB in our case). – The deployment process has all the available disk blocks for temporary storage (since it uses the free space remaining in the last partition). Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 5 Figure 4 Setting the partition layout in the Profile Wizard 6. The partition layout can be subsequently modified by accessing the properties of the specific configuration. Figure 5 shows how the editor of the partition layout appears from the Web console. Figure 5 Partition layout editor for the configuration created 7. The next steps (see Figure 6 on page 7) ask you to select the path where the installation CDs/DVDs can be accessed. Since all the deployment steps do not require you to manually insert the needed media on the target machine, all the data is required to be loaded on the server at this step. 6 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 6 Select source media in the Profile Wizard 8. Figure 7 shows that the operating system we provided in the installation CDs was recognized and we are prompted for the base configuration to use. Here, we choose the KDE option. Figure 7 Choosing the base configuration in the Profile Wizard Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 7 9. In the last two steps of the profile wizard, we can do the following: – Select which of the software provided with the installation CDs is added to the machine. – Set the language and regional settings. Figure 8 and Figure 9 on page 9 shows our settings. Figure 8 Additional software installation in the Profile Wizard 8 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 9 Language and regional settings in the Profile Wizard 10.Since we are not using advanced settings, we will leave the File field empty as shown in Figure 10. Figure 10 Advanced configuration in the Profile Wizard Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 9 11.Finally, insert the name of the profile with a descriptive comment. Take care to describe the complete name of the operating system we used, Red Hat Enterprise Linux 4 AS, Update 3 as shown in Figure 11. Figure 11 Inserting name and description of the profile in the Profile Wizard 12.After completing all the configuration steps, the server will load all the data and creates the profile in its database. Figure 12 on page 11 shows that you may be prompted to insert different installation CDs. 10 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 12 Required installation media in the Profile Wizard 13.If all the steps are performed correctly, you will receive a message stating that the profile was successfully created as shown in Figure 13. Figure 13 Outcome message in the Profile Wizard Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 11 14.After completing the Profile Wizard, you can also use the Web console to modify the recently specified settings. To perform this operation, navigate through your profiles list (OS Deployment → Profiles), and edit the specific binded configuration. Figure 14 Profile details 15.You cannot manually bind the configuration created with this profile to a specific host since it is automatically performed after the first deploy. If you want to bind manually, do the following: a. Go to the Hosts list. b. Double-click the specific host. c. Manually bind the configuration from the Binding panel. Creating software packages You may find it useful to add some specific software installations at the end of the deployment process. Software packages can let you upgrade your bare bones system installation to a bare metal machine building process that leads to a working computer equipped with the needed applications. If the required software is provided with the installation CDs, you can use the previous wizard steps (as described in “Creating an unattended setup profile” on page 3), and select those needed programs from the Additional software list (see Figure 8 on page 8). Otherwise you can use the “Software packages” feature of Tivoli Provisioning Manager for OS Deployment to install some programs or to perform other configuration operations on the target machine. In the following paragraphs, we describe how to create and configure software packages and how to bind them to target machines. 12 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Our software packages perform the following operations: Install an RPM containing the DHCP server. Copy and unpack the Tivoli Provisioning Manager for OS Deployment installer provided in a tar.gz format. Copy a system file containing release information. RPM software packages Perform the following steps to create the software package that installs the DHCP server from an RPM: 1. Choose the New Software item from OS Deployment → Software Packages. In the first window of the Software Wizard, select RPM as the type of package: Figure 15 Choosing the type of software package in the Software Wizard 2. Provide the full path of the RPM package that will be loaded into the Tivoli Provisioning Manager for OS Deployment server. The package that is used is a RPM binary containing the DHCP server. Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 13 Figure 16 Inserting the full path to the package in the Software Wizard If the RPM is correctly loaded by the wizard, some general information will appear as shown in Figure 17. Figure 17 General package information in the Software Wizard 3. Next, we are prompted to insert a name and a description that will help to identify this software package through the list. We recommend that you insert a descriptive value. See Figure 18 on page 15. 14 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 18 Name and description for the package in the Software Wizard 4. Next the most important window of the wizard is shown asking us to define the following: – When to apply the software package. – Where to copy the RPM package. – Which command to use to install the RPM. Figure 19 shows the selected values. Figure 19 Software package parameters in the Software Wizard 5. If all the wizard steps are performed correctly, you will get a message stating that “Your software package was successfully created” as shown in Figure 19. Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 15 Figure 20 Outcome message in the Software Wizard In the list of the software packages, it will appear as shown in Figure 21. Figure 21 List of the software packages 6. If you right-click each software package and select Reorder software package, you can see all the existing software packages grouped by the step of the deployment process, which is when they will be added to the target system. It is very important to choose the right order for each package in the list. We choose to add the software packages after one additional reboot of the system. 16 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 22 Software package order in the deployment process Copying and unpacking software packages Perform the following steps to copy and unpack the software packages: 1. For the Tivoli Provisioning Manager for OS Deployment installer (we chose to copy and unpack it on the target machine) which is provided in a tar.gz format, we need to create another software package with the “Custom action“ option (see Figure 23 on page 18): Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 17 Figure 23 Software package type in the Software Wizard 2. Choose to copy a file on the target system, since we have to put the installer on the machine where it will be installed. Figure 24 Type of operation in the Software Wizard 3. Be careful when you are prompted to insert the source folder. Here, you will have to insert the path of the folder containing the installer that will be copied on to the target machine (see Figure 25 on page 19). 18 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 25 Source path of the file in the Software Wizard 4. As previously described, we need to insert a name to identify this profile in the database as shown in Figure 26. Figure 26 Name and description for the package in the Software Wizard 5. The last panel of the wizard requires you to insert the following parameters: – Destination path /usr/local – Command line cd /usr/local ; gunzip -c /usr/local/TPMfOSd-5.1.000.32-linux.tar.gz | tar -xvf – Installation stage After one additional reboot. Note that in the command line section, we insert commands that unpack the Tivoli Provisioning Manager for OS Deployment installer as shown in Figure 27 on page 20. Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 19 Figure 27 Script details in the Software Wizard After the wizard steps are completed, the creation of the software package starts. Executing a command In this last package, we want to copy in the root directory of the target machine, a file (/proc/version) containing some useful release information. 1. To achieve this, we create a new software package called rhel release that executes a single command in order to copy the specific file on the required destination. After choosing the A custom action on the target computer option, select the Execute a single command option as shown in Figure 28. Figure 28 Type of software package in the Software Wizard The syntax of the command that will perform the copy is as follows: cp /proc/version /rhel_release When the software package is deployed, we will have this new file in the root folder of the target machine as shown in Figure 29 on page 21. 20 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 29 Command details in the Software Wizard Software packages binding As for configurations, you can bind software packages to hosts in order to create a permanent relationship and automatically install them during each deployment performed. This operation can be performed in the following two ways: Manually, for each host-software package Automatically with binding rules Manually binding software packages to a host To perform manual binding 1. Select the host to which you want to associate a software binding from the Hosts list. 2. Double-click the host name to accessing to the Binding panel. 3. Add the specific software package or configuration. We manually bind to the target host two of the three packages created: – DHCP server RPM – Tivoli Provisioning Manager for OS Deployment installer Figure 30 on page 22 shows what we did. Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 21 Figure 30 Our bindings for the target computer Automatically binding software packages to a host You can also create software packages that can be automatically binded to a host using matching criteria. Using this process you avoid adding each software package to each host manually. We can copy the file containing the release information, the rhel release software package, for only one particular Linux distribution. This can be done without manually binding the software package for each of the several hosts where the distribution will be deployed. We can also add a binding rule to the software package in order to bind it automatically to the hosts where that specific Linux release will be deployed. To achieve this, perform the following steps: 1. Add a new binding rule for the rhel release package. 2. Select, as matching criteria, that the deployed profile is the specific RHEL 4 unattended setup profile. 22 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 31 Binding rule for the rhel release software package As you can see in the binding panel of the specific host, the rhel release software package was automatically binded since the RHEL 4 Linux unattended profile (the matching criteria) was already bound. During deployment, this software package is added to the system as the previous two (DHCP server RPM and Tivoli Provisioning Manager for OS Deployment installer). Figure 32 Software package binding for the target computer The deployment process After creating the profile and the software packages, choose the related bindings. We can start the deploy on the specific host. In the Deploy now window, choose the following: The deployment scheme to use The profile to deploy Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 23 The software packages to add If you manually bound for the specific host the previously created configuration and software packages in the previous step, they are checked in the related lists, namely Edit manual configuration bindings and Edit software configuration bindings. Since these lists only show the manual link to profiles and packages, the binding entailed by the automatic rules are not checked even if they will be deployed. Figure 33 and Figure 34 on page 25 show that we want to deploy the Linux RHEL 4 profile with the DHCP and Tivoli Provisioning Manager for OS Deployment software packages manually added. Even if the rhel release software package is not checked in the list (since we did not add it manually) it will be deployed because it matches its binding rule. Figure 33 Deploy now options 24 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 34 Manual software bindings After starting the deployment from the Web console, the client machine performs a network boot in order to load the Tivoli Provisioning Manager for OS Deployment mini operating system. This is a simple operating system that contacts the Tivoli Provisioning Manager for OS Deployment server and runs the deploy on the target machine. Following is the sequence of the steps performed on the client machine during the deploy of our profile with the binded software packages. 1. The client machine boots from the network and loads the Tivoli Provisioning Manager for OS Deployment mini operating system. 2. The deployment starts on the client machine. 3. After the “Starting system installation” step, the Linux installer, called Anaconda, is started on the client machine. 4. Anaconda performs the unattended system installation on the client machine. 5. The client machine reboots from the hard disk, and the early installed Linux is loaded to install the software packages binded to the host. 6. The client machine reboots, forcing the loading of Tivoli Provisioning Manager for OS Deployment mini operating system for the last deployment steps. 7. The client machine informs customer that the deploy ended correctly. Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 25 Note: The second reboot after OS installation and before software installation (step 5) is optional, but is recommended to minimize the risk of a file system corruption. Figure 35 shows the sequence of operations performed on the client machine after booting from the network. You can see the Tivoli Provisioning Manager for OS Deployment window on the client that displays the action that is currently being performed. Figure 35 Copy operating system files step on the target machine Figure 36 on page 27 shows the last step performed on the target computer before the Linux installer is loaded. There is a Tivoli button in this window that helps you during troubleshooting operations. 26 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 36 Starting system installation on the target machine After the Linux installation is configured by the deployment process, the installer (called Anaconda) is launched to perform the unattended installation. All the parameters provided in this step can be modified through editing the profile and the binded configuration from the Web console. Figure 37 The Linux installer started on the target client After Anaconda completes its tasks, the system reboots from hard disk and the Linux operating system installed earlier is loaded. During this step, the software packages are also installed. Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 27 Figure 38 Linux is loaded on the target computer Figure 39 Window before the last reboot Finally the target machine forces another reboot from Tivoli Provisioning Manager for OS Deployment mini operating system in order to complete the remaining operations and to inform the user of the status. If the installation of the operating system encountered some problems, some errors may appear on the client during this last step. As mentioned earlier, you may find the Tivoli button very useful to show errors or to upload logs. 28 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 40 Last installation step on the target computer Figure 41 displays the message showing the successful completion of the deployment operation. Figure 41 Outcome message on the target machine After completion, we are prompted to shutdown or reboot the freshly installed system. In order to check whether the bare metal machine is working as required, we run the client machine and log into the system. The DHCP server package was correctly installed since the rpm qa command shows it. Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 29 Figure 42 Checking DHCP server RPM installation Also the Tivoli Provisioning Manager for OS Deployment installer was correctly copied and unpacked as shown in Figure 43. Figure 43 Checking the Tivoli Provisioning Manager for OS Deployment installer Finally the rhel release package was added to the deploy since we found the copied file in the root directory, as shown in Figure 44. Even if this software package was not manually added to the binding list, it matched the binding rule that we created and was added to the deploy. Figure 44 Checking the rhel release package Cloning a machine Another important feature of Tivoli Provisioning Manager for OS Deployment is the cloning of machines with the Windows® or Linux operating system running. Creating a clone of a machine means building an image of the content its disks contain: 30 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment The operating system The operating system settings and drivers The software and the data During the cloning operations, all the content of the disks of a source machine are imported as an image on the server to deploy it at a later time. This means that you can clone a machine used as a prototype and deploy its image on several machines that appear as the original one. Obviously, the cloning operation implies the customizing of some basic settings on each target machine. We show how to capture the image of a source machine running a Linux operating system and how to deploy it taking care of some useful advice. In the following sections we used the Linux RHEL 4 computer, which was created earlier, as a source machine. We deploy its cloned profile on a machine of the same model but with a hard disk of different capacity. Although a wide range of modifications are possible on each captured profile, the cloning procedure should be performed between machines of similar models in order to avoid incompatibility problems. We explain how to customize a cloned image modifying the partition scheme to use all of the disk size of the target machine. The cloning steps may be summarized into the following: Run a “make a new image” task from the source client to capture its image. Modify the captured profile on the server to fit the destination machine characteristics (we will change only the partition scheme). Deploy the profile on the destination machine. Capturing the image Before creating an image of a source machine, you need to perform some cleaning steps that will remove unwanted files: Empty the trash Delete temporary directories and files Disconnect network drives and remote printers Note that the Tivoli Provisioning Manager for OS Deployment supports both GRUB and LILO bootloaders, but we strongly suggest using the former instead of the latter. If you do not plan to use the Redeployment feature, it can be installed on the MBR or on the boot sector of the Linux boot partition. The cloning operation on the Linux machine does not require that you install and run a specific software, such as Sysprep for Windows systems, before starting Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 31 the capture. For Linux cloned profiles, Tivoli Provisioning Manager for OS Deployment automatically copies and uses its own tool called Linprep that configures the destination machine after the deployment with the needed customization. Linprep is used only for cloning profiles and it is copied during deployment on the target machine. It is run at the first boot of the target machine just after the deploy. When the “Starting system installation” step of the deployment process completes and the machine boots the earlier installed system (the profile just copied on the target machine), installation is launched by a script in /etc/init.d at runlevel 1. The customizations performed are as follows: Reconfigure the network settings, the primary network interface (DHCP or static ip address), and the gateway and similar tasks. Reinstall the bootloader (GRUB or LILO). The bootloader is software that stores the physical address of the kernel to load. Since this address changes at each new deployment, the bootloader cannot be installed by Tivoli Provisioning Manager for OS Deployment during the deployment operations; therefore, Linprep runs LILO or GRUB installers at the first boot of the system when this address is known and will not change. After executing Linprep, the Linux system is rebooted (other runlevel 1 scripts are not executed) and the deployment completes. Note: In future releases, it is expected that Tivoli Provisioning Manager for OS Deployment will use the Web interface extension interface instead of Linprep. 1. The first step to start the capture is to access the source machine and boot it from the network in order to start the Admin Toolkit interface on the client. In future releases, it will be possible to capture the image of a machine from the Web console, while in the current release you have to physically access the source client. You may need to manually bind the Admin Toolkit interface on the specific machine; otherwise, no operations will be allowed on it. Figure 45 on page 33 shows the main menu of the Admin Toolkit interface. 32 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 45 Main menu of the Admin Toolkit interface 2. Since we need to capture an image of this machine, choose the make a new image option. Figure 46 Make a new image task on the Admin Toolkit interface 3. Insert the name of the profile that will contain this image (cloneRHEL4), and accept to create a default configuration (automatically bound) for it. Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 33 Figure 47 Inserting the profile name in the Admin Toolkit interface Figure 48 Default configuration in the Admin Toolkit interface 4. At the end of the operations, if the captured image is correctly stored in a profile, you will see the message Operation Completed as shown in Figure 49. Figure 49 Outcome message in the Admin Toolkit interface 34 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 5. You can browse the Web console to find the captured profile in the list as shown in Figure 50. Figure 50 List of profiles in the Tivoli Provisioning Manager for OS Deployment server Customizing the captured profile During the deployment of the captured image, we advise you to ensure that Tivoli Provisioning Manager for OS Deployment gets enough disk space for the deployment operations. On the target machine, the process uses both the unpartitioned space at the end of the hard disk and the free space at the end of the last partition. The sum of these areas must be large enough for storing all partition images that are deployed at the same time on the client computer—it should typically be half of the size of the data on the hard disk—the available space should be 1 GB if your OS partition contains about 2 GB of data. We suggest that you ensure that the swap partition of the image is not at the end of the disk when deploying a Linux system profile, since this partition is usually small and if there is no unpartitioned space (as in our case where we will partition all the available disk space), the deployment of the cloned profile will fail because of insufficient free disk space. Since our destination machine has a hard disk with higher disk size (10GB), we modify the captured profile to use the 100% of the disk space for the last root partition. We also check that the last partition (since we will not leave any unpartitioned space) will be enough for the deployment process. Figure 51 on page 36 shows our profile after the capturing. Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 35 Figure 51 The partition layout of the captured image Next, set the third partition, where the root file system will be mounted, to use all the available disk space as shown in Figure 52. Figure 52 Using all the available disk space After the changes, the partition scheme will use all the available disk space of the target machine (10GB) instead of the fixed size of the source machine (8GB), as shown in Figure 53. Figure 53 The partition layout after the changes 36 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Deploying the cloned profile After the customization steps, we can distribute the cloned profile to the target machine. We select the destination client from the hosts list and deploy the cloneRHEL4 profile. Figure 54 Deploying the cloned profile cloneRHEL4 Note: In the manual bindings of the software packages, there is no software selected since we are deploying a cloned profile and we will get all the installed software from the source machine. Figure 55 No manual bindings for software packages During the deploying operations, the target machine performs the following steps: Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 37 Boot from the network to connect to Tivoli Provisioning Manager for OS Deployment server. Start the deployment. After the “Starting system installation” step, run the earlier installed system. Run Linprep, then reboot. Boot from the network (forced by the deployment process) to terminate the installation. Figure 56 shows that the deployment process is started on the client. Figure 56 Deployment step on the client After the “Starting system installation” step, the system runs the earlier copied Linux image. Then Linprep is launched to perform the needed customization. After the configuration ends, a reboot from the Tivoli Provisioning Manager for OS Deployment mini-operating system is forced, and the final deployment steps are performed. Note: Note that Linprep is not customizable. You can only customize the profile you have to deploy. Figure 57 on page 39 shows one of the operations performed after the reboot—resizing the last partition used as temporary storage. 38 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Figure 57 Last deployment steps At the end of the process, we receive a message as shown in Figure 58. Figure 58 Outcome message at the end of the cloning process If we run Linux, we can check the following: All the software of the source machine that was installed on the destination. For example, the DHCP RPM was installed even if not binded. Whether the disk partitioning is correctly set. The root partition uses all the available space. Linprep log that shows the Linprep operations. Figure 59 shows the disk size to 9 GB of the last root partition and the DHCP server installed as it was on the source machine. Figure 59 DHCP server installed For an example of Linprep.log, see Example 1 on page 40. Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment 39 Example 1 Linprep.log Distribution : unknown RedHat Parsing /etc/linprep.inf..... Time Zone = 110 Boot loader = grub Root partition = disk://0:3 Boot partition = disk://0:2 BootLoaderLocation = disk://0:0 MacAddress = * Language -> Keyboard = 0409 Host Name = pc-000C2955E702 Found GRUB bootloader Changing administrator password Change root password: executing: echo root:XXXX | /usr/sbin/chpasswd Changing DNS settings Generate new /etc/resolv.conf (DNS) Changing network configuration Modifying /etc/sysconfig/network OK Modifing /etc/sysconfig/network-scripts/ifcfg-eth0 DHCP actived OK Changing hostname Modifying /etc/hosts Adding 127.0.0.1localhost pc-000C2955E702 OK Changing timezone Modifing file /etc/sysconfig/clock new Timezone : Etc/GMT+1 OK Changing keyboard mapping Adjusting keyboard locale console keytable : us ERROR with file /etc/X11/XF86Config-4 : No such file or directory Unable to open device /dev/sda Found a valid RAD protected MBR on /dev/hda Using /dev/hda as root device Installing GRUB on MBR Executing grub-install --recheck '(hd0)' Saving MBR Linprep finished. 40 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment Notices This information was developed for products and services offered in the U.S.A. IBM may not offer the products, services, or features discussed in this document in other countries. Consult your local IBM representative for information on the products and services currently available in your area. Any reference to an IBM product, program, or service is not intended to state or imply that only that IBM product, program, or service may be used. Any functionally equivalent product, program, or service that does not infringe any IBM intellectual property right may be used instead. However, it is the user's responsibility to evaluate and verify the operation of any non-IBM product, program, or service. IBM may have patents or pending patent applications covering subject matter described in this document. The furnishing of this document does not give you any license to these patents. You can send license inquiries, in writing, to: IBM Director of Licensing, IBM Corporation, North Castle Drive Armonk, NY 10504-1785 U.S.A. The following paragraph does not apply to the United Kingdom or any other country where such provisions are inconsistent with local law: INTERNATIONAL BUSINESS MACHINES CORPORATION PROVIDES THIS PUBLICATION "AS IS" WITHOUT WARRANTY OF ANY KIND, EITHER EXPRESS OR IMPLIED, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF NON-INFRINGEMENT, MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Some states do not allow disclaimer of express or implied warranties in certain transactions, therefore, this statement may not apply to you. This information could include technical inaccuracies or typographical errors. Changes are periodically made to the information herein; these changes will be incorporated in new editions of the publication. IBM may make improvements and/or changes in the product(s) and/or the program(s) described in this publication at any time without notice. Any references in this information to non-IBM Web sites are provided for convenience only and do not in any manner serve as an endorsement of those Web sites. The materials at those Web sites are not part of the materials for this IBM product and use of those Web sites is at your own risk. IBM may use or distribute any of the information you supply in any way it believes appropriate without incurring any obligation to you. Information concerning non-IBM products was obtained from the suppliers of those products, their published announcements or other publicly available sources. IBM has not tested those products and cannot confirm the accuracy of performance, compatibility or any other claims related to non-IBM products. Questions on the capabilities of non-IBM products should be addressed to the suppliers of those products. This information contains examples of data and reports used in daily business operations. To illustrate them as completely as possible, the examples include the names of individuals, companies, brands, and products. All of these names are fictitious and any similarity to the names and addresses used by an actual business enterprise is entirely coincidental. COPYRIGHT LICENSE: This information contains sample application programs in source language, which illustrates programming techniques on various operating platforms. You may copy, modify, and distribute these sample programs in any form without payment to IBM, for the purposes of developing, using, marketing or distributing application programs conforming to the application programming interface for the operating platform for which the sample programs are written. These examples have not been thoroughly tested under all conditions. IBM, therefore, cannot guarantee or imply reliability, serviceability, or function of these programs. You may copy, modify, and distribute these sample programs in any form without payment to IBM for the purposes of developing, using, marketing, or distributing application programs conforming to IBM's application programming interfaces. © Copyright International Business Machines Corporation 2007. All rights reserved. Note to U.S. Government Users Restricted Rights -- Use, duplication or disclosure restricted by GSA ADP Schedule Contract with IBM Corp. 41 Send us your comments in one of the following ways: Use the online Contact us review IBM Redbooks form found at: ibm.com/redbooks Send your comments in an email to: redbook@us.ibm.com Mail your comments to: IBM Corporation, International Technical Support Organization Dept. HYTD Mail Station P099, 2455 South Road Poughkeepsie, NY 12601-5400 U.S.A. ® Redpaper ™ Trademarks The following terms are trademarks of the International Business Machines Corporation in the United States, other countries, or both: IBM® Redbooks (logo) ® Tivoli® The following terms are trademarks of other companies: Solaris, Ultra, and all Java-based trademarks are trademarks of Sun Microsystems, Inc. in the United States, other countries, or both. Windows, and the Windows logo are trademarks of Microsoft Corporation in the United States, other countries, or both. Linux is a trademark of Linus Torvalds in the United States, other countries, or both. Other company, product, or service names may be trademarks or service marks of others. 42 Deploying Linux Systems with Tivoli Provisioning Manager for OS Deployment