Saturday, April 28, 2012

ChrUbuntu 12.04. Now with double the bits!

Update #4: There's a new version of the ChrUbuntu script that offers much more flexibility. Be sure to check out my latest post at ChrUbuntu: One Script to Rule them All!

Update #3: I've updated the script so that module loading works with beta and dev channel Chrome OS kernels. If you were on beta or dev channel and ChrUbuntu booted but you couldn't connect to WiFi/ethernet, try now. Thanks to not-so-lazy commenter "The Lazy Husband" for the pointer and fix. I've also added a possible fix for some people getting out of space errors. The script below now works with external USB Flash and SD Card ChrUbuntu installs.

Update #2: Instructions for installing to an external USB or SD Card are up!

Update: The script now works on older Cr-48 and Samsung Series 5 Chromebooks. For details, see this blog post.

I'm excited to announce the release of ChrUbuntu 12.04! ChrUbuntu is a clean install of Ubuntu 12.04, the latest Long Term Service release customized to run on Chromebooks. This is the first Ubuntu for Chromebooks that is 64-bit which means it will be twice as fast! Okay, maybe not but it'll at least be compatible with the new Chromebook and Chromebox :-) Also with this release, Chromebook features like 2-finger scrolling and audio and brightness controls work out of box.

Installing ChrUbuntu is extremely easy, just follow the steps below. Want to say thank you for ChrUbuntu? Feel free to do so in the comments below or show your support by visiting the advertisements on this blog. If you purchase a Chromebook or any other Amazon items using the links on the right, I get a small portion of the cost :-)
  1. To get started, make sure your Chromebook is in developer mode and has a developer BIOS installed. See Google's instructions for the Cr-48, Samsung Series 5, the Acer AC700, or the 2nd generation Samsung Series 5 550 and Chromebox Series 3 depending on your model. Samsung and Acer owners should pay special attention to the Developer BIOS instructions.
  2. Reboot your Chromebook but do not login. Make sure you have a WiFi or Ethernet connection at this point. 3G is not recommended. Press CTRL+ALT+=> (=> is the forward arrow where the F2 key would be on a PC). Do not use the normal CTRL+ALT+T method to get a shell. Use the CTRL+ALT+=> method while no one is logged in.
  3. Login as user chronos, no password is needed.
  4. As the chronos user, run:

    wget; sudo bash tnyga

    Make sure you have the command exactly right. tnyga is all lowercase letters and would sound like "tee in why gee aye" if you said it out loud (go ahead, try it!). If you get a "not found" error, make sure you have Internet connectivity.
  5. You'll be prompted with some information about your Chromebook. You may need to run an additional command to install a developer BIOS on your Chromebook or, if you have a 1st generation Chromebook, you might be notified that a special non-official kernel will be used to allow 64-bit Ubuntu to run on your hardware. Press Enter to continue.
  6. The Chrome OS stateful partition where your data and settings are stored is just short of 11gb by default, the script shrinks the stateful partition to make room for ChrUbuntu. You can choose to give ChrUbuntu from 5gb up to 10gb in 1gb increments (Note: If you've installed a larger SSD in your Chrome device, your max number and recommended max will be larger). I recommend not going higher than 9 as 10 leaves Chrome OS with very little free space (less than 1gb). Once you've entered a number, your hard drive will be repartitioned. It may look like the Chromebook is doing nothing for 10-15 minutes but let it be, after awhile it will reboot and re-initialize the stateful partition. This process takes about 5 minutes and then the Chromebook reboots again and shows you the Welcome screen you got when you first turned on your Chromebook out of the cardboard box.
  7. Go through the Chrome OS setup process again until you get to the Google login page. You'll need to have a WiFi or Ethernet connection again at this point. 3G is not recommended. Now follow steps 3 through 5 again. This time the script will see that you've already made room for Ubuntu and will start downloading the ChrUbuntu image and copying it to the SSD.
  8. There are 52 100mb files to be downloaded. Each is compressed so the actual download size ranges from less than 1mb in size to 90mb in size. The total size of all the files is about 1gb compressed and 5gb uncompressed so the download and install will take awhile. The files are named ubuntu-1204.binXX.bz2 (where XX is aa, ab, ac, ad, ae, af... ba, bb, bc... all the way to bz). If you want to see how big each piece is, take a look here.
  9. The script keeps track of which of the 52 files have been successfully installed so if you lose Internet connectivity, or the battery dies (you should be plugged in BTW), etc, just re-run Step 8 and it should resume where it left off.
  10. After all 52 files have been downloaded and copied to the SSD, the script will make a few more updates to your Cr-48 and then reboot.
  11. You'll see ChrUbuntu start up! The username is "user" and the password is "user" if you need to make changes.
  12. Right now, you're in ChrUbuntu but if you reboot, you'll be back in Chrome OS. To make ChrUbuntu the default, run:

    sudo cgpt add -i 6 -P 5 -S 1 /dev/sda

    (password is "user"). It should be possible to run this from ChrUbuntu or Chrome OS.
  13. To make Chrome OS the default again, either turn off Developer Mode, or run:

    sudo cgpt add -i 6 -P 0 -S 1 /dev/sda