Skip to content

Instantly share code, notes, and snippets.

@sadasant
Created March 5, 2013 05:11
Show Gist options
  • Save sadasant/5088180 to your computer and use it in GitHub Desktop.
Save sadasant/5088180 to your computer and use it in GitHub Desktop.

Getting command line tools on your Chromebook

If you want have some fun in the terminal with your new ARM Chromebook here's how to get a simple Arch Linux ARM chroot up and running. It assumes you already have your Chromebook in dev mode, if not google it before you continue.

This method requires no partitioning or other messing with your system, it just uses the fact that the /usr/local space is writable and persisted between upgrades.

First of, download http://archlinuxarm.org/os/ArchLinuxARM-imx6-latest.tar.gz

Open crosh with Ctrl+Alt+T

In crosh run the following commands

shell
cd /usr/local
sudo mkdir arch
sudo chown chronos.chronos arch
cd arch
tar xzvf /home/user/*/Downloads/ArchLinuxARM-imx6-latest.tar.gz .

To actually chroot into your new Arch system you can use a script like this (put in /usr/local/bin/chroot_arch.sh):

#!/bin/bash
cp /etc/resolv.conf /usr/local/arch/etc/resolve.conf
sudo mount -o bind /dev /usr/local/arch/dev
sudo mount -t devpts none /usr/local/arch/dev/pts
sudo mount -t proc proc /usr/local/arch/proc
sudo mount -t sysfs sys /usr/local/arch/sys
sudo chroot /usr/local/arch /bin/bash 
sudo umount /usr/local/arch/dev/pts
sudo umount /usr/local/arch/dev
sudo umount /usr/local/arch/proc
sudo umount /usr/local/arch/sys

After that just run the chroot_arch.sh command and then you can install whatever command line utilities you need with pacman.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment