Installing ALARM to TonidoPlug NAND?

This forum is for Marvell Kirkwood devices such as the GoFlex Home/Net, PogoPlug v1/v2, SheevaPlug, and ZyXEL devices.

Installing ALARM to TonidoPlug NAND?

Postby BaxterStockman » Mon Jun 17, 2013 9:30 pm

Hey all - thanks in advance for any insight you can offer.

I am the proud new owner of a v1 TonidoPlug, and for various reasons I'd like to install ALARM to the plug's NAND, rather than using a USB drive as the root filesystem. I see from the SheevaPlug instructions that this is possible on the SheevaPlug, but the TonidoPlug instructions are limited to USB installation.

There's a script available on GitHub based on the TonidoPlug reflashing utility to install Plug Apps (ALARM's predecessor, I gather) onto NAND; might it be possible to adapt the script to flash the current ALARM build? The script looks like this:

$this->bbcode_second_pass_code('', '#!/bin/bash
#
# Arch Linux ARM Plug Flasher
#
# The following script will take a rootfs file and flash it
# on a TonidoPlug's NAND. Stick this on a Arch Linux ARM USB drive
# along with a rootfs.tar.gz (set it below), SSH in, and run this.
#
# It's based on the official TonidoPlug reflasher: http://www.tonido.com/support/TonidoPlug_Flash_LinuxOS
#
# Set this to where you put the rootfs on the USB drive! e.g. make a folder
# named "flash" on your drive and put the rootfs in there.
#
ROOTFS=/flash/PlugApps-Linux-2011.02-beta1-rootfs.tar.gz
#
echo "This script will completely erase your TonidoPlug's firmware"
echo "and will replace it with Plug Apps. You will then be able to"
echo "use Plug Apps from the internal storage instead of from USB."
echo ""
echo "This will take up to 15 minutes."
echo ""
echo "If this is not what you want, press CTRL-X now."
echo "Otherwise, press ENTER to start reflashing."
#
echo "Accessing internal storage..."
ubiattach /dev/ubi_ctrl -m 2
mount -t ubifs ubi0:rootfs /mnt/
echo "Wiping internal filesystem contents..."
rm -rf /mnt/*
echo "Flashing Arch Linux ARM..."
tar -C /mnt/ -xzf $ROOTFS >& /dev/null
echo "Flashing kernel..."
flash_eraseall -j /dev/mtd1
nandwrite -pm /dev/mtd1 /mnt/boot/uImage
echo "Unmounting..."
umount /mnt/
ubidetach /dev/ubi_ctrl -m 2
#
echo "All done, you now have Plug Apps on your TonidoPlug!"
echo "Remove all USB drives attached to the plug and reboot."')

Maybe all that's needed is to put the latest build in the /flash directory and change the ROOTFS value to /flash/ArchLinuxARM-armv5te-latest.tar.gz?

As an additional caveat, the current build of ALARM (for ARMv5te) seems to be around 477MB:

$this->bbcode_second_pass_code('', '$ du -c ALARM/ | grep total
477480 total')

That leaves precious little room for packages. I suppose I could try getting rid of uneeded modules and other superfluous stuff?

Anyway, just tossing ideas out. If you got better ones, or think I should deep-six my plans, please let me know. Thanks!

(Had to do some edits to the post, because apparently any instance of "Plug Apps" with no space between the two words gets changed automatically to "Arch Linux ARM" :) )
BaxterStockman
 
Posts: 6
Joined: Thu Jan 17, 2013 9:12 pm

Re: Installing ALARM to TonidoPlug NAND?

Postby Orionn » Tue Jun 25, 2013 8:36 am

Firstly, make sure it works on a USB drive. I think the latest build has problems with connections (see the other thread on not being able to SSH to Tonido).
Orionn
 
Posts: 2
Joined: Fri Jun 14, 2013 11:24 am


Return to Marvell Kirkwood

Who is online

Users browsing this forum: No registered users and 3 guests