Introduction

A couple of years ago I bought myself a black Linux SSD EeePC 901. I slightly regret the black as it really shows fingerprints but if you really want to get me started mention the included Linux distribution. It's something Asus derived, badly, from Xandros.

Among the problems with the distro is the partitioning scheme. The machine contains a 4GB "drive" for the system and a 16GB mounted at /home.

The 4GB drive is split into a 3.2GB read-only partition that comes preloaded and a read-write initially emty 700MB one that is union-mounted (aufs) on top. The idea is anything you do to bugger up the latter can be undone by re-formatting it. But note that some updates do operate on the read-only partition by temporarily remounting it writeable.

The problem is once you apply Asus's updates, which incidentally come in through a system that doesn't even enforce the order of application, your read-write partition overfills and things break. Others have written about how to do away with this scheme but here's my version. Another benefit is that it runs a bit faster not having all that union stuff in the way.

Sorting out the partitions

You will need you Eee PC (obviously) and some external bootable thingy with a partition editor that is capable of resizing partitions. The method as described here undoes all updates you have done though does preserve your /home. But in any case backup, backup, backup. You can keep updates by fiddling around moving files from the writeable partition and deleting what had a corrsponding whiteout file but I don't cover that here and in any case the update system becomes a mess for reasons already mentioned.

I first decided to look into how the thing boots. I looked at the grub menu and the initramfs and concluded that pretty well all I needed to do was have the thing run with sda1 mounted on root and not a lot else. I decided I would blow away my sda2 forgetting my system updates and redo them later.

Remove any SD or USB devices unless it's them you're operating on. You might want to start with a really clean system using the Linux Recovery DVD.

DO NOT PROCEED UNLESS YOU'RE EXPERIENCED AT EDITING CONFIGURATION FILES, MAKING PCs BOOT, FIDDLING IN THE BIOS, HAVE MET GRUB'S MENU BEFORE AND UNDERSTAND WHAT'S GOING ON HERE.

IN ADDITION YOU MAY WELL NEED TO ADAPT THESE INSTRUCTIONS UNLESS YOUR MACHINE IS LOADED WITH PRECISELY THE SAME VERSION OF SOFTWARE AS MINE.

First you need to edit grub's menu. Note we're editing the version stored on the normally read-only partition. In my case it is mounted /ro. You might find it's at /.ro or something. You can get an honest mount list in /proc/mounts. mtab lies somewhat.

mount -o rw,remount /ro
cd /ro/boot/grub
cp -p menu.lst msnu.lst-inst
nano menu.lst
Make a copy of the first entry and stick it at the end changing the name. Remove the initrd line, change the root root=/dev/sda1 and add init=/sbin/fastinit to the kernel line. The init is pretty well all the initramfs does after doing the union mount. Also change the boot timeout to a couple of seconds and the default entry (or do this bit later). Maybe remove "quiet". This is what I have.
# default boot entry
default=4

# Boot automatically after 1 second.
timeout=2
.
. [four entries above mine]
.
title New and improved
        root (0x80,0)
        kernel /boot/vmlinuz-2.6.21.4-eeepc rw vga=785 irqpoll nosplash root=/dev/sda1 init=/sbin/fastinit
Now that's mostly done. Reboot into your new arrangement (remembering that if you haven't change default yet you'll have to do catch grub in those two seconds). You should now have your Eee in its virgin state except your home should still be there.

Get your self a bootable thing with a partition editor on it. I used the windows version of UnetBootin to knock up a bootable USB stick with Parted Magic. You don't need to download anything but Unetbootin. You might choose to use a CD instead.

You will probably need to fiddle with your BIOS to make it boot from the USB stick. In paritcular my stick initially half booted and complained it couldn't load something or other. While I began looking into it on the other machine I noticed it had sorted itself out and was booting. Great.

Fire up the partitioning tool (gparted), carefully delete the 700MB ish sda2 partition and resize sda1 to take up the space. That's about it.

You'll need to do updates again. Try to apply them in rough date order.

Other things to cleanup

Unless you need to write Chinese I suggest you remove the gcin packages because it's something you don't need running. Do dpkg -l | grep gcin then dpkg -r those packages.
Please let me know how you got on especially if I've forgotten to mention something important.

Jon Schneider. Early 2010.