Last Tuesday I made the move. I ditched Ubuntu and installed Arch Linux in my Acer Aspire One. After my post Linux is a time killer (which attracted a lot of attention, and didn’t really carry the message I wanted) I got a lot of comments to think about. The two most suggested Linux distributions were Debian/unstable and Arch Linux. Well, maybe Arch Linux was not that talked about, but the following comment bought me out:
I finally tried Arch and haven’t looked back. Initial setup is a little more lengthy (more config files, etc. to edit than say, Debian/Ubuntu net-inst), but the config files are really well layed out and easy to understand. Once its set up, its rolling release, so you should basically never have to reinstall from scratch again (which is what drove me away from Ubuntu originally - new system install every 6 months, I have better things to do). Updates just stream in continuously (and very quickly after they’re developed).
But the killer feature is probably the community documentation. The Arch Wiki is a massive, thorough and well made resource. If you have an issue with setting up something in Arch, its probably covered in the wiki. The first few times I thought they missed something, I was later proven wrong - its amazing. The Arch community is just really good at documentation.
If you’re not too new to Linux (if you’ve ever thought of Ubuntu as “too mainstream”), then give Arch a try, its awesome.
I had used and installed Debian previously, knew it wasn’t a thrilling experience. Thus, installing Arch Linux in my AAO was worth a try (while implementing some disaster-preventing solutions from other commenters), at least one or two days of Linux fiddling. Thus I sat up, copied my important stuff in a USB stick and started the process
The first step is just downloading the image file to write in your USB stick. As I was already inside a Linux system, it was plain easy following the instructions on installing from USB stick. I went for the net install image, where just the base system is written in the disk and the rest will be downloaded from the Internet. I managed to even configure my wifi connection from the command line, if I did it, you can do it too!
Now comes one of the last easy steps. Reboot, press F12 (in my Acer Aspire One) to change the boot device to the USB stick. Once it has booted, and before starting the installer, it is better to configure the keyboard map, console font and wifi.
I like a lot this console font!
To configure the keyboard and font, run km. I choose, of course, the qwerty_es key map, and as for a font, one I hadn’t used before and I liked a lot afterwards, ISO01-12x22. It looks very Times New Roman, very nice and big.
After that, it is the wireless moment. For me, this worked:
ifconfig wlan0 up
iwconfig wlan0 essid “myId” key “mypasswd”
because my key was WEP. If your router uses WPA passphrases, you need to use WPA_supplicant, which isn’t as hard as it looks. But if it is not your router, maybe you don’t know which encryption it uses… start with WEP and then go to WPA. Maybe you’ll need to do the two last steps of it twice, or wait a little before issuing the dhcpd.
After this, test your net with an ifconfig wlan0 and ping www.google.com. If everything works as expected, run /arch/setup. If you have DNS problems, add nameserver 18.104.22.168 to /etc/resolv.conf (Google’s DNS).
The installation procedure is guided, but there are several possible pitfalls… I slipped in at least two. Well, three counting my problems in configuring the wifi connection.
First, when selecting your packages, be sure to select wireless-tools. If you don’t… When the installation is complete and everything is working, there will be no networking. And you can’t install any package.
Once the base packages are installed, you need to configure them. First, you will be asked which editor do you prefer: nano, joe or vi. I selected nano the first time. Just before, you will be asked to either copy the current networking configuration into the future network configuration, or leave it as is. I decided to copy… And then all configuration files you were supposed to edit with nano were empty. Moreover, nano could not write the files either. And when I selected change root password, the installer broke. Restart needed.
Once restarted, I selected vi as my editor (and I am an emacs guy… here you can find a cheatsheet) and not to copy. Everything worked out as expected, following the guidelines of the Arch Linux beginners guide. After a while, the system was working.
Tweaking started. First, some modules and daemons from Acer Aspire One in the Arch Wiki. Not everything, just one after the other to get xorg installed and working. In case you don’t know, installing in Arch Linux packages is done via pacman, with pacman -S package. You can also look for a string in the packages list with pacman -Ss package.
Once I could startx, I had to choose a display manager (you can find them in this Arch Wiki list and set-up, I went for Slim) and a window manager, which of course had to be Fluxbox. Fluxbox installation details here.
After some wrestling with .xinitrc and the like, I got it working, and realised it was the moment to adduser. I added my main user, forgot about groups and had to manually add the user to all the relevant groups, detailed here.
Now everything started to get downhill, as I had some working X. I installed the networkmanager and networkmanager-applet from Gnome, to control my wifi connections, although you have a lot of possibilities in this page for wireless set-up. Installed emacs-23.6 and firefox-3.6, checked they worked and left the rest for the following day. It is the day of package installing, configuring Fluxbox keybindings and these small and long chores.
First, as I was in my office, I needed to get working the external monitor as I like it. Before it worked somehow ok, when setting up the external resolution the laptop monitor shut down. Now, for some odd reason it didn’t happen… Thus I set up WinKey+F5 to display in external monitor and Shift+WinKey+F5 to switch back to the laptop screen. In Fluxbox’s keys file:
Mod4 F5: exec xrandr –output VGA1 –mode 1152x864 –output LVDS1 –off
Shift Mod4 F5: exec xrandr –output LVDS1 –mode 1024x600 –output VGA1 –off
To find out which resolutions are available to your external monitor (even for your LCD screen), plug the monitor VGA connector and issue
This will give you a list of available resolutions for all devices, with its corresponding names. In case of doubt of which is the external and which the LCD, unplug and repeat: one will disappear.
Now, my computers are always on duty. This means, I need suspend on lid. To do so, be sure to add your default user to the power user group (in fact, read this list of user groups you should consider), then just read these steps. They work perfectly… Except maybe for some X problems. Do it at your own risk, of course. For me, it worked ok after xrandr was configured correctly, see above. After coming back from sleep, the external monitor will flicker. Turn back to the LCD and then again to the external monitor (just 4 keypresses and 2 seconds) and it will be solved.
Installing emacs packages was a charm using ELPA, texlive was installed in just 20 minutes (I didn’t find a generic texlive with all packages, thus I had to write several texlive-stuff to get everything installed) and working in no time. The main afternoon problem was setting up networkmanager and gnome-keyring-daemon to work together. After much, much googling and changing, the solution can be found here. In broad terms, you check that dbus is running, together with the addition of
auth optional pam_gnome_keyring.so
session optional pam_gnome_keyring.so auto_start
to /etc/pam.d/slim (you should change slim for your session manager) and this line
eval $(gnome-keyring-daemon -s –components=pkcs11,secrets,ssh)
to your .xinitrc. All these three changes, together and nm-applet and gnome-keyring-daemon where happy ever after. Because writing a 16 hex digits key several times can be nerve-wrecking (I know, I know, I have it in a file, but anyway).
Then, as I checked my twitter timeline, I followed a link to youtube… Installing the flash plugin was done via pacman -S flashplugin, then I had to copy /usr/lib/mozilla/plugins/libflashplayer.so to ~/.mozilla/plugins and chmod +xr it. Then, I realised I didn’t have sound enabled… A little looking around until I realised it just was that Alsa is muted by default. You can solve it with
amixer set Master 90% unmute
After this, I wanted to be able to raise and lower the volume with the dedicated fn keys of the laptop… The proposed solution in Arch Linux wiki page on Acer Aspire One (using xbindkeys) didn’t work directly, had to change it for
> "(amixer sset Master toggle)"
> m:0x0 + c:121
> "(amixer set Master 2+ unmute)"
> m:0x0 + c:123
> "(amixer set Master 2- unmute)"
> m:0x0 + c:122
> "(sudo pm-suspend)"
> m:0x0 + c:150
I.e. remove the db after 2. This didn’t satisfy me, I wanted libnotify (which I installed together with pidgin… remember to enable the pidgin notify plugin!) to tell me the volume levels. A solution I found over the web is a nice bash script called bashmixer. I modified a little the code to show volume after every operation. Maybe there is a better solution for this… Any idea? Anyway, the AAO has problems with audio playback from its speakers. Remember it!
I also added gnome-power-manager, to see my battery levels (I forgot to install it the first day… bad!). As the netbook stands, everything I need is installed and working correctly. Just 1 day more or less. And Arch Wiki and Arch Forums are fantastic places to find solutions to Arch Linux problems and configurations (beating by a wide margin Ubuntu forums).
Oh, I almost forgot! I got the left hand and right hand card readers to hotplug by adding pciehp to the MODULES line in /etc/rc.conf, i.e. MODULES=(… pciehp) and creating the file /etc/modprobe.d/pciehp.conf with the following content:
options pciehp pciehp_force=1
After rebooting, both card readers will hotplug (when inserting an SD card, which is the one I use).
In case you wonder, I am not the only one loving Arch Linux in my Acer Aspire One:
Arch linux HOWTO « Acer Aspire One ZG5 - The system I have now runs better than any other OS I’ve tried on my AAO — I may switch all my computers to Arch if this proves to be stable.
And another user blog:
Installing ArchLinux on Acer Aspire 7720-934G « Where r00t has no land - ArchLinux installation and configuration on Acer Aspire 7720-934G.
9 programming books I have read and somewhat liked…
Linux is a time killer
My first port to the Ben NanoNote: gnugo
Power to the command line
Two weeks, still loving Fluxbox
Three dee (3-dimensional file system browsers review)
Gcal: the ultra-powerful command line GNU calendar
Acer Aspire One 8.9’ + Ubuntu + Fluxbox