1. Introduction

This document describes how to use preseeding to automate installation of an AES XvBA Reference System. Preseeding is a feature of the Ubuntu®
[Ubuntu is a registered trademark of Canonical Ltd.]
packaging system that provides a way to seed answers to questions asked during installation, without having to supply them manually at the time of installation.

Caution

This guide documents commands and procedures which, if used improperly, can result in permanent data loss. Please read it carefully.

1.1. What is the AES XvBA Reference System?

The AES XvBA Reference System is a reference installation of Ubuntu designed for AES customers to:

  • evaluate the AMD Proprietary Linux®
    [Linux is a registered trademark of Linus Torvalds in the United States and other countries.]
    Graphics Driver;

  • evaluate XvBA; and

  • facilitate investigation, diagnosis, and reporting of bugs in software components supplied by AES.

It’s roughly equivalent to an installation of Ubuntu Desktop with a few extras:

  • AMD Proprietary Linux Graphics Driver,

  • XvBA SDK, and

  • XvBA Tools.

2. Changes since the previous release

Support for Ubuntu 11.04 Natty Narwhal

mkusb.sh now works with the Ubuntu 11.04 Natty Narwhal alternate installer and a package archive (natty.tgz) is provided.

Catalyst 11-7 and 11-8

Catalyst 11-7 and 11-8 releases of the AMD Proprietary Linux Graphics Driver are included in the package archives for all supported distributions.

Prepared images for Ubuntu 11.04

Prepared installer images for Ubuntu 11.04 Natty Narwhal are available for download. This simplifies use of the AES automated installer as it’s no longer necessary to use mkusb.sh or to have a host Linux system.

Preparation of USB disk images

The DEVICE argument to mkusb.sh can name an image file, rather than just a block device, in which case it creates a disk image which can be written to USB disk using dd on Linux or a tool like Image Writer for Windows.

Preparation of ISO images

The DEVICE argument to mkusb.sh can name an ISO image file, in which case it creates an ISO image which can be written to DVD.

Use without AMD graphics

The installer can be used on a system without a supported AMD graphics adapter. This is useful for testing and/or for installation in a virtual machine. The AMD Proprietary Linux Graphics Driver will be installed but left unconfigured.

Realtek r8168 driver

The r8169 driver included in the Ubuntu 11.04 installer and default kernel package is unreliable when used with a Realtek RTL8111/8168B NIC. The Realtek r8168 driver is now included in the installer and in the Ubuntu 11.04 package archive. It will be used by the installer and installed on the target system in preference to the r8169.

3. Requirements

Host system (optional)

A PC running a Linux distribution of your choice
[Tested on Ubuntu and Debian. Changes may be required for other distributions.]
. Hardware specifications are not important. You will use this system to prepare the USB stick. A host Linux PC is required only if using mkusb.sh to prepare your own installer images. It’s not required if downloading prepared ISO or USB disk images.

Target system

A PC to be installed with the AES XvBA Reference System. Check the Ubuntu Installation Guide for minimum hardware requirements. In addition, it should have a supported AMD graphics adapter (discrete or integrated).

Internet connection

You will need Internet access to download the installer components. Additionally, the installer requires Internet access to download extra packages and updates during installation.

USB stick or DVD

A 2GB or larger USB stick or a recordable DVD.

4. Installing the AES XvBA Reference System

Installation of an AES XvBA Reference System is carried out in two steps:

  1. prepare a bootable USB stick or DVD containing the AES automated installer, then

  2. install the target system by booting it from the USB stick.

4.1. Preparing bootable media

The previous release required use of the mkusb.sh script to prepare a bootable USB stick. While this method is flexible and powerful, providing opportunities for customization, it requires a host Linux system and moderate Linux skills. To simplify installation, we have built installer images for Ubuntu 11.04 Natty Narwhal and made them available for download. You don’t require any Linux skills or a Linux host system to use these images.

In summary, there are now four methods of preparing bootable media:

Preparing a bootable USB stick — the easy way

Download a prepared USB disk image and write it to a USB stick.

Preparing a bootable DVD — the easy way

Download a prepared ISO image and write it to DVD.

Preparing a bootable USB stick — the flexible way

Use mkusb.sh to prepare a USB stick. This is the only method that was available in previous releases.

Preparing a bootable DVD — the flexible way

Use mkusb.sh to prepare an ISO image and write it to DVD.

4.2. Preparing a bootable USB stick — the easy way

For Ubuntu 11.04 Natty Narwhal 32-bit, download: natty-i386.zip.

For Ubuntu 11.04 Natty Narwhal 64-bit, download: natty-amd64.zip.

Unzip it to create natty-i386.img or natty-amd64.img, then write the image to your USB stick. If you’re running Windows®
[Windows is a registered trademark of Microsoft Corporation in the United States and other countries.]
, you can use Image Writer for Windows or a similar program. If you’re using Linux, use dd, like this:

Caution

This command will overwrite the contents of your USB stick, including its boot block, partition table, and the contents of all partitions.

sudo dd if=natty-i386.img of=/dev/sdb bs=1MB

This example makes a few assumptions, specifically:

  • you’re using an Ubuntu host system where sudo is required to gain administrative privileges,

  • your USB stick appears as /dev/sdb, and

  • your USB stick is not mounted.

You may need to adjust these commands. If your system is configured to mount your USB stick automatically, you should unmount it before running dd.

4.3. Preparing a bootable DVD — the easy way

For Ubuntu 11.04 Natty Narwhal 32-bit, download: natty-i386.iso.

For Ubuntu 11.04 Natty Narwhal 64-bit, download: natty-amd64.iso.

Burn the ISO image to DVD using the DVD burning tool of your choice.

4.4. Preparing a bootable USB stick — the flexible way

The AES automated installer is based on Ubuntu’s alternate installer. This package includes a shell script (mkusb.sh) for making a bootable USB stick by combining the alternate installer ISO image with the configuration files and auxiliary scripts provided.

For clarity, the overview and detail below use concrete file names, URLs, and device names where practical. You should adapt these to the particulars of your system.

Caution

Don’t just type in these commands blindly without understanding them. Doing so can harm your system.

Overview
mkdir /var/tmp/aes-install                                                           1
cd /var/tmp/aes-install                                                              1
wget http://ubuntu-cd.mirror.iweb.ca/10.04/ubuntu-10.04.2-alternate-i386.iso         2
wget http://xvbat.sourceforge.net/d-i/aes.tgz                                        3
wget http://<aes-package-archive>/lucid.tgz                                          4
tar xvfz aes.tgz                                                                     5
tar xvfz lucid.tgz -C aes                                                            5
cd aes                                                                               5
sudo ./mkusb.sh /var/tmp/aes-install/ubuntu-10.04.2-alternate-i386.iso /dev/sdb1     6
sudo eject /dev/sdb                                                                  6
1 Make and change to a working directory.
2 Download the Ubuntu alternate installer.
3 Download the AES automated installer.
4 Download the AES package archive.
5 Unpack the AES automated installer and package archive.
6 Create the USB stick.

4.4.1. Download the Ubuntu alternate installer

Go to Ubuntu alternative download, then click location near you under Alternate installer details. It will take you to a random Ubuntu mirror near you. The mirrors can be organized differently but should look similar to this one at iWeb Canada.

Clicking a release number (10.04.2, 10.10, or 11.04) will take you to a download page from where you can download the alternate installer ISO image. Scroll down to Alternate install CD. In Firefox on Linux, you can right click over the link and select Copy Link Location, then paste it into a terminal for use with wget, like this:

wget http://ubuntu-cd.mirror.iweb.ca/10.04/ubuntu-10.04.2-alternate-i386.iso

4.4.2. Download the AES automated installer

If you’re reading this, you probably already have it. If not, download it here or use this command:

wget http://xvbat.sourceforge.net/d-i/aes.tgz

This archive is not tied to a specific Ubuntu release; you can use it with any supported release. See this FAQ.

4.4.3. Download the AES package archive

The AES package archive is a compressed tar archive containing:

  • the AMD Proprietary Linux Graphics Driver,

  • XvBA SDK, and

  • XvBA Tools,

pre-packaged as native Ubuntu packages and organized into an Ubuntu package repository. The package archive is distribution specifc.

For Ubuntu 10.04 Lucid Lynx, download lucid.tgz.

For Ubuntu 10.10 Maverick Meerkat, download: maverick.tgz.

For Ubuntu 11.04 Natty Narwhal, download: natty.tgz.

4.4.4. Unpack the AES installer and package archive

Unpack the AES installer and package archive into your working directory:

tar xvfz aes.tgz
tar xvfz lucid.tgz -C aes

Once again, use maverick.tgz for Ubuntu 10.10 Maverick Meerkat or natty.tgz for Ubuntu 11.04 Natty Narwhal.

4.4.5. Create the USB stick

Use the provided mkusb.sh script to create the USB stick. mkusb.sh should be run from the aes directory which was created by unpacking the AES installer archive.

Caution

Running the mkusb.sh script will reformat the given device (/dev/sdb1) in the example below.

cd aes
sudo ./mkusb.sh /var/tmp/aes-install/ubuntu-10.04.2-alternate-i386.iso /dev/sdb1
sudo eject /dev/sdb

This example creates a modified Ubuntu 10.04 installer which can be used to install an AES XvBA Reference System based on Ubuntu 10.04. To create an Ubuntu 10.10 installer, use the Ubuntu 10.10 installer ISO image. To create an Ubuntu 11.04 installer, use the Ubuntu 11.04 installer ISO image.

The example makes a few assumptions, specifically:

  • you’re using an Ubuntu host system where sudo is required to gain administrative privileges,

  • your USB stick appears as /dev/sdb, and

  • your USB stick is not mounted.

You may need to adjust these commands. If your system is configured to mount your USB stick automatically, you should unmount it before running mkusb.sh.

At startup, mkusb.sh checks that required commands are installed on the host system. If not, it prints an error message and exits. As a concrete example, it might report:

fakeroot is not installed

In this case, install fakeroot using your distribution’s package manager, then rerun mkusb.sh.

4.5. Preparing a bootable DVD — the flexible way

This is the sames as Preparing a bootable USB stick — the flexible way except that you use mkusb.sh to prepare an ISO image, then write that image to DVD. When given a file name ending in .iso instead of a device, mkusb.sh creates an ISO image. The example above:

sudo ./mkusb.sh /var/tmp/aes-install/ubuntu-10.04.2-alternate-i386.iso /dev/sdb1

might become:

sudo ./mkusb.sh /var/tmp/aes-install/ubuntu-10.04.2-alternate-i386.iso /var/tmp/lucid-i386.iso

Note that this requires quite a bit more temporary space so you may need to override TMPDIR, like this:

sudo env TMPDIR=/var/tmp ./mkusb.sh /var/tmp/aes-install/ubuntu-10.04.2-alternate-i386.iso /var/tmp/lucid-i386.iso

4.6. Install target system from bootable media

Boot the target system from the USB stick or DVD. Select a language from the language menu (only English has been tested). You will be presented with the following menu:

Boot Menu
                                   Install Ubuntu
                            Install Ubuntu Automatically
                               Check disc for defects
                                    Test memory
                             Boot from first hard disk
                                     mainmenu
                                      expert
                                      rescue

F1 Help  F2 Language  F3 Keymap  F4 Modes  F5 Accessibility  F6 Other Options

Select Install Ubuntu Automatically.

Caution

Selecting Install Ubuntu Automatically will reformat and repartition your hard disk. Any existing data will be lost irrecoverably.

After installation is complete, the system will reboot into the installed AES XvBA Reference System.

4.7. Post Installation

The installer creates a user with login name ubuntu and password password. This user is allowed to sudo.

Caution

Obviously, this is not secure. If you intend to connect this system to an insecure network, you should take steps to secure it.

In addition, it installs the XvBA SDK and XvBA Tools source so, if you’re interested in evaluating XvBA, you may want to build XvBA Tools, like this:

/usr/share/doc/xvbat-source/build.sh

The build script includes brief help:

/usr/share/doc/xvbat-source/build.sh --help

Running the script builds XvBA Tools in a subdirectory of your current working directory named after the XvBA Tools source archive, e.g. xvbat-0.9-404001 for the current release. You can run xvbainfo to confirm that XvBA Tools has been built properly:

cd xvbat-0.9-404001
./xvbainfo

For further information, consult the XvBA Tools documentation in its doc/html subdirectory.

6. FAQ

6.1. Why automated installation? Why not disk cloning?

Disk cloning tools like Symantec Ghost™
[Symantec Ghost is a trademark of Symantec Corporation in the United States and other countries.]
are most useful for duplicating gold images but do not (and cannot) address creation of gold images. While some customers might find fully functional system images useful, releasing images wouldn’t help our customers learn how to install and configure AMD software components. Furthermore, distribution of a system image containing fglrx pre-installed is a violation of its EULA.

6.2. What releases of Ubuntu are supported?

10.04, 10.10, and 11.04.

6.3. Do you support other Linux distributions?

No. The AES automated installer is based on the preseeding facility of the Ubuntu alternate installer. Both Red Hat Enterprise Linux®
[Red Hat and Red Hat Enterprise Linux are registered trademarks of Red Hat, Inc. in the U.S. and other countries.]
and SUSE Linux Enterprise Desktop®
[SUSE and SLED are registered trademarks of Novell, Inc., in the United States and other countries.]
have similar but different facilities.

6.4. Can I use a CD instead of a USB stick or DVD?

No. A CD is not large enough for everything (installer components and packages to be installed on the target system).

6.5. Can I use PXE to install over the network?

Yes but documenting it is beyond the scope of this document. Consult the Ubuntu Installation Guide for details.

6.6. What version of fglrx is installed by default?

The AES Automated Installer installs the latest version of the driver found in the AES package archive. Currently, that is Catalyst 11.8.

6.7. How do I choose which version of fglrx to install?

Add a line like:

d-i fglrx/version string =VERSION

to local.cfg and use mkusb.sh to rebuild the USB stick. Here’s a concrete example that selects Catalyst 11.2:

d-i fglrx/version string =2:8.821-0ubuntu1

The chosen driver must be present in the (unpacked) package archive. See also this FAQ.

To disable installation of fglrx, use:

d-i fglrx/version string -

That’s a single minus not an equals.

Note

This seemingly obscure syntax is the syntax supported by apt-get. Constult the apt-get documentation for details.

6.8. Can I disable installation of fglrx?

See the answer to the previous question.

6.9. What versions of fglrx are present in the package archive?

Each package archive (lucid.tgz, maverick.tgz, or natty.tgz) contains a package index. So you could run:

tar xfzO lucid.tgz dists/lucid/restricted/binary-i386/Packages |less

to extract the package index to standard output and view it with less. Note that there’s a separate index for each distribution and architecture. This example is for 32-bit (i386) 10.04 (lucid). For 64-bit (amd64) 10.10 (maverick), the command would be:

tar xfzO maverick.tgz dists/maverick/restricted/binary-amd64/Packages |less

You could also open the archive in the file manager and view the package index file.

6.10. Can I customize the installer?

Yes but it’s beyond the scope of this document. Consult the Ubuntu Installation Guide for details.

6.11. There’s only about 10GB of space in /home. Why?

Because formatting large partitions slows down the installation and 10GB is large enough for evaluation purposes.

6.12. I want more space. Can I change the partitioning scheme?

Yes. Modify the partitioning scheme in aes/partition/custom.seed. Consult the Ubuntu Installation Guide for details.

Alternatively, use GParted (or similar) to partition the free space or resize the partitions.

6.13. The boot partition /boot is mounted read-only. Why?

This is a common practice to avoid accidental damage to critical files needed to boot the system (Linux kernel, initial RAM disk, GRUB configuration, etc.). If you need to write to /boot, e.g. to update your kernel or GRUB configuration, you can remount it read-write, like this:

sudo mount -o remount,rw /boot

6.14. This seems complicated. Is there an easier way to evaluate XvBA?

It depends on your skill set. If you’re an experienced Linux developer or Linux System Administrator, you should have no trouble installing a Linux system that meets the requirements of XvBA. In that case, you may want to review or modify the build.sh script from the xvbat-source package contained in the package archives.

On the other hand, if you’re unfamiliar with Linux installation or are not comfortable working at the command line, following the procedure documented in this guide should help you to get up and running quickly. Using one of the easy methods to prepare bootable media should be straightforward.

7. Appendix A: Glossary

AES

AMD Embedded Solutions.

fglrx

Another name for the AMD Proprietary Linux Graphics Driver.

Preseeding

Preseeding provides a way to seed answers to questions asked during installation, without having to supply them manually.

XvBA

X-Video Bitstream Acceleration is AMD’s API for hardware accelerated video decoding using the UVD engine of ATI Radeon graphics hardware.