Saturday, September 26, 2015

Creating Chromebook Recovery Media on Linux

This should have been really easy. Like REALLY REALLY easy. Go and look up the instructions and you find out they have an app in Google Chrome for it. Cool, open up chrome, install the app, and find that it only supports Windows and Mac OSX.


Further down the page I found a "how to do this in Linux" (or something to that effect) link which downloads a script and tells you to change permissions and run it as root. And it fails...

So here's what to do. The reason the script seems to fail is that the file it uses to decide what image to download seems to have changed format or something. So, download that file.


This is the tricky bit. In a text editor (or using less or whatever), you need to find your model, or at the very least, make a reasonable guess to the correct model. If your chromebook is showing a sad chromebook face with a USB stick, then it's relatively easy. At the bottom of that screen if shows the hw identifier. It'll be something like ALEX ALPHA-DOGFOOD.

If you don't have that screen, you can probably just do a "powerwash". Instructions are here.

When you do a search, that model number should find something in a "hwimatch" block. Lower down in the stanza, you'll see a "url" block. Download that file. i.e. something like:


Unzip that file:


Make sure your usb stick is unplugged and run the following command:

 ls /dev/sd?  

Plug the usb stick in, wait a couple of seconds, and then run:

 ls /dev/sd?  

again. The device that has shown up is the usb stick. Now run:

 sudo dd bs=4194304 of=/dev/[usb_stick] if=[image file] conv=sync  
 sync ; sleep 1 ; sync 

And that's it! The recovery media should now be written and ready to use.

No comments:

Post a Comment