Difference between revisions of "Amahi Plug Edition"

From Amahi Wiki
Jump to: navigation, search
 
(59 intermediate revisions by 9 users not shown)
Line 1: Line 1:
 +
{{MessageBox|backgroundcolor = #FBB|
 +
image =Warning.png|
 +
heading =WARNING|
 +
message = '''DEPRECATED'''<br>This is no longer supported.}}
 +
 +
 +
Amahi "Plug Edition" &mdash; How to run Amahi on your Plug Computer!
 +
 +
For discussions see the [https://forums.amahi.org/viewforum.php?f=40 Amahi Plug Computer Forum].
 +
 
= Supported devices =
 
= Supported devices =
  
* SheevaPlug
+
* [http://www.ionicsplug.com/products.html Ionics Plugs]
* GuruPlug
+
* [http://www.globalscaletechnologies.com/t-guruplugdetails.aspx GuruPlug]
* Pogoplug
+
* [http://en.wikipedia.org/wiki/SheevaPlug SheevaPlug]
* DockStar
+
* [http://www.globalscaletechnologies.com/t-openrdcdetails.aspx OpenRD Client]
* Any other Plug Computer based on the Marvell Plug Computer
+
* [http://www.globalscaletechnologies.com/t-openrdbdetails.aspx OpenRD Base] (unverified)
 +
 
 +
Supported but not recommended, due to compatibility or speed:
 +
 
 +
* [http://www.tonidoplug.com/ TonidoPlug]
 +
* [http://www.plugapps.com/index.php5?title=Getting_Started:_Pogoplug Rooted] [http://www.pogoplug.com/ Pogoplug] &mdash; (256 RAM)
 +
* [http://www.cs.cmu.edu/~ecc/dockstar-howto.html Rooted] [http://www.seagate.com/www/en-us/products/network_storage/freeagent_dockstar/ Seagate DockStar] &mdash; (128MB RAM - a little slow)
 +
* Any other device based on the [http://plugcomputer.org Marvell Plug Computer]
 +
 
 +
Known Issues:
 +
* [http://www.globalscaletechnologies.com/p-35-openrd-ultimate.aspx OpenRD Ultimate] will need some tweaking as the current kernel does not support OpenRD Ultimate yet.
 +
* eSata [http://en.wikipedia.org/wiki/SheevaPlug SheevaPlug] will need an updated kernel to support the eSata port ([http://bugs.amahi.org/issues/show/850 #850])
  
 
= Requirements =
 
= Requirements =
  
 
You'll need:
 
You'll need:
* A storage device, of 2GB or more, that your plug computer can boot from.
+
* A Linux Computer
* The latest Amahi ''rootfs'' from http://dl.amahi.org/marvell/ - look for the latest file named '''amahi-marvell-*.tar.bz2'''
+
* A storage device, of 2GB or more, that your plug computer can boot from
* The script to copy the above ''rootfs'' into your storage device: http://dl.amahi.org/marvell/create-clean-f12-disk.sh
+
* The latest Amahi "rootfs" from the [http://dl.amahi.org/marvell/ Amahi4Plug repo] look for the latest file named '''amahi-marvell-*.tar.bz2'''
 +
* [http://dl.amahi.org/marvell/create-amahi-f12-plug-disk.sh This script] to copy the above ''rootfs'' into your storage device. Important: you <u>will</u> have to modify this script to suit your device, as it obliterates the content of it
 +
 
 +
= Quick Overview =
 +
 
 +
Because of the headless nature of the Plug devices, there are some more steps than the typical Amahi release to make things work smoothly.
  
= Known issues =
+
There are three major steps in getting things going
  
For a list of working / not working apps for plug computers, see [[SP Apps|this page]].
+
; '''Step 1'''
 +
: Download the latest [http://dl.amahi.org/marvell/ rootfs image] then use the script to extract and put it into an empty USB hard drive, USB flash drive, or SD card (depending on what your device supports). While it does that, you may want to setup a profile for your HDA at [http://www.amahi.org/ Amahi]
  
= Quick Install =
+
; '''Step 2'''
 +
: Boot your device using the drive or card you created in step 1. Find out the IP it got assigned from your existing DHCP server (typically your router). Alternately if you have console access log in at the console prompt (user: admin, password: amahi) and run /sbin/ifconfig. The ip address is at the second line of the eth0 section (inet addr)
  
Step 1: Download and extract the [http://dl.amahi.org/marvell/ Amahi ''rootfs'' image] into an empty USB hard drive, USB flash drive, or SD card (depending on what your device supports), formatted as ext3.
+
; '''Step 3'''
 +
: Install Amahi, by loading <code>http://plug_ip:2000</code> and entering the install code you got when you [https://www.amahi.org/user created your Amahi profile].
  
Step 2: Boot your device using the drive or card you created in step 1.
+
= Known issues =
  
Step 3: Install Amahi, by loading http://plug_ip:2000 and entering the install code you got when you [https://www.amahi.org/user created your Amahi profile].
+
For a list of working / not working apps for plug computers, see [[Plug Apps| Plug Apps]] page. Also, please check and file any issues in the [http://bugs.amahi.org/projects/show/plug Amahi bug tracker project for the Plug port]
  
 
= Detailed Installation Instructions =
 
= Detailed Installation Instructions =
 +
 +
Fully detailed procedure.
  
 
== Step 1: Prepare your boot device ==
 
== Step 1: Prepare your boot device ==
  
Connect your boot device (USB hard drive, USB flash drive, or SD card) into a working Linux machine (you can use your plug computer!)<br/>
+
Connect your boot device (USB hard drive, USB flash drive, or SD card) into a working Linux machine (you can use your plug computer!)
If needed, partition your device to create a partition you'll use to boot. No need to format it.<br/>
+
 
 +
If needed, partition your device to create a partition you'll use to boot. No need to format it.
 +
 
 
If a swap partition is desired (highly recommended for the PogoPlug & DockStar), create a second partition on your storage device, between 512MB and 2GB (depending on how big your storage device is), and format it as ''Linux Swap''.
 
If a swap partition is desired (highly recommended for the PogoPlug & DockStar), create a second partition on your storage device, between 512MB and 2GB (depending on how big your storage device is), and format it as ''Linux Swap''.
  
Line 37: Line 70:
 
{| cellpadding="7"
 
{| cellpadding="7"
 
! 2GB Flash Drive<br/>or SD Card
 
! 2GB Flash Drive<br/>or SD Card
 +
! 4GB Flash Drive<br/>or SD Card
 
! 8GB Flash Drive<br/>or SD Card
 
! 8GB Flash Drive<br/>or SD Card
 
! 16GB Flash Drive<br/>or SD Card
 
! 16GB Flash Drive<br/>or SD Card
Line 42: Line 76:
 
|-
 
|-
 
|2GB, unformatted
 
|2GB, unformatted
 +
|4GB, unformatted
 
|512MB, Linux Swap<br/>7.5GB, unformatted
 
|512MB, Linux Swap<br/>7.5GB, unformatted
 
|1GB, Linux Swap<br/>15GB, unformatted
 
|1GB, Linux Swap<br/>15GB, unformatted
Line 49: Line 84:
  
 
Download the Amahi ''rootfs'' file and ''create-clean-f12-disk.sh'' script into your Linux machine. Don't store them on the storage device you want to use on your plug computer.<br/>
 
Download the Amahi ''rootfs'' file and ''create-clean-f12-disk.sh'' script into your Linux machine. Don't store them on the storage device you want to use on your plug computer.<br/>
Edit the ''create-clean-f12-disk.sh'' script:
+
Edit the ''create-amahi-f12-plug-disk.sh'' script:
 
* Change the first line, the one that says '''partition="..."''' to point to the partition you want to use to boot your plug computer.<br/>If you're not sure, '''ls -l /dev/disk/by-id/''' and see if you can find it there.
 
* Change the first line, the one that says '''partition="..."''' to point to the partition you want to use to boot your plug computer.<br/>If you're not sure, '''ls -l /dev/disk/by-id/''' and see if you can find it there.
* Change the second line, if needed. It should contain the name of the Amahi ''rootfs'' file you downloaded. Example: '''rootfs="amahi-marvell-0.8.tar.bz2"'''
+
* Change the second line '''swap="..."''' to point to the partition you want to use for swap.  If you do not have a swap partition just set this to a partition that does not exist.
 +
* Change the third line, if needed. It should contain the name of the Amahi ''rootfs'' file you downloaded. Example: '''rootfs="amahi-marvell-1.0.tar.bz2"'''
 
* Comment (add a # character at the beginning of) the two following lines, the ones that say '''echo "Please edit this script...''' and '''exit 0'''.
 
* Comment (add a # character at the beginning of) the two following lines, the ones that say '''echo "Please edit this script...''' and '''exit 0'''.
  
<font color="red" style="font-weight: bold">Big Warning! Putting the wrong partition in this script will completely erase that partition! Be careful what partition you target!</font>
+
<div style="border: 1px solid #B66; padding: .5em 1em; color: #000; background-color: #FEE; margin: 3px 3px 1em 3px;">
 +
'''BIG WARNING! Putting the wrong partitions in this script will completely erase those partitions! Be careful what partitions you target!
 +
</div>
 +
 
 +
Run the ''create-amahi-f12-plug-disk.sh'' script under root:
 +
 
 +
      sh create-amahi-f12-plug-disk.sh
  
Run the ''create-clean-f12-disk.sh'' script: '''bash create-clean-f12-disk.sh'''
 
 
 
== Step 2: Boot your plug ==
 
== Step 2: Boot your plug ==
  
Boot the plug computer with your newly created drive/card attached. Give it a few minutes to boot, and it will be ready for the Amahi installation.
+
Boot the plug computer with your newly created drive/card attached. Give it a few minutes to boot, and it will be ready for the Amahi installation.
  
 
If you need help getting your plug computer to boot from USB or SD, instead of the on-board Flash memory, see our [[Marvell Plug Computer Booting]] page.
 
If you need help getting your plug computer to boot from USB or SD, instead of the on-board Flash memory, see our [[Marvell Plug Computer Booting]] page.
Line 68: Line 108:
 
Note that for this step to work correctly, your plug computer needs to have access to Internet. Maybe you can just SSH into it, and ping www.amahi.org to make sure it works.
 
Note that for this step to work correctly, your plug computer needs to have access to Internet. Maybe you can just SSH into it, and ping www.amahi.org to make sure it works.
  
Find the plug computer IP address (check your DHCP server), and launch the Amahi installer by visiting http://plug_computer_ip:2000
+
Find the plug computer IP address (check your router DHCP logs or DHCP server), and launch the Amahi installer by visiting http://plug_computer_ip:2000
  
 
(Use nmap or ping -b to find new devices on your LAN, if you can't find your plug computer IP address on your DHCP server.)
 
(Use nmap or ping -b to find new devices on your LAN, if you can't find your plug computer IP address on your DHCP server.)
Line 76: Line 116:
 
== Enjoy ==
 
== Enjoy ==
  
Access your HDA by logging in at http://plug_computer_ip<br/>
+
After it reboots, access your HDA by logging in at <code>http://plug_computer_ip</code><br/>
Username: admin<br/>
+
 
Password: amahi
+
    Username: admin
 +
    Password: amahi
 +
 
 +
The root password is: amahi<br/>
 +
(Change it!)
 +
 
 +
== Post Install Action ==
 +
 
 +
If all seems to work, you can now disable your old DHCP server, and let your plug computer act as your new DHCP server.
 +
 
 +
You'll need to [[RenewIP|release and then renew the IP address]] of your client computers, once your old DHCP server is disabled.
  
If all seems to work, you can now disable your old DHCP server, and let your plug computer act as your new DHCP server.<br/>
 
You'll need to [[RenewIP|renew the IP address]] of your client computers, once your old DHCP server is disabled.<br/>
 
 
You'll then be able to access the Amahi dashboard at http://hda, and your installed apps using http://app_name
 
You'll then be able to access the Amahi dashboard at http://hda, and your installed apps using http://app_name
 +
 +
 +
If you created a swap partition while partitioning your storage device, you might need to tell Amahi to use that partition for swap space. You'll need to change '''/dev/sda2''' for the real path to your swap partition. SSH into your Amahi server, and execute the following:
 +
 +
    mkswap /dev/sda2
 +
    swapon -a
 +
 +
You will also need to edit the /etc/fstab file to use that new partition at startup
 +
 +
Check that everything is now working with
 +
 +
        free
 +
 +
The total on the swap line should not be 0 if all worked out. Otherwise make sure the fstab has the right device for swapping.
 +
 +
Note: On the SheevaPlug, the onboard NAND flash is called /dev/mtdblock2. You might want to use it as a swap partition, as it would be faster than your SD card or USB drive.
 +
 +
= Customize and Extend =
 +
 +
If you need customizations for your device, you can install the [http://fedoraproject.org/wiki/Architectures/ARM/CrossToolchain ARM cross compilation toolset] to compile things like the kernel, multimedia libraries, etc. etc.
 +
 +
= Tips and Tricks =
 +
Tips, tricks and howto's can be found at [[Plug Tips and Tricks]]
 +
 +
= Known Issues =
 +
* See the [http://bugs.amahi.org/projects/show/plug bug tracker] for reported bugs against the plug edition.
 +
* See [[Plug_warboard]] for documented issues.
 +
 +
 +
These are mostly what matter for debugging:
 +
/root/hda-install.log
 +
egrep -v 'POST<nowiki>|GET|</nowiki>progress' /tmp/amahi-ruby-install.log

Latest revision as of 03:31, 23 June 2020

Warning.png WARNING
DEPRECATED
This is no longer supported.



Amahi "Plug Edition" — How to run Amahi on your Plug Computer!

For discussions see the Amahi Plug Computer Forum.

Supported devices

Supported but not recommended, due to compatibility or speed:

Known Issues:

  • OpenRD Ultimate will need some tweaking as the current kernel does not support OpenRD Ultimate yet.
  • eSata SheevaPlug will need an updated kernel to support the eSata port (#850)

Requirements

You'll need:

  • A Linux Computer
  • A storage device, of 2GB or more, that your plug computer can boot from
  • The latest Amahi "rootfs" from the Amahi4Plug repo look for the latest file named amahi-marvell-*.tar.bz2
  • This script to copy the above rootfs into your storage device. Important: you will have to modify this script to suit your device, as it obliterates the content of it

Quick Overview

Because of the headless nature of the Plug devices, there are some more steps than the typical Amahi release to make things work smoothly.

There are three major steps in getting things going

Step 1
Download the latest rootfs image then use the script to extract and put it into an empty USB hard drive, USB flash drive, or SD card (depending on what your device supports). While it does that, you may want to setup a profile for your HDA at Amahi
Step 2
Boot your device using the drive or card you created in step 1. Find out the IP it got assigned from your existing DHCP server (typically your router). Alternately if you have console access log in at the console prompt (user: admin, password: amahi) and run /sbin/ifconfig. The ip address is at the second line of the eth0 section (inet addr)
Step 3
Install Amahi, by loading http://plug_ip:2000 and entering the install code you got when you created your Amahi profile.

Known issues

For a list of working / not working apps for plug computers, see Plug Apps page. Also, please check and file any issues in the Amahi bug tracker project for the Plug port

Detailed Installation Instructions

Fully detailed procedure.

Step 1: Prepare your boot device

Connect your boot device (USB hard drive, USB flash drive, or SD card) into a working Linux machine (you can use your plug computer!)

If needed, partition your device to create a partition you'll use to boot. No need to format it.

If a swap partition is desired (highly recommended for the PogoPlug & DockStar), create a second partition on your storage device, between 512MB and 2GB (depending on how big your storage device is), and format it as Linux Swap.

Example partitioning depending on your boot device type & size:

2GB Flash Drive
or SD Card
4GB Flash Drive
or SD Card
8GB Flash Drive
or SD Card
16GB Flash Drive
or SD Card
USB Hard Drive
(40+ GB)
2GB, unformatted 4GB, unformatted 512MB, Linux Swap
7.5GB, unformatted
1GB, Linux Swap
15GB, unformatted
2GB, Linux Swap
The rest, unformatted

Download the Amahi rootfs file and create-clean-f12-disk.sh script into your Linux machine. Don't store them on the storage device you want to use on your plug computer.
Edit the create-amahi-f12-plug-disk.sh script:

  • Change the first line, the one that says partition="..." to point to the partition you want to use to boot your plug computer.
    If you're not sure, ls -l /dev/disk/by-id/ and see if you can find it there.
  • Change the second line swap="..." to point to the partition you want to use for swap. If you do not have a swap partition just set this to a partition that does not exist.
  • Change the third line, if needed. It should contain the name of the Amahi rootfs file you downloaded. Example: rootfs="amahi-marvell-1.0.tar.bz2"
  • Comment (add a # character at the beginning of) the two following lines, the ones that say echo "Please edit this script... and exit 0.

BIG WARNING! Putting the wrong partitions in this script will completely erase those partitions! Be careful what partitions you target!

Run the create-amahi-f12-plug-disk.sh script under root:

     sh create-amahi-f12-plug-disk.sh

Step 2: Boot your plug

Boot the plug computer with your newly created drive/card attached. Give it a few minutes to boot, and it will be ready for the Amahi installation.

If you need help getting your plug computer to boot from USB or SD, instead of the on-board Flash memory, see our Marvell Plug Computer Booting page.

Step 3: Install Amahi

Note that for this step to work correctly, your plug computer needs to have access to Internet. Maybe you can just SSH into it, and ping www.amahi.org to make sure it works.

Find the plug computer IP address (check your router DHCP logs or DHCP server), and launch the Amahi installer by visiting http://plug_computer_ip:2000

(Use nmap or ping -b to find new devices on your LAN, if you can't find your plug computer IP address on your DHCP server.)

It will ask for an install code. That code can be obtained by creating an Amahi profile here: https://www.amahi.org/user (you'll need to create an account first, if you don't already have one).

Enjoy

After it reboots, access your HDA by logging in at http://plug_computer_ip

   Username: admin
   Password: amahi

The root password is: amahi
(Change it!)

Post Install Action

If all seems to work, you can now disable your old DHCP server, and let your plug computer act as your new DHCP server.

You'll need to release and then renew the IP address of your client computers, once your old DHCP server is disabled.

You'll then be able to access the Amahi dashboard at http://hda, and your installed apps using http://app_name


If you created a swap partition while partitioning your storage device, you might need to tell Amahi to use that partition for swap space. You'll need to change /dev/sda2 for the real path to your swap partition. SSH into your Amahi server, and execute the following:

    mkswap /dev/sda2
    swapon -a

You will also need to edit the /etc/fstab file to use that new partition at startup

Check that everything is now working with

        free

The total on the swap line should not be 0 if all worked out. Otherwise make sure the fstab has the right device for swapping.

Note: On the SheevaPlug, the onboard NAND flash is called /dev/mtdblock2. You might want to use it as a swap partition, as it would be faster than your SD card or USB drive.

Customize and Extend

If you need customizations for your device, you can install the ARM cross compilation toolset to compile things like the kernel, multimedia libraries, etc. etc.

Tips and Tricks

Tips, tricks and howto's can be found at Plug Tips and Tricks

Known Issues


These are mostly what matter for debugging:

/root/hda-install.log
egrep -v 'POST|GET|progress' /tmp/amahi-ruby-install.log