Mer/Documentation/Installation

This article sums up the different ways to install Mer on different types of computers (VMWare, chroot, on device, etc.). Please feel free to add/edit. The original information is taken from Mer/Releases/0.9.

Replace "<your version>" with the version you are going to install, e.g. "0.9".

Contents

Installation in VirtualBox

  1. Unzip zip file
  2. Open VirtualBox, create new machine (click New):
    • Name: Mer <your version>
    • OS type: Linux
    • Version: Ubuntu
    • RAM: 128MB (at least)
    • Disk: click "existing", find the mer-x86-generic-image-v<your version>.vmdk file, select, select
    • Next
  3. Finish
  4. Start the newly created virtual machine
  5. Installing all the needed packages for installing VirtualBox additions:
    • I had to install the following packages by:
    • sudo apt-get install build-essential linux-headers-*kernel-version*-generic
    • (replace *kernel-version* with the currently installed kernel-version on the virtual machine)
    • (you can simply find out which kernel-version you have, by executing "uname -r" in Mer's XTerminal)
  6. Installing the additions:
    • First of all you have to mount the CD-Image with the additions emulated as a cdrom-device into the virtual machine running mer.
    • Mount the VboxAdditions.iso by: Devices -> mount CD-ROM image -> select VboxGuestAdditions.iso
    • Create a new folder with root rights by:
    • sudo mkdir /media/cdrom
    • and mount the virtual device's filesystem to the new mountpoint by:
    • sudo mount /dev/scd0 /media/cdrom
    • If no errors are appearing you can install the additions by:
    • sudo /media/cdrom/VBoxLinuxAdditions-x86.run
  7. Rebooting the virtual machine:
    • Now, when the installation of the additions has finished, you can reboot the vm simply by:
    • sudo init 6
  8. Finished

Installation (chroot)

mkdir mer-<your version>
cd mer-<your version> && sudo tar xzf mer-x86-generic-image-v<your version>.tar.gz
sudo mkdir -p tmp/.X11-unix home/$USER/.osso
sudo mv usr/bin/maemo-invoker usr/bin/maemo-invoker.real
echo -e '#!/bin/sh\nPROG="$1"\nshift\nexec "$PROG" "$@"' | sudo tee usr/bin/maemo-invoker
sudo chmod 755 usr/bin/maemo-invoker
echo 'nameserver <mynameresolver>' | sudo tee -a etc/resolv.conf

Start-up (from within mer-<your version> directory)

Xephyr :2 -host-cursor -screen 800x480x16 -dpi 96 -ac -extension Composite 2>/dev/null 1>&2 &
sudo mount --bind /tmp/.X11-unix tmp/.X11-unix
sudo mount --bind /dev/pts dev/pts
sudo mount -t proc proc proc
sudo mount -t sysfs sysfs sys
sudo chroot .
export DISPLAY=:2.0
/etc/init.d/dbus start
start-hildon

x86 Install

See Making x86 Mer Bootable

N8x0 Install

The Installer

The developers of Mer implemented an installer, which leads through all the steps of installation. In order to use the installer you need to open: .install file with your device, which will prompt you to install the file (about 2.5MB) and add the Extras, Extras-devel and tspre.org repositories if they were not added already.

After the download and the installation go to Settings -> Application Manager -> Utilities -> Browse Installable Applications -> Other and system and you will find a program "Install Bootmenu" and "Merinstaller". If you did not install those by pressing "OK" before, do it now.

The Simple Install will create a bootmenu entry for you. However, for more advanced installations - eg if you already have multiple booting OSes - you might want to read about its configuration - you may need to make a .item if you have a clone-to-SD copy of Maemo or Deblet. You can also find out how to change the default boot menu item and other bootmenu tricks.

Assuming you created all the .item files you wanted, go ahead, and start the bootmenu installer from Utilities -> Install Bootmenu. Its advised to close all other applications and network connections, but the installer will tell you all relevant information.

  • "Are you sure to continue?" - yes
  • "Create backup of current initfs" - yes/no
  • "Remove unneeded extra (and factory testing) stuff?" - yes
  • "install telnet server for network recovery?" - yes/no
  • "install dropbear ssh server for advanced network recovery?" - yes/no
  • "/etc/bootmenu.conf found, do you want to add it to initfs?" - yes
  • "Ready for flashing this image?" - yes/no

After a successfull flash, the device will reboot and you should see the bootmenu, where you can select the partition you want to boot. Choose the operating system where you just installed the installer for Mer and boot it.

Now start the Merinstaller via Utilities -> Install Mer. Follow the instructions. When prompted for the URL= you can point it to any rootfs image you want. Check at Mer/Releases or ask at #mer.

Once the installer puts the extracted rootfs to your device you can reboot and chose the partition where you put Mer. Please contribute by filing bugs on bugs.maemo.org

Flashable Image

NOTE: Very experimental, because it doesn't use the Maemo initfs; only install if you want to help test it.

Grab a kernel and rootfs image of Mer and flash them directly to the device by:

  ./flasher-3.0-static -k mer-armel-n8x0-kernel-v<your version>.zImage -r mer-armel-n8x0-image-v<your version>.jffs2 -f -R

You might want a MMC card swap partition.

770 Install

(these instructions need testing)

You will need at least a 1gb MMC, and these instructions are based on OS2008HE kernel. 48mhz kernel is highly recommended

Partition MMC to:

  • p1: Large ext3 partition first
  • p2: 256 MB swap partition second

Grab http://packages.tspre.org/pool/user/b/bootmenu/bootmenu_1.5-2_armel.deb and install it.

  • Open the main menu and tap Utilities -> Install Bootmenu to start the bootmenu install process.
    • If nothing happens, install xterm
    • If window appears and then goes away, gainroot is not installed
      • Alternative method with dropbear client / server installed, start xterm, run dbclient root@0, password 'rootme', run /usr/sbin/install_bootmenu
  • First, say yes to removing "unneeded extra (and factory testing) stuff"
  • say yes to including bootmenu.conf (important). Reboot when done flashing.
  • This is a special boot menu where boot menu items are made in /etc/bootmenu.d/*.item and refresh_bootmenu.d will flash this to initfs. If you are cloning or booting other OS'es, you'll need to make such .item files. See Mer/Documentation/Bootmenu

Grab e2fsprogs and install it - grab gnutar as well

  • From x-terminal, root: insmod /mnt/initfs/lib/modules/current/mbcache.ko
  • insmod /mnt/initfs/lib/modules/current/jbd.ko
  • insmod /mnt/initfs/lib/modules/current/ext3.ko
  • mkfs.ext3 /dev/mmcblk0p1
  • mkswap /dev/mmcblk0p2
  • swapon /dev/mmcblk0p2
  • mkdir -p /mnt/mer
  • mkdir -p /etc/bootmenu.d
  • mount -t ext3 /dev/mmcblk0p1 /mnt/mer
  • cd /mnt/mer; wget http://stskeeps.subnetmask.net/mer/<your version>/mer-armel-770-image-v<your version>.tar.gz
  • tar pzxvf mer-armel-770-image-v<your version>.tar.gz
  • rm mer-armel-770-image-v<your version>.tar.gz
  • umount /mnt/mer
  • Make /etc/bootmenu.d/mer.item with the following contents:
ITEM_NAME="Mer"
ITEM_ID="mer"
ITEM_DEVICE="mmcblk0p1"
ITEM_MODULES="mbcache jbd ext3"
ITEM_FSTYPE="ext3"
ITEM_FSOPTIONS="noatime,ro"
ITEM_LINUXRC="linuxrc"
  • refresh_bootmenu.d (say yes to reflashing, no to backup of initfs. reboot)
  • Hold down Menu key when prompted while booting and select Mer in the boot menu.

BeagleBoard port

  • Make sure you are running a RECENT uBoot, and you have USB input devices like keyboard or mouse, if you don't own a touchscreen..
  • Make a SD card, partitioned with 50mb FAT as first partition, extract boot fs on this, and the rest Linux partition, format this as ext3, and extract rootfs on this.
  • In uBoot, use the following commands (you may have to adjust video= parameter to match your display screen:

Note: The format of the video bootargs parameter has changed for the new 2.6.28 kernel in 0.9. You'll likely have to update the bootargs line.

setenv bootcmd 'mmcinit; fatload mmc 0:1 0x80300000 uImage; bootm 0x80300000'
setenv bootargs 'console=ttyS2,115200n8 console=tty0 root=/dev/mmcblk0p2 rw rootfstype=ext3 rootwait omapfb.video_mode=1024x768MR16@60'
saveenv
boot
  • The tablet should output kernel output on serial and on video, and on HDMI out it will eventually start X and show the First Boot Wizard. Good luck.

Pocket Loox 720 port (experimental)

  • Set up a SD card with a logical partition, and inside this logical partition, make a 50mb or so FAT partition (p5), and put the zImage file on this filesystem, name it zImage. After the logical partition, make a ext3 partition (p2), and untar rootfs on it.
  • Grab HaRET and put it on the FAT partition, HaRET.exe.
  • Make a file, startup.txt, with the following contents:
set kernel "zImage"
set mtype "617"
set RAMADDR "0xa8000000"
set cmdline "mem=128M rootdelay=1 root=b302 rw console=tty0"
boot
  • Unmount all filesystems, insert SD card into Pocket Loox, boot by running HaReT.exe. If HaRET stops with "Jumping to kernel..." then grab HaRET from www.postnuklear.de/linuxloox.
  • Experimental release, if you want to play with this - come hang out on #mer on irc.freenode.net and we'll try to guide you along. It is a 640x480 screen so our theme won't fit.
  • For using ssh between loox and desktop box :

- You need to grab an ssh enabled rootfs.

- extract it on your sd card (ext3 partition)

- connect the Loox with the sync cable to your desktop box. And power on loox.

- on your desktop box check for USB network interface (usualy usb0) with : ifconfig

- configure the USB network interface : sudo ifconfig usb0 192.168.2.1

- ssh to loox : ssh root@192.168.2.2

- root password is 'rootme'

  • If touchscreen is not calibrated MER v0.11:

- download tslib-bin to your desktop box.

- scp the deb file to loox : scp libts-bin_1.0-4ubuntu2_armel.deb root@192.168.2.2:/root

- on loox : dpkg -i libts-bin*.deb

- run ts_calibrate (all in one line) :

TSLIB_CONFFILE=/etc/ts.conf TSLIB_TSDEVICE=/dev/input/event0 TSLIB_FBDEVICE=/dev/fb0 TSLIB_CONSOLEDEVICE=none TSLIB_CALIBFILE=/etc/pointercal ts_calibrate

- you can test your touchscreen with ts_test

  • If touchscreen is not working under Xorg MER v0.11 :

remove xorg synaptics driver

apt-get remove xserver-xorg-input-synaptics
  • Internet on Loox

- Configure MASQUERADE on you desktop

iptables -A FORWARD -s 192.168.2.0/24 -j ACCEPT
iptables -A FORWARD -d 192.168.2.0/24 -j ACCEPT
iptables -t nat -A POSTROUTING -o eth0 -s 192.168.2.0/24 -j MASQUERADE
echo 1 >/proc/sys/net/ipv4/ip_forward

SmartQ

Dual booting doesn't seem to work at the moment.

You'll need an SD card with a FAT32 as the first partition and more than 140MB free.

Download the correct 'firmware image' from the Released Images table and copy it to the root of the FAT32 partition on the SD card.

Rename it SmartQ5 or SmartQ7 according to your device.

You may also want to :

  • Download the SmartQ5 or SmartQ7 WPA2-fixed driver to your SD card.
  • Browse here to agree the download license and get a zip file
  • Extract the downloaded zip file, then extract SD-8686-FEDORA26FC6-SYSKT-GPL-9.70.3.p24-26409.P45.tar within it. Extract the FwImage folder to your PC.
  • Inside there are two files, helper_sd.bin and sd8686.bin. Rename helper_sd.bin to sd8686_helper.bin and copy to your SD card
cd /tmp
unzip SD-8686-LINUX26-SYSKT-9.70.3.p24-26409.P45-GPL.zip
tar xf SD-8686-FEDORA26FC6-SYSKT-GPL-9.70.3.p24-26409.P45.tar
cp FwImage/helper_sd.bin /path_to_SD_CARD/sd8686_helper.bin
cp FwImage/sd8686.bin /path_to_SD_CARD/sd8686.bin

Now unmount the SD card and eject it.

Power off the SmartQ totally (wait for the LED to go out) and insert the SD card.

SmartQ5

Press and hold the + key and insert the charger. The device will begin to boot; the LED will be green/yellow.

SmartQ7

Press and hold the 'menu' key (bottom key on front) and insert the charger. The device will begin to boot; the LED will be a different colour - green/yellow. You can release the menu key. Some chinese symbols appear and then a progress bar ticks (slowly) up to 100%.

both

After this a calibration screen appears and shortly after you are in Mer.

It will be accessible over USB networking on IP 192.168.2.15 (see instructions here) with a SSH server, login root, password rootme

It will not show a splash screen, but it will after darkness then make the screen white, and eventually, show the Mer background and first boot wizard.

To get WPA2 wireless networking to work

Install the .deb you copied to your SD card and then (from https://wiki.ubuntu.com/Marvell8686Firmware), install the Marvell firmware.

So, in Mer on SmartQ, open X-Terminal and type (nb tab-completion is your friend):

$  sudo mount -t vfat /dev/mmcblk1p1 /media
(password is the one you used when installing)
$ sudo cp /media/sd8686.bin /lib/firmware/
$ sudo cp /media/sd8686_helper.bin /lib/firmware/

And then either, for the SmartQ5

$ sudo dpkg -i kernel-smartq5-modules_2.6.24.7-smartq5-*_all.deb

or for the SmartQ7

$ sudo dpkg -i kernel-smartq7-modules_2.6.24.7-smartq7-*_all.deb
$ sudo umount /media

5. Reboot.