So, here's my setup. I have one partition with the newest version installed, a second partition with an older version installed (as a backup just in case), a swap partition that both share, and a boot partition so the bootloader doesn't need to be setup after each upgrade.
- sda1 ext3 /boot
- sda2 ext4 / (current version)
- sda3 ext4 / (old version)
- sda4 swap /swap
- sda5 ntfs (contains folders symbolically linked to /home on /)
So far it has been a very good setup. I can modify the boot loaders for new installs without messing with the MBR. Adding my personal files (from the /home partition) is as easy as creating some symlinks in my home folder (even on a Windows install).
Here's the issue. I'd like to be able to deploy an installation in the 'current version' partition to overwrite the 'old version' partition effectively making it the new 'current version'.
The goal here is to do the install with no USB drives, external hard drives, or CD copies.
Here are the steps to deploy an install from within Ubuntu using debootstrap
Step One: Format sda3 (the partition with the old copy of linux that's being overwritten)
I used gparted to format it as ext4 from within the current linux install. How this is done varies based on what tools you prefer to use.
Step Two: Mount the newly formatted partition (we'll call the mount ubuntu for simplicity)
sudo mkdir /mnt/ubuntu sudo mount -o -loop /dev/sda3 /mnt/ubuntu
Step Three: Get debootstrap
sudo apt-get install debootstrap
Step Four: Mount the install disk (replace ubuntu.iso with the name if your install disk)
sudo mkdir /media/cdrom sudo mount -o loop ~/ubuntu.iso /media/cdrom
Step Five: Install the OS using debootstrap (replace fiesty with the version you're installing and amd64 with your processor's architecture)
sudo debootstrap --arch amd64 fiesty /mnt/ubuntu file:/media/cdrom
The settings here varies. While I loaded debootstrap using an install iso, you can also have debootstrap automatically download and install if with a repository link (While most of these repositories contain debian versions I'm still not clear as to whether Ubuntu has similar repositories). Here a list of the debian package repositories and their mirrors.
This is how you'd deploy debootstrap if you were doing it directly from a repository:
sudo debootstrap --arch amd64 squeeze /mnt/debian http://ftp.us.debian.org/debian
Here's the link that I primarily used to figure out the steps needed.
Update 2: I've removed the info about my initial failed attempt and added the steps to accomplish this so this question may be useful for others who attempt this in the future.