NAME
Tapper::Installer::Precondition::Package - Install a package to a given location
SYNOPSIS
use Tapper::Installer::Precondition::Image;
FUNCTIONS
get_device
Return device name (i.e. /dev/$device) for a given device-id, partition label or $device name (with or without preceding /dev/). Doesn't work with dev-mapper.
@param string - device or reference to array with device ids @param string - base dir prepended to all paths (testing purpose)
@returnlist success - ( 0, device name string) @returnlist error - ( 1, error string)
get_partition_label
Get the label of a partition to be able to set it again at mkfs.
@param string - device file
@returnlist success - ( 0, partition label string) @returnlist error - ( != 0, error string)
configure_fstab
Write fstab on installed system based upon the installed images and partitions.
@return success - 0 @return error - error string
generate_pxe_grub
Generate a simple PXE grub config that forwards to local grub.
@return success - 0 @return error - error string
copy_menu_lst
Copy menu.lst to NFS. We need the grub config file menu.lst on NFS because thats where PXE grub expects it. Still we create the file on the local hard drive because it's faster and allows users to boot with this config without using PXE grub.
@return success - 0 @return error - error string
get_grub_device
Get the disc part of grub notation of a given device file eg. /dev/hda1.
@param string - device file name
@return success - (0, grub device notation) @return eror - (1, error string)
get_partition_number
Get the partition part of grub notation of a given device file eg. /dev/hda1.
@param string - partition number
@return int - grub device notation
generate_grub_menu_lst
Create a grub config file (menu.lst) based on the options in the configuration hash. The function is mainly a wrapper for create_menu_lst_entry and create_new_menu_lst.
@return success - 0 @return error - error string
create_menu_lst_entry
Create and entry for the installed kernel in menu.lst. The kernel must be named /boot/vmlinuz.
@param string - name of the root partition
@return success - 0 @return error - error string
create_new_menu_lst
Create a new menu.lst with default header information. Existing grub configs are silently overwritten.
@return success - 0 @return error - error string
write_menu_lst
Write content to grub file. This encapsulates writing to improve readability and testability.
@param string - what to write @param bool - true = truncate ('>'), false = append ('>>') (append is default)
@return success - 0 @return error - error string
install
Install a given image. This function is a wrapper for image installer functions so the caller doesn't need to care for preparations.
@param hash reference - containing image name (image), mount point (mount) and partition name (partition)
@return success - 0 @return error - error string
generate_user_grub_conf
Generate grub config file menu.lst based upon user provided precondition.
@param string - name of the root partition
@return success - 0 @return error - error string
prepare_boot
Make installed system ready for boot from hard disk.
@return success - 0 @return error - error string
create_mount_point
Create the mount point if its not an existing directory.
@param string - mount point path
@return success - 0 @return error - error string
install_image
Install an image on a given device and mount it to a given mount point. Make sure to set partition label reasonably.
@param string - image file name @param string - device file name @param string - mount point relative to future test system
@return success - 0 @return error - error string
install_image_iso
Install an image of type iso.
@param string - image file name @param int - size of the target partition @param string - device name of the target partition @param string - directory to mount the installed image to
@return success - 0 @return error - error string
install_image_tar
Install an image of type tar.
@param string - image file name @param int - size of the target partition @param string - device name of the target partition @param string - directory to mount the installed image to @param string - partition label
@return success - 0 @return error - error string
install_image_gz
Install an image of type tar.gz.
@param string - image file name @param int - size of the target partition @param string - device name of the target partition @param string - directory to mount the installed image to @param string - partition labeö
@return success - 0 @return error - error string
install_image_bz2
Install an image of type tar.bz2.
@param string - image file name @param int - size of the target partition @param string - device name of the target partition @param string - directory to mount the installed image to @param string - partition labeö
@return success - 0 @return error - error string
copy_image
Install an image to a given partition and mount it to a given mount point.
@param string - device name @param string - image file @param string - mount point
@return success - 0 @return error - error string
unmount
Umounts all images that were mounted during installation in reverse order.
@return success - 0 @return error - error string
AUTHOR
AMD OSRC Tapper Team, <tapper at amd64.org>
BUGS
None.
SUPPORT
You can find documentation for this module with the perldoc command.
perldoc Tapper
ACKNOWLEDGEMENTS
COPYRIGHT & LICENSE
Copyright 2008-2011 AMD OSRC Tapper Team, all rights reserved.
This program is released under the following license: freebsd
1 POD Error
The following errors were encountered while parsing the POD:
- Around line 581:
Non-ASCII character seen before =encoding in 'labeö'. Assuming CP1252