Saturday, April 4, 2015

Cheaper Music Making - Part 6 Geeks only need apply


When I last posted on the Linux music making effort, I was wrestling with Crouton, latency and several Linux based DAWs. Its been awhile and I've done quite a bit of experimenting and hacking since then. With all of this effort, I'm drawing a few conclusions that I'd like to share:
  1. While cheap in terms of hardware, making music on Linux is significantly more difficult than on a commercial platform. The setup for hardware and software solutions are overwhelming and in varying degrees of maturity - it remains a domain for tinkerers and hackers.
  2. Crouton, while tremendous on the Chromebook has a "wall" when it comes to latency. Since it shares its kernel with the chroots and its kernel is not optimized for low latency (such as hooking up MIDI keyboards), there is only so far it can take you. I find it usable, but just barely.
  3. It is a lot of fun hacking around getting all of this to work - which is why I kept going on this over the past month. My definition of "fun" might not fit yours though! 
  4. If you are really just looking for cheap hardware for your music making, you might do better to focus on second hand hardware and use cheap and/or free options. Many of the software packages for music making on Linux have cross-platform options.
With all that said, I decided to try yet another option on the chromebook hardware - a full linux distribution that dual boots along with Chrome OS. By going with a full distro, I can tweak the settings and kernel as needed to get the desired performance (in theory at least). I already replaced the SSD in the chromebook with a 128GB option, so I decided to install an independent 32GB Linux partition.

Any kind of hardware configuration in Linux requires a detailed knowledge of the touchpad, music cards, screens, etc. Instead of going through all of that work, I did take a shortcut and used pre-configured Linux installs for my Acer C720 available at Distroshare. This site has many Linux options pre-made for a few Acer chromebooks - the C720 and C740 for the most part. 

If you wish to go this route and create a dual-booting Linux, I cannot emphasize enough the need for backups! Chrome OS is very easy to recover, but if you have files on your local machine in your Downloads folder or you have existing crouton setups, you need to back these up before trying to partition and install a full distro. The instructions on Distroshare, sort of assume you are setting up Linux for the first time and don't make it clear that the process is destructive! It will cause your Chromebook to reset itself. Also, many installers are looking to completely replace Chrome OS. In my case I wanted to be able to boot either OS so you have to look for the instructions for Dual-boot and follow them carefully. If you make a mistake (I made several!), be prepared to do a full recovery of your Chrome OS - not that hard, but takes about 20 minutes or so each time. I've slightly altered the instructions from the site. Please note that step 1 will cause the partition to be created and your chromebook will recover itself - so have your backups first! 
  1. Go into a terminal window on your Chromebook (Ctrl-Alt-T), type shell and download and run the Chrubuntu script to partition the disk: curl -L -O http://goo.gl/s9ryd; sudo bash s9ryd. At this point, Chrome will reboot and repair itself. Format the filesystem on /dev/sda7 while you are in the ChromeOS shell, which is where Linux is going to. To do that, type sudo mkfs.ext4 /dev/sda7
  2. Reboot and boot into legacy mode (Ctl-L) with the usb stick with this distro on it.
  3. Run the installer continue on until you reach the "Installation Type" section.
  4. Choose: "Something else" or "manual install"
  5. Select /dev/sda7
  6. Select Change. 
  7. In the popup window, configure it so the filesystem matches what you formated it as in step #3 and the mount point is "/". Do NOT select the format checkbox. Then press ok.
  8. A new popup might show up with the title: "Write previous changes to disk and continue?" Select "Go Back" - Do not write the changes to disk or you will have to recover. 
  9. Select "Install Now"
  10. A new pop up will show up with the title "Do you want to return to the partitioning menu?" Select "Continue"
  11. Another popup: "Do you want to return to the partitioner?" Select "Continue"
  12. Another popup: "Continue with installation? No partition table changes ..." Select "Continue"
Once all of that completes and you reboot (pressing Ctrl-L when the splash screen shows), you should be in a full independent Linux on your laptop. This allows you to alter any of the etc files, create custom kernels etc. I'll get into those steps later.