How to add ChromiumOS to existing Ubuntu install

Guide now supports Flow Build
Both Intel and NVidia friendly

WARNING: THIS GUIDE IS TOTALLY UNSUPPORTED BY HEXXEH, PLEASE DO NOT ASK HIM ABOUT ANYTHING REGARDING IT. MULTIBOOTING IS NOT A SUPPORTED USAGE METHOD RIGHT NOW, BUT MAY BE SUPPORTED IN THE FUTURE.

Overview

This document provides a guide for installing ChromiumOS to your computer's hard drive. It allows you to perform this install while maintaining your existing Windows/Ubuntu installations. After following this guide, you will be able to multi-boot between Ubuntu 1) and ChromiumOS and/or Windows 2). This guide uses Hexxeh's ChromiumOS build (http://ChromeOS.hexxeh.net/).

Disclaimer: You could lose all of your data on your computer during this process. This could happen due to an error in this guide, an error in your application of this guide, or other reasons. Proceed at your own risk. Always back your data up first. Additionally, please look over this guide in it's entirety before proceeding.

The Hexxeh's ChromiumOS build we will be installing uses two partitions. One for the “clean” OS, called C-ROOT, the other for state generated by using the OS, called C-STATE. The rough outline for the installation process then is as follows:

  1. Install the ChromiumOS image to USB
  2. Add partitions for ChromiumOS onto your machine's hard drive.
  3. Copy partitions from USB to hard drive.
  4. Update GRUB configuration

Requirements

  1. Computer with existing grub-based Ubuntu installed
  2. 2 GB of free space on your machine's hard drive
  3. An empty USB thumbdrive 2GB or greater capacity
  4. Bootable copy of GParted
    1. A Live CD is the easiest way to go
    2. If you don't have a CD drive, check out the instructions for a USB stick 3)
  5. ChromiumOS image (http://chromeos.hexxeh.net/)

Step 1: Install ChromiumOS image to USB

Follow directions for your operating system (Linux, Windows, Mac)

Optionally, you may want to check that that the ChromiumOS actually works by trying to boot directly off the USB stick first.

Step 2: Add partitions for ChromiumOS onto your machine's hard drive

Note: In this document, GParted is used to modify and create partitions. Technically, this can be done using programs other than GParted, but they have to be the exact same sizes that are mentioned next. If you are using GParted, boot into it. Create two new partitions. One should be 252MiB, while the other should be at least 1600MiB. If you do not have free space to create these partitions, you will need to resize existing partitions to be smaller.

How to create partitions in GParted

Note: This is one of the most dangerous parts of this guide. Make sure your power will not be interrupted for the next twenty minutes. Also, note that you cannot run GParted off of the same disk that you are partitioning; for most of you that means that you'll have to run it off of a live CD or a USB stick. For additional reading, check out an introduction to GParted.

  1. Boot into GParted
  2. Accept all defaults (key map, language, etc.)
  3. Take a look at the top right hand corner of the GParted window and make sure that you've got your destination disk selected
  4. Take a look at the partition map at the top of the screen; we need to free up about 2 GiB of space in there
  5. Choose a big partition, select it from the list, click the Resize/Move button at the top
  6. In the Free Space Following (MiB) box type 1854, press enter, click Resize/Move
  7. Now you should see a new gray item called unallocated; select it, click the New button
  8. In the New Size (MiB) box type 252, press enter, click Add
  9. Right click the unallocated item again, click the New button
  10. Click Add (the new partition should be larger than 1600 MiB, if it's not start over with an initial amount slightly larger than 1854)
  11. Click the Apply button

Step 3: Copy partitions from USB to hard drive

Boot into Ubuntu. Copy the partitions from the USB key to the newly created partitions on your machine's hard drive. The C-STATE partition (262MB) should be copied to the ~264MB partition. The C-ROOT partition (about 1677 MB in size) should be copied to the ~1679 MB partition on your machine. Do both of these copies with the 'dd' command.

This is the most dangerous part of the guide. Make sure you have the correct partition references.

Basic Syntax of Commands:

sudo dd if=/dev/<C-STATE_USB_PARTITION> of=/dev/<MACHINE_264MB_PARTITION> bs=4096
sudo dd if=/dev/<C-ROOT_USB_PARTITION> of=/dev/<MACHINE_1679MB_PARTITION> bs=4096

Actual Examples: (be sure to replace sdb1,sda5, etc. with the actual partitions for your machine!)

sudo dd if=/dev/sdb1 of=/dev/sda5 bs=4096
sudo dd if=/dev/sdb2 of=/dev/sda6 bs=4096

Note If you get “Error 15” later when you boot, perhaps you'll need to replace “4096” with “4M” in the commands above. See http://code.google.com/p/chromiumos-hexxeh/issues/detail?id=111#c4

Step 4: Update GRUB configuration

Grub (pre Karmic Koala)

Once your machine partitions are updated, remove all USB keys. Run the following command

sudo update-grub

To get to ChromiumOS, restart your machine, hold the escape key during start up (to bring up the GRUB menu), and select “ChromiumOS”.

Grub2 (Fresh install of Karmic Koala)

We're first going to edit the file /etc/grub.d/40_custom so lets give ourselves the permission to edit it by running:4)

sudo chmod 777 /etc/grub.d/40_custom

Next, open this file in gedit by executing:

gedit /etc/grub.d/40_custom

Add the following at the very end:

40_custom (partial)
menuentry "ChromiumOS" {
	insmod ext2
	set root=(hd0,x)
	linux   /boot/vmlinuz root=LABEL=C-ROOT rw noresume noswap i915.modeset=1 loglevel=1 quiet
	initrd  /boot/initrd.img
}

Nvidia users use this

menuentry "Chrome OS Flow NVIDIA" {
 root=(hd0,x)
 linux /boot/vmlinuz console=tty2 init=/sbin/init boot=local rootwait root=LABEL=C-ROOT rw noresume noswap i915.modeset=1 loglevel=1 apci=force single
 initrd /boot/initrd.img
}

Important Note: Where it says (hd0,x) type the number from the partition where the C-ROOT was copied to from Step 3 (i.e. (hd0,6)).

Now, save your work and close gedit.

Finally execute sudo update-grub2 to properly generate a new Grub Configuration

To get to ChromiumOS, restart your machine, hold the shift key during start up (to bring up the GRUB2 menu), and select “ChromiumOS”.

Other Considerations

  • You will lose 2GB of hard disk space using this guide, but it is completely reversible (assuming all goes well).
  • This procedure (as of 17/02/10) was tested successful. If it didn't work the first time for you, go back and double check the partition references that you used in gedit. That's probably where things went sour.
  • If you have very carefully read over the guide twice and the dual booting aspect of it isn't working out, give @mdwittenberg a shout on twitter
  • Check out the faq
  • To set Chrome as the default boot, check out this post's second task
  • Wondering why it is sometimes MB and other times MiB? See Chart
1) This guide is actually compatible with any distro which uses GRUB or GRUB2 (i.e. UNR, Jolicloud, OpenSUSE, Mint, etc) – “Ubuntu” is used as a common example
2) We do not yet have a method to dual-boot ONLY Windows and ChromiumOS
3) GParted via UNetbootin is flakey, I recommend following the Windows Choice 1 (Manually) method
4) The GRUB2 procedure is to be used for the new GRUB2 config file found only in a clean install of Ubuntu 9.10 Karmic. Older versions of Ubuntu use the menu.lst file. Even if you upgraded from an earlier version of Ubuntu to Karmic, even 9.04 jaunty, you still need to install GRUB2 manually. See https://wiki.ubuntu.com/Grub2.
 
multiboot.txt · Last modified: 2010/06/25 21:54 by 67.252.42.242
 
Recent changes RSS feed Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki