Create the Ubuntu Breezy build chroot

Create the Breezy chroot

Use debootstrap to install the base system into the chroot directory.
mkdir /chroot
sudo debootstrap --arch i386 breezy /var/chroot/ http://archive.ubuntu.com/ubuntu/
Edit basic system files
sudo cp /etc/resolv.conf /chroot/etc/resolv.conf
sudo cp /etc/apt/sources.list /chroot/etc/apt/
Setup the chroot
sudo chroot /chroot/
apt-get update
apt-get install wget debconf devscripts gnupg
apt-get update
dpkg-reconfigure locales
tzconfig
exit
sudo cp /etc/ passwd /chroot/etc/
sudo sed 's/\([^:]*\):[^:]*:/\1:*:/' /etc/shadow | sudo tee /chroot/etc/shadow
sudo cp /etc/group /chroot/etc/
sudo cp /etc/hosts /chroot/etc/
sudo cp /etc/sudoers /chroot/etc/
sudo chroot /chroot/
dpkg-reconfigure passwd
passwd <your first ubuntu user in the admin group>
apt-get install sudo
exit
sudo editor /etc/fstab

/home          /chroot/home        none    bind            0      0
/tmp            /chroot/tmp        none    bind            0      0
/dev            /chroot/dev        none    bind            0      0
proc-chroot    /chroot/proc        proc    defaults        0      0
devpts-chroot  /chroot/dev/pts    devpts  defaults        0      0

sudo mount -a
sudo chroot /chroot/
mike – Thu, 2006 – 01 – 19 16:40