Linux - Asus/HP ChromeBox EZ Setup (OpenELEC or Ubuntu+XMBC) [v2.16 - 2014/07/29]

  Thread Rating:
  • 11 Votes - 4.64 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
Matt Devo Offline
Fan
Posts: 680
Joined: Nov 2008
Reputation: 41
Post: #1
In order to simplify the setup/installation of XBMC on the Asus/HP Chromebox, and to resolve many of the setup issues encountered, I've developed a new script which will handle just about everything.

Before using this script, you must perform the steps in the device prep section of the wiki (put the ChromeBox in developer mode, and disable the firmware write protect). If you are planning on installing a dual-boot setup, you must perform a factory reset using Google'e recovery image prior to running the script for a dual-boot install.

To run the script (which must be executed from either ChromeOS or ChromiumOS), perform the following steps:
  • Power on and boot to ChromeOS. DO NOT LOG IN TO ChromeOS, but do ensure a network connection is set up
  • Hit CTRL-ALT-F2 to get to command prompt
  • Login with user chronos (no password required for ChromeOS; ChromiumOS uses 'password')
  • Download and run the setup script with the commands:
    curl -L -O http://goo.gl/3Tfu5W
    sudo bash 3Tfu5W

You will be presented with a menu with the following options:

[Image: cbox-menu.png]


Each option is explained below:



-----------------------------------------------------------------
Setup: ChromeOS + OpenELEC (dual boot)
-----------------------------------------------------------------


This option will install OpenELEC in a dual boot setup with ChromeOS.

IMPORTANT: Installing a dual boot setup occurs in two stages, and requires this script to be downloaded and run twice.

In the first stage, the script will prompt you for the partition size to use for OpenELEC, then re-partition the internal HDD to make room. After a reboot, ChromeOS will "repair" the newly created partitions and reboot itself. Once it completes the repair, you will need to re-download and re-run the script to complete the second phase, during which OpenELEC will be installed to the newly created partition(s).

After completion of the 2nd stage, use the 'Set Boot Options' menu option to set your preferred boot delay and default boot option.

Note: if you already have Ubuntu installed in a dual boot setup, you will need to perform a factory reset before installing OpenELEC in a dual boot configuration.

----------------------------------------------------------
Setup: ChromeOS + Ubuntu (dual boot)
----------------------------------------------------------


This option will install Ubuntu (14.04) in a dual boot setup with ChromeOS, plus update the Linux kernel to 3.14.1 and install the latest stable version of XBMC (13.1 / Gotham).

IMPORTANT: Installing a dual boot setup occurs in two stages, and requires this script to be downloaded and run twice.

In the first stage, the script will prompt you for the partition size to use for Ubuntu, then re-partition the internal HDD to make room. After a reboot, ChromeOS will "repair" the newly created partitions and reboot itself. Once it completes the repair, you will need to re-download and re-run the script to complete the second phase, during which you can select which metapackage of Ubuntu to use, and it will be installed to the newly created partition.

After completion of the 2nd stage, use the 'Set Boot Options' menu option to set your preferred boot delay and default boot option.

Note: if you already have a different version of Ubuntu installed in a dual boot setup, you can select this option and it will erase the existing version and install 14.04 + kernel update + MCE remote fix + XBMC 13.1, using the existing partition size/setup. If you are dual booting OpenELEC you will need to perform a factory reset before installing Ubuntu.

-----------------------------------------
Set Boot Options (dual boot)
------------------------------------------


[Image: cbox-menu-boot-options.png]

This option will allow you to set the boot delay (30s or 1s) and the default boot option (ChromeOS or OpeneELEC/Ubuntu).

Regardless of the option selected, on the developer boot screen (white screen w/"OS Verification Off" text) you can always press [CTRL-D] to boot into ChromeOS or [CTRL-L] to boot OpenELEC/Ubuntu.

Note: this requires the firmware write-protect to be disabled.

-----------------------------------------
Update Legacy BIOS (dual boot)
------------------------------------------


This option updates the Legacy BIOS component of the stock firmware to the latest fixed version. This step is automatically performed as part of any dual-boot setup, and is only necessary to perform manually if an update is released with a bug fix or new feature of interest to you.

---------------------------------------------------------------------------
Standalone Setup / coreboot Firmware Install / Update
------------------------------------------------------------------------------


[Image: cbox-menu-coreboot.png]

This option will allow you to replace the stock firmware with a custom build of coreboot. This custom firmware fixes many issues with the stock firmware and significantly reduces the boot time, but is not ChromeOS compatible. (You can, however, run the open-source variant ChromiumOS. Downloads are available at http://chromium.arnoldthebat.co.uk/)

You will be given the option to backup the current/stock firmware to an external USB drive; it is highly recommended that you do this in the event you wish to revert the ChromeBox to stock / run ChromeOS (the recovery button won't help you anymore), and since there is always a small risk anytime you flash/update the firmware.

After completing this step, you can install any off-the-shelf linux distro (Ubuntu, OpenELEC, etc) via USB, no custom installers are needed.

Upon reboot, if any USB/SD devices are connected, you will have 5s to press [ESC] to display the boot menu; otherwise it will boot the internal hard drive directly.

Note: this requires the firmware write-protect to be disabled.

-----------------------------------------------------------------------
Create OpenELEC USB/SD Installer (standalone)
-----------------------------------------------------------------------


This option will create a bootable USB/SD OpenELEC installer, which can then be used to install OpenELEC in standalone mode. The only difference from the latest OpenELEC Generic x86_64 version is that resume from suspend is enabled for USB3 ports, which allows IR remotes to power on the ChromeBox when in standby.

After completion, reboot and press [ESC] at the boot menu prompt, and select the USB device for installation.

In the OpenELEC installer, choose the 'Quick Install' option, select [YES]/[OK] as needed, and leave all defaults enabled (ssh, samba). When installation is complete, remove the USB stick, choose the reboot option, and OpenELEC will be booted by default in ~6 seconds.

Note: this requires you to have completed the Standalone Setup, which will update the ChromeBox's firmware to my custom coreboot build.

----------------------------------------------------------

-----------------------------
Other Configurations
-----------------------------


If you want to dual boot a different Linux distro, simply run the Device Prep followed by the first stage of the Ubuntu dual boot setup. Reboot, and allow ChromeOS to "repair" itself and perform the partition resizing. Then, reboot in legacy mode [CTRL-L] and choose to boot from your distro's USB installer ([ESC] then option 2). Install Linux to partition /dev/sda7, and the grub bootloader to /dev/sda. Afterwards, you can re-run the script to set your boot options.

If you want to install a different Linux distro in standalone mode, run the Standalone Setup / coreboot Firmware Install.
Then, reboot and choose to boot from your distro's USB installer ([ESC] then select USB drive from list). Install to the entire internal HDD.

I've personally tested Fedora 20, Linux Mint Debian Edition, and SteamOS so far, as well as Windows 8.1.


---------------------------------------
Restoring the Stock Firmware
-------------------------------------------

If you've used this script to setup for a standalone OpenELEC/Ubuntu setup, or otherwise flashed a custom coreboot firmware, you'll need to restore the stock firmware before using Google's recovery media to restore/reload ChromeOS. Full instructions can be found on the wiki here:
ASUS_Chromebox - Restoring the Stock Firmware



This script is a work in progress, all feedback is appreciated and I'll do my best to implement any fixes/improvements.

cheers!

------------------------------------------------------------------
Version history
------------------------------------------------------------------

2014-07-29 -- v2.16
------------------------------------------------------------------
- updated VGA BIOS to always init display even if connection not detected (fix no video for some users)
- updated coreboot/SeaBIOS naming to reflect suitability for both Asus (panther) and HP (zako) ChromeBox models
------------------------------------------------------------------
2014-07-12 -- v2.15
------------------------------------------------------------------
- updated to OpenELEC 4.2 beta 2 (4.1.2), which now includes working USB3 wake from suspend, so custom build no longer needed.
------------------------------------------------------------------
2014-07-12 -- v2.14
------------------------------------------------------------------
- updated script to use a custom OpenELEC ChromeBox build for standalone setups, which enables USB3 ports to wake from suspend.
Fixes the issue of IR remotes not being able to power on the system when suspended. Dual boot setups are unaffected since suspend/resume is broken anyway.
------------------------------------------------------------------
2014-07-09 -- v2.13
------------------------------------------------------------------
- updated coreboot firmware to properly support virtualization (vmx/smx)
- updated script to make selection of connected USB devices more user-friendly
- updated to OpenELEC v4.0.7
- updated SeaBIOS datestamp
------------------------------------------------------------------
2014-06-30 -- v2.12
------------------------------------------------------------------
- updated script to persist MAC address, serial #, etc from stock firmware when flashing coreboot firmware
-- if you've already flashed coreboot firmware, script can extract data from stock firmware backup
- updated to OpenELEC v4.0.6
- updated SeaBIOS datestamp
------------------------------------------------------------------
2014-06-20 -- v2.11
------------------------------------------------------------------
- updated coreboot firmware with TPM disabled (fixes some Linux hangs)
- updated datestamp on legacy BIOS/SeaBIOS
- perform MD5 check on legacy BIOS after setting dual-boot
boot options in case it gets corrupted in the process
------------------------------------------------------------------
2014-06-14 -- v2.10
------------------------------------------------------------------
- updated coreboot firmware with USB boot detection fix
- updated legacy BIOS/SeaBIOS with USB boot detection fix
- update to OpenELEC 4.0.5
------------------------------------------------------------------
2014-06-11 -- v2.9
------------------------------------------------------------------
- updated coreboot firmware with HDMI boot menu video init fix
- updated legacy BIOS/SeaBIOS with HDMI boot menu video init fix
------------------------------------------------------------------
2014-06-09 -- v2.8
------------------------------------------------------------------
- updated coreboot firmware with potential video init fix
- include southbridge USB fixes from chromium coreboot branch
------------------------------------------------------------------
2014-06-06 -- v2.7
------------------------------------------------------------------
- update firmware (coreboot and legacy SeaBIOS) for compatibility with Core i3/i7 ChromeBox models
- change default legacy boot from USB to internal HDD (by request)
- ensure legacy boot is unavailable until dual-boot setup is complete
- update to OpenELEC 4.0.4
------------------------------------------------------------------
2014-05-30 -- v2.6
------------------------------------------------------------------
- fix OpenELEC dual-boot install issue
------------------------------------------------------------------
2014-05-28 -- v2.4/2.5
------------------------------------------------------------------
- re-add option to update Legacy BIOS for dual boot setups
- update legacy BIOS to SeaBIOS release 1.7.5
- fix legacy BIOS boot order (USB preferred)
- dual boot legacy BIOS boot menu only shown if USB drive(s) connected (USB 2.0 only)
- update coreboot firmware to use SeaBIOS 1.7.5
- improve script organization / error handling
------------------------------------------------------------------
2014-05-27 -- v2.3
------------------------------------------------------------------
- improved error handling for dual boot / OpenELEC setup
- updated coreboot firmware; text now indicates when booting from USB (cosmetic change only)
------------------------------------------------------------------
2014-05-22 -- v2.1, 2.2
------------------------------------------------------------------
- more robust mounting of USB drives for firmware backup
- added error checking to firmware backup
------------------------------------------------------------------
2014-05-21 -- v2.0
------------------------------------------------------------------
- revamped / simplified menu options
- updated coreboot firmware, integrated into standalone setup
- OpenELEC installer now uses standard OE version (vs custom build)
------------------------------------------------------------------
2014-05-19 -- v1.1
------------------------------------------------------------------
- added option for coreboot firmware update
------------------------------------------------------------------
2014-05-07 -- v1.0
------------------------------------------------------------------
initial release

XBMC on a ChromeBox?

Check out the wiki and my EZ install script

[Image: btn_donate_SM.gif]

(This post was last modified: Yesterday 05:02 by Matt Devo.)
find quote
Veronica Offline
Senior Member
Posts: 168
Joined: May 2012
Reputation: 0
Location: Ecuador
Post: #2
Thanks, no option to dualboot ubuntu + openelec for the ones that have removed chromeos with ubuntu already? Tongue that would be the best imo

My XBMC folder:

GDrive
find quote
Matt Devo Offline
Fan
Posts: 680
Joined: Nov 2008
Reputation: 41
Post: #3
One could certainly install Ubuntu in standalone mode and set up the partitions such that OE could be installed along side it afterwards, but that's well beyond the scope of this "1-click" tool. The ChromeBox is a linux device, and I've done my best to try and mask the pain of dealing with that aspect of it for the average user, but at the end of the day if you want something other than a relatively vanilla config, you're going to have to get your hands dirty and do it yourself Smile

XBMC on a ChromeBox?

Check out the wiki and my EZ install script

[Image: btn_donate_SM.gif]

find quote
tetsuya Offline
Member
Posts: 51
Joined: Mar 2014
Reputation: 3
Post: #4
Matt, you may want to add the tearing fix to your script for the ubuntu installation. Just add the following

Code:
echo -e "Section \"Device\"
    Identifier      \"Intel Graphics\"
    Driver          \"intel\"
    Option         \"TearFree\"    \"true\"
EndSection" > /tmp/urfs/usr/share/X11/xorg.conf.d/20-intel.conf

Were there a bunch of mceusb that weren't working? I just poped my dongle in and it just worked right after
installation without having to use the fix.
(This post was last modified: 2014-05-07 21:40 by tetsuya.)
find quote
underworld123 Offline
Senior Member
Posts: 141
Joined: Dec 2012
Reputation: 3
Post: #5
Wow....this is impressive. I do not own a Chromebox, but I want to get one just to try this script Smile

BTW, few more screenshots will be great.

What will happen if I run the script twice? Will it overwrite the previous installation? Can I use it to try OpenElec first and then Ubuntu, if I don't like OE?
(This post was last modified: 2014-05-07 21:49 by underworld123.)
find quote
jsp1 Offline
Senior Member
Posts: 124
Joined: Apr 2014
Reputation: 1
Post: #6
This is awesome Matt, should help some of those who were on the fence due to the somewhat complicated process take the leap. More exposure for the box with this kind of usage can only be a good thing for further development. Thank you for your continued efforts. Just great!
find quote
Matt Devo Offline
Fan
Posts: 680
Joined: Nov 2008
Reputation: 41
Post: #7
(2014-05-07 21:39)tetsuya Wrote:  Matt, you may want to add the tearing fix to your script for the ubuntu installation. Just add the following

Code:
echo -e "Section \"Device\"
    Identifier      \"Intel Graphics\"
    Driver          \"intel\"
    Option         \"TearFree\"    \"true\"
EndSection" > /tmp/urfs/usr/share/X11/xorg.conf.d/20-intel.conf

Were there a bunch of mceusb that weren't working? I just poped my dongle in and it just worked right after
installation without having to use the fix.

fix added.

Depending on the type of USB transfers a particular MCE device used, certain ones would not work when connected to USB 3.0 ports. I submitted a patch to fix this in the Linux kernel, but it has not yet been accepted. OpenELEC has implemented my fix already in v4.0.0. And installing Ubuntu with this script will update the kernel and apply the patch Smile

(2014-05-07 21:45)underworld123 Wrote:  Wow....this is impressive. I do not own a Chromebox, but I want to get one just to try this script Smile

BTW, few more screenshots will be great.

What will happen if I run the script twice? Will it overwrite the previous installation? Can I use it to try OpenElec first and then Ubuntu, if I don't like OE?

Well, that depends. If you set up a dual boot setup with either OE or Ubuntu and want to switch to the other, you'll need to restore ChromeOS first using Google's recovery tool (outlined in the wiki) since each modifies the internal HDD structure differently, and trying to change it all dynamically is more work than I care to put in. If you dual boot Ubuntu and want to switch to a different metapackage or different linux distro, then no problem. But if you've installed OE (or anything else in standalone) you'll have to restore ChromeOS (which is pretty trivial) since you can't run my script other than in ChromeOS when booted from the internal HDD.

what else did you want screenshots of?

XBMC on a ChromeBox?

Check out the wiki and my EZ install script

[Image: btn_donate_SM.gif]

(This post was last modified: 2014-05-07 22:15 by Matt Devo.)
find quote
Netix Offline
Senior Member
Posts: 124
Joined: Jul 2013
Reputation: 3
Location: Montreal, Quebec
Post: #8
(2014-05-07 22:10)Matt Devo Wrote:  
(2014-05-07 21:39)tetsuya Wrote:  Matt, you may want to add the tearing fix to your script for the ubuntu installation. Just add the following

Code:
echo -e "Section \"Device\"
    Identifier      \"Intel Graphics\"
    Driver          \"intel\"
    Option         \"TearFree\"    \"true\"
EndSection" > /tmp/urfs/usr/share/X11/xorg.conf.d/20-intel.conf

Were there a bunch of mceusb that weren't working? I just poped my dongle in and it just worked right after
installation without having to use the fix.

fix added.

Depending on the type of USB transfers a particular MCE device used, certain ones would not work when connected to USB 3.0 ports. I submitted a patch to fix this in the Linux kernel, but it has not yet been accepted. OpenELEC has implemented my fix already in v4.0.0. And installing Ubuntu with this script will update the kernel and apply the patch Smile

(2014-05-07 21:45)underworld123 Wrote:  Wow....this is impressive. I do not own a Chromebox, but I want to get one just to try this script Smile

BTW, few more screenshots will be great.

What will happen if I run the script twice? Will it overwrite the previous installation? Can I use it to try OpenElec first and then Ubuntu, if I don't like OE?

Well, that depends. If you set up a dual boot setup with either OE or Ubuntu and want to switch to the other, you'll need to restore ChromeOS first using Google's recovery tool (outlined in the wiki) since each modifies the internal HDD structure differently, and trying to change it all dynamically is more work than I care to put in. If you dual boot Ubuntu and want to switch to a different metapackage or different linux distro, then no problem. But if you've installed OE (or anything else in standalone) you'll have to restore ChromeOS (which is pretty trivial) since you can't run my script other than in ChromeOS when booted from the internal HDD.

what else did you want screenshots of?

So if I already have Ubuntu 13.10 dual booted. I just have to run the script to install Ubuntu 14.04 over it without needing to reset the chromebox ?
find quote
Matt Devo Offline
Fan
Posts: 680
Joined: Nov 2008
Reputation: 41
Post: #9
(2014-05-07 23:39)Netix Wrote:  So if I already have Ubuntu 13.10 dual booted. I just have to run the script to install Ubuntu 14.04 over it without needing to reset the chromebox ?

correct, it will erase 13.10 and install 14.04 + updated kernel + MCE fix + XBMC.

I've updated the OP with installation notes for each type when you don't have a "clean" system.

XBMC on a ChromeBox?

Check out the wiki and my EZ install script

[Image: btn_donate_SM.gif]

(This post was last modified: 2014-05-07 23:59 by Matt Devo.)
find quote
Smobbo Offline
Senior Member
Posts: 249
Joined: Oct 2010
Reputation: 2
Location: The Netherlands
Post: #10
This is great! Very nice!

I am considering getting a chromebox and with this script I think my biggest hurdle has been removed Smile!

Just curious about the noise level of the box, since I'm now running a raspberry pi (which is completely quite).
I know the chromebox will be much faster scrolling my rather big library, but if I leave it on 24/7 will I always hear a slight humming noise or will the fan stop after a while?
I think I'll run it 24/7 because I don't think you can power it on via a MCE remote, correct?


Anyhow, tnx for your work on this script (and the wiki!) Smile
find quote
Matt Devo Offline
Fan
Posts: 680
Joined: Nov 2008
Reputation: 41
Post: #11
as far as I'm concerned it's inaudible unless the box is pressed directly against your ear

XBMC on a ChromeBox?

Check out the wiki and my EZ install script

[Image: btn_donate_SM.gif]

find quote
Dougie Fresh Offline
Donor
Posts: 3,469
Joined: Feb 2009
Reputation: 81
Location: New Hampshire
Post: #12
+1 for an awesome contribution to the community.
find quote
devliskater Offline
Junior Member
Posts: 1
Joined: May 2014
Reputation: 0
Post: #13
Hi there,


thank you very much for the script. It saved me a lot of headache as a newbie to this whole thing. However, when I installed ubuntu (dual boot), it created a user and I dont know the password. I was never asked to enter a password. Any help?

Thanks. Cheers.
find quote
solamnic Offline
Posting Freak
Posts: 820
Joined: Jul 2009
Reputation: 4
Post: #14
How much space does the Chrome OS needs?
find quote
tetsuya Offline
Member
Posts: 51
Joined: Mar 2014
Reputation: 3
Post: #15
Username: user
Password: user

It's displayed at the Instalation complete and press enter to go back to the main menu screen, from looking in the script.
find quote
Post Reply