This is an old revision of the document!


Setting up an Ubuntu Installation to work with AOE

First make sure you have a server with some aoe server software installed. If you use Linux as a server, get and install the “vblade” package.

On the client side, install a standard Ubuntu Desktop on a physical or virtual machine. If you use a virtual machine, make the sure disk image is in 'raw' format, meaning no headers or such on the image. If it is a valid raw image, you should be able to see the partition table with, for example “fdisk -l disk.img” or even the “disktype” command, like so:

$ disktype disk.img 

--- disk.img
Regular file, size 6 GiB (6442450944 bytes)
DOS/MBR partition map
Partition 1: 5.858 GiB (6290407424 bytes, 12285952 sectors from 2048, bootable)
  Type 0x83 (Linux)
  Ext3 file system
    UUID 745D45C4-38FA-4B7C-85A3-71D37AE23AF3 (DCE, v4)
    Volume size 5.858 GiB (6290407424 bytes, 1535744 blocks of 4 KiB)
Partition 2: 144 MiB (150994944 bytes, 294912 sectors from 12288000)
  Type 0x82 (Linux swap / Solaris)
  Linux swap, version 2, subversion 1, 4 KiB pages, little-endian
    Swap size 144.0 MiB (150986752 bytes, 36862 pages of 4 KiB)

Use the following steps to make the Ubuntu client aoe capable:

First, start the client and login, then start a terminal and become root: Applications → Accessories → Terminal

Paste the following code into a new file called /etc/initramfs-tools/scripts/local-top/aoe
#!/bin/sh

sleep 1                       # Wait for network driver to load
ip link set eth0 up           # Activate the network interface
sleep 3                       # Wait for the network interface to become active
echo 1 >/dev/etherd/discover  # Start looking for aoe devices on the net

Then do these commands at the terminal:

sudo -s                                               # Become root, if it asks for password, use the users password
chmod +x /etc/initramfs-tools/scripts/local-top/aoe   # Make your script executable
apt-get install aoetools                              # Make sure you have the aoe tools installed
echo aoe >>/etc/initramfs-tools/modules               # Add the aoe module to the modules list of initramfs
update-initramfs -u                                   # Update initramfs with your changes, 
                                                      # the changes will also take effect even with upgrades
Optional: Do the following if you want your eth0 interface to have the same name even if the image is booted on different machines
sudo -s                                                   # Change to root access
rm /etc/udev/rules.d/70-persistent-net.rules              # Get rid of this rule so that your current eth0 interface doesn't get changed
rm /lib/udev/rules.d/75-persistent-net-generator.rules    # This re-creates the above, so get rid of it too

Note: I don't know if the above steps are the best way to make eth0 name static, but this is what works for me.

Random Notes

If you don't install any proprietary video drivers, then what you got here is an image that will boot from either AOE, USB, or any internal/external disk on any machine.

Created by — Quinn Plattel 2010/09/17 07:33


QR Code
QR Code sanboot:ubuntu_aoe (generated for current page)