Fr-eee-dom: roaming on the bus with wpa_supplicant

As I wrote earlier, I bought an Eee PC to use on the bus. Initially, I only used it offline to do some Debian packaging and blogging, but I soon discovered that I could do a few things online on the many open networks on my daily commute. While the connections are normally brief in good traffic conditions, even a few seconds here and there is enough to participate in irc discussions.

Manually connecting to each got old very quickly. So, to automate those connections I settled on wpa_supplicant, (wpasupplicant is the Debian package name,) which is quite easy to set up in roaming mode, as outlined in /usr/share/doc/wpasupplicant/README.modes.gz. All you need is the following in /etc/network/interfaces:

allow-hotplug ath0
iface ath0 inet manual
        wpa-driver wext
        wpa-roam /etc/wpa_supplicant/wpa_supplicant.conf
iface default inet dhcp

Then create your /etc/wpa_supplicant/wpa_supplicant.conf as follows:

ctrl_interface=/var/run/wpa_supplicant
network={
     key_mgmt=NONE
}

That’s it. You can now roam from one open network to the next and the supplicant will connect you to each one in turn. I have used this to reconnect to my screen session each time the bus slows down for a stop or gets stuck in traffic to carry on conversations on irc for the whole length of the commute.

If you also connect to networks requiring authentication, you’ll need to add a “network” clause for each network. See /usr/share/doc/wpasupplicant/examples/ for help with that, particularly the annotated conf file, README.wpa_supplicant.conf.gz.

For finer control over the process, I use sudo wpa_cli so i can:

  • keep an eye on what networks are around: scan, then scan_results,
  • disconnect from a network once I know it’s out of range
  • and reassociate as needed.

The only things that I haven’t figured out how to do yet are to make the process of switching from one network to the next a bit faster (it normally takes about a minute; precious seconds of online time are lost when the bus is in motion,) and to blacklist certain essids, e.g. commercial hotspots that make you pay before they’ll route your packets to the Internet. For the first problem, I have already tweaked my dhcp settings, which helps a bit. For the second, I tried adding network blocks for specific networks and setting them to a lower priority, but that doesn’t work because then the ‘catch all’ open network block kicks in and picks them up anyway.

Debian-eeepc now has atl2 ethernet

With Kel Modderman’s help, we now have a working atl2 driver for the Eee PC. This brings the Debian-eeepc project one step closer to providing a pure Debian replacement for the Xandros OS that ships with the unit. Now that Asus has released the GPLed source that was missing before, we now just have to ensure both the atl2 and asus_acpi modules get merged upstream.

The driver for the wifi in the Eee isn’t under the GPL, however, and therefore only works on the Xandros kernel provided with the default OS. Since I really can’t live without wifi and it is not my first choice to buy replacement hardware, in the interim, I’m living with using the Xandros kernel and modules on Debian. I can learn from studying the Xandros components in action, but it’s not a solution I’m happy with in the long term. The Debian-eeepc project’s goal is to produce a pure Debian solution, at least as far as that is possible given the hardware present in an unmodified system. On that front, I think the best bet is for ath5k to support the particular Atheros chip in the Eee. (Yes, I know about ndiswrapper, but for both technical and philosophical reasons I won’t use it.)

Debian-eeepc: the ideal mobile text editing device realized

The search for the ideal mobile text editing device is over. While the price was well over my original budget, we’ve since gone ahead and splurged on two new Eee PCs: one for me, one for my wife. In the end, I think it will be worth it because these systems are capable of far more than just editing text.

Now comes the challenging part. Xandros is the default OS and we want Debian on it instead. I have started supplementing the system with packages from Etch and Etch-backports using apt pinning, but already I have noticed some cracks beginning to develop: with pure Xandros, an SD card was automounted when it was inserted. Now it fails. Also, the Network utility no longer launches. I can work around these glitches for now, but it is plain that in the long term this Xandros/Etch hybrid is going to be more grief than it is worth.

To that end, enter Debian-eeepc. Building on the work started by timbobsteve and drawing from the collective experience of the Eeeuser.com community we will make a debian-live cd + debian-installer to install Debian (as pure as possible—obviously the kernel is going to be our most contentious issue) on the device. So stay tuned for more articles on that work-in-progress.

And how does my new toy shape up for mobile text editing so far? I’m delighted! For starters, this article was drafted on the bus home from work. The keyboard, while small, is still quite usable for touch-typing, the display is crisp and bright, and the size is just perfect for the cramped quarters of a public transit bus seat.

But beyond just editing text, I have loaded up the system with all of the tools that go around it: subversion, git, ruby, gcc, meld, etc. I’ll be able to manage a fair amount of development on the bus, with the exception being really large builds that will continue to be done on remote build systems.

Bumpy Typo blog upgrade: mod_fcgid 1.10 -> 2.1

For some time I have ignored my blog so I did not notice that when my co-admin upgraded our system from etch to lenny, it broke.

When I found some time to look at it, it turned out to be because the blog was no longer running in production mode, so it pointed at the empty development database. This caused every URL to redirect to the login page, but since I didn’t have a valid user for that db, I couldn’t login. This, in turn, was due to the upgrade of mod_fcgid from the old 1.10 version in Etch to 2.1.

Apparently, this used to work. Note the name of the module:

<IfModule mod_fastcgi.c>
   <Directory /var/www/vir/syn.theti.ca/typo>
    FastCgiIpcDir /tmp/fcgi_ipc/
    FastCgiServer /var/www/vir/syn.theti.ca/typo/public/dispatch.fcgi -initial-env RAILS_ENV=production -processes 15 -idle-timeo
ut 60
   </Directory>
</IfModule>

It’s strange that the section is called mod_fastcgi.c, not mod_fcgid.c. Either that was done to make it a “drop in” replacement for fastcgi, and later changed in the next release, or else this config was not actually used, but somehow my blog started in production mode before the upgrade anyway. In any case, the blog is back in production node with the new fcgid with the following module section (based on this one from the mod_fcgid home page).

<IfModule mod_fcgid.c>
   DefaultInitEnv RAILS_ENV production
   <Directory /var/www/vir/syn.theti.ca/typo>
     FCGIWrapper "/var/www/vir/syn.theti.ca/typo/public/dispatch.fcgi" .fcgi
   </Directory>
</IfModule>

Hope this is helpful to others making the upgrade.

The children of Debian

Who are the next generation of Debianists? Are they all still coming to us out of different OS backgrounds, or do we now have the significant beginnings of a home grown generation, born and raised in Debian-using families and now making their voices heard?

I hope that Debian Jr. will encourage this kind of generational growth of the project. When recently I rewrote the guiding principles of Debian Jr., my vision was a Debian that children would identify as their own. I expect they will be eager to add their own ideas as they grow up with it. It was pointed out to me today that there is some evidence that this is already happening (thanks for the link, Matthew Wilcox).

As for my own kids, ages 16, 15, 12, 9 and 5, only the oldest have ever used some system at home other than Debian1. They all comfortably use our Debian systems daily, discussing regularly with me what they need. This leads to filing bugs and patches on their behalf2, and inspires further development of the Debian Jr. project.

So, in at least this sense, the children of Debian are already contributing members of Debian, if not voting members. The ideas of families are improving Debian for everyone. As the project grows, I expect the ways in which families will change Debian will be more significant, not only technically but also in Debian’s character.

1 Before we started using Debian in 1995, the family system was a VT-420 terminal connected to the Solaris system running our community freenet. At that time our kids would sit in my lap and play at typing into pico for their amusement.

2 For instance, I was pleased to discover the other day that my egoboo patch was accepted. That was a direct result of my kids asking me to make it work for them.

Moved Debian Jr. repository to Alioth

A little remembered fact is that the Debian Jr. project had a directory in the subversion repository of the CDD project at Alioth. Aside from Andreas Tille’s experimental conversion of Debian Jr. to use cdd-dev1, there was nothing else there until today.

While I was in the process of populating this directory with the junior-* metapackages and adding an external reference to the live CD config, it seemed to me that it would be better to move the whole thing to our own repository at Alioth, which I promptly did. So now you can check it out:

$ svn co svn://svn.debian.org/debianjr

As well, I registered Debian Jr. at http://cia.vc/ and configured svn so that the CIA bot will report on the #debian-jr channel at irc.debian.org for every commit.

And finally, I applied for the creation of a debian-commits@lists.alioth.debian.org list. As soon as the list is created, I will hook it up to the repository so you can subscribe to commit emails.

1 Although this seemed like a good idea at the time, for various reasons I ended up sticking with the single metapackage per category model Debian Jr. uses to this day. But I have retained this experiment in the repository under svn://svn.debian.org/debianjr/branches/EXP-cdd-dev
in case we ever reverse that decision.

Launcher for xjig adds open dialog and file conversion

I have long recognized that to be usable by young kids, xjig really needs a better user interface. So I wrote a launcher, xjig-menu to address the problem. It adds a file open dialog (via zentiy) and support for more file formats (via imagemagick).

Update

I have put this script in subversion and added a man page. Check it out:

  $ svn co svn://svn.debian.org/pkg-games/people/synrg/xjig

or browse the repository.

live-helper progress

Now that live-helper1 has superceded live-package I have a config for the junior livecd work-in-progress in the debian-live repository:

sudo apt-get install live-helper
svn co svn://svn.debian.org/debian-live/configs/junior
sudo make-live --root junior &>make-live.log

This will build a usb image for the gnome-junior package list. If you want a regular iso image or want to try the kde-junior or xfce-junior lists, just make the appropriate changes in config.

I have tested the usb image on a 1G usb key. At this point I’m not layering on customizations, but am focusing on basic usability issues: X autoconfiguration, sound, menus, etc. Once I’m happy with these I’ll move on to the kinds of customizations we’d like to make for children.

1 live-helper is still in NEW at the moment. I’ve been checking it out from svn and building the package myself, though you can also get Daniel’s packages from his site. My config should work with a2-1 or later.

update

For the time being it is best to stick with live-helper from svn, as my configs are being developed to work with trunk, which is still in flux (e.g. config variables are renamed without notice, etc.)

svn co svn://svn.debian.org/debian-live/dists/trunk/live-helper
cd live-helper ; debuild -us -uc

make-live -p gnome-junior

Ever since I started working towards a Debian Jr. livecd back in November, I’ve played off and on with qemu, approx and debian-live.

Yesterday, I took another kick at the can. Being frustrated with make-live’s inability to combine two package lists, Daniel Baumann came to my rescue, promptly commiting and then releasing live-package 0.99.23-1
with three new package lists for Debian Jr.

  • gnome-junior
  • kde-junior
  • xfce-junior

So now we have something to play with. Try it out. Install live-package 0.99.23-1 or later, configure /etc/make-live.conf to set LIVE_MIRROR to your favourite mirror (I use the apt caching proxy approx to avoid re-downloading the same packages from one run to the next) and pick an image and type to build, e.g.

$ sudo make-live -t usb -p gnome-junior

This makes a ./debian-live/binary.img that can be put on a 1G usb key flashdrive.

We have more work to do to polish this. Particularly, since the GNOME and KDE flavours are larger than a 700M CD, some fat could be trimmed. If you’ve tried it, I’d love to hear your ideas on debian-jr@lists.debian.org.