建立工作目錄
mkdir arm_ubuntu-lucid cd arm_ubuntu-lucid
安裝必要套件及下載 rootstock
sudo apt-get install debootstrap fakeroot bzr bzr branch lp:project-rootstock
TIPs
bzr 這行指令會上網下載 rootstock 相關檔案,故須保持外網暢通。
rootstock 可以自動建立一個 rootfs 的 tarball 檔,詳見此連結。
下載 Lucid 的 vmlinuz 檔
wget http://ports.ubuntu.com/ubuntu-ports/dists/lucid/main/installer-armel/current/images/versatile/netboot/vmlinuz
建立系統映像檔 qemu_ubuntu-lucid_arm.img
sudo project-rootstock/rootstock --fqdn ubuntu --login ubuntu --password ubuntu --notarball --imagesize 3G mv qemu-armel-201203301652.img qemu_ubuntu-lucid_arm.img
TIPs
系統建立映像檔時需要一些時間,請耐心等候。
產生的檔名會以日期來命名。
啟動模擬系統
qemu-system-arm -M versatilepb -cpu cortex-a8 -kernel vmlinuz -hda qemu_ubuntu-lucid_arm.img -m 256 -append "root=/dev/sda rootwait"
如果看到以下的畫面,就表示成功。
接著按下 ALT+F1,會出現登入提示,以 ubuntu : ubuntu 登入。