Ubuntu 14.04 LTS on Radxa Rock

currently only very first part is written... ;)

install

first of all, install miniroot.

prepare miniroot

network (DHCP)

miniroot# udhcpc

network (static)

miniroot# ip addr add 192.168.1.2/24 broadcast + dev eth0
miniroot# ip link set dev eth0 up
miniroot# ip route add default via 192.168.1.1
miniroot# echo nameserver 192.168.1.1 > /etc/resolv.conf

replace 192.168.1.* with correct addresses for your network.

storage

you can use any supported storage, partition, and (sub)directory.

e.g. make ext4 file system on first partition of external SD card, then mount it on /mnt

miniroot# mkfs.ext4 -E nodiscard /dev/mmcblk0p1
miniroot# mount /dev/mmcblk0p1 /mnt

ubuntu-core

ubuntu-core is minimal root file system. you can setup desktop or server environment after install.

download

miniroot# wget -P /mnt http://cdimage.ubuntu.com/ubuntu-core/releases/trusty/release/ubuntu-core-14.04.3-core-armhf.tar.gz

install

extract tarball (e.g. under "ubuntu" directory on external SD card)

miniroot# mkdir /mnt/ubuntu
miniroot# tar -xpzf /mnt/ubuntu-core-14.04.3-core-armhf.tar.gz -C /mnt/ubuntu

setup sources.list

miniroot# wget -P /mnt/ubuntu/etc/apt http://files.androtab.info/radxa/ubuntu/sources.list

setup hostname (e.g. "ubuntu")

miniroot# echo ubuntu > /mnt/ubuntu/etc/hostname
miniroot# sed -e 's/miniroot/ubuntu/' < /etc/hosts > /mnt/ubuntu/etc/hosts

setup serial console (automatically log-in as "root")

miniroot# sed -e 's/tty1/ttyFIQ0/g' -e '/^exec/c exec /sbin/getty -a root -L 115200 ttyFIQ0 vt100' < /mnt/ubuntu/etc/init/tty1.conf > /mnt/ubuntu/etc/init/ttyFIQ0.conf

if you cannot use serial console, you must setup user account here. (e.g. user "ubuntu" password "ubuntu")

miniroot# chroot /mnt/ubuntu useradd -G sudo -m -s /bin/bash ubuntu
miniroot# echo ubuntu:ubuntu | chroot /mnt/ubuntu chpasswd

boot

miniroot# boot /mnt:/ubuntu

you can specify path of root device in 1st argument if it's not mounted. (e.g. "boot /dev/mmcblk0p1:/ubuntu")

initial setup

setup network (e.g. DHCP)

root@ubuntu:~# echo auto eth0 > /etc/network/interfaces.d/eth0
root@ubuntu:~# echo iface eth0 inet dhcp >> /etc/network/interfaces.d/eth0
root@ubuntu:~# ln -fs ../run/resolvconf/resolv.conf /etc/resolv.conf
root@ubuntu:~# ifup eth0

update packages

root@ubuntu:~# apt-get update
root@ubuntu:~# apt-get dist-upgrade

reboot

root@ubuntu:~# reboot

autoboot

change miniroot configuration

miniroot# editenv
boot=/dev/mmcblk0p1:/ubuntu
init=/sbin/init
autoboot=1
miniroot# saveenv
miniroot# reboot -f

prepare desktop environment

root@ubuntu:~# apt-get install lubuntu-desktop

(TBD)