Monday, December 17, 2007

The OLPC is here

I haven't been keeping with news so I was surprised and happy to find my new(est) toy on the doorstep tonight - an OLPC XO. I have been trying to put it down for several hours now so that I can take care of, well, anything else but it's fascinating. Performance wise it is not snappy but I can get on the network, download things, type in the word processor (abiword, I think) and generally fiddle around. I want to download some new apps just to see and then I am going to try and leave it alone for a while. At least overnight..

Has anyone else in Dallas (or elsewhere) received theirs?

Sunday, December 9, 2007

Starting a wireless interface properly

I added WPA-PSK to my router recently (the wireless connection has been open up to now) and that immediately caused problems because my Linux laptop (running FC6) didn't want to play nice. My shiny new MacBook had no problems (no surprise there).

After some rummaging around, I found that I needed to start wpa_supplicant so I tried that using the init script but had no success. After some more poking, I edited
  1. /etc/wpa_supplicant/wpa_supplicant.conf (to set the passphrase generated by wpa_passphrase)
  2. /etc/sysconfig/wpa_supplicant (to change the default driver from ndiswrapper to wext
and created ifup-pre-local and ifdown-pre-local to start and stop wpa_supplicant respectively. These get called from /sbin/ifup and /sbin/ifdown and can be contain anything you want run before bringing up the wireless connection. Mine look like this:


. /etc/init.d/functions

cd /etc/sysconfig/network-scripts
. ./network-functions

. /etc/init.d/functions

cd /etc/sysconfig/network-scripts
. ./network-functions

CONFIG=`echo ${1} | cut -d- -f2`

need_config ${CONFIG}


if [ "${TYPE}" = "Wireless" ]
/etc/init.d/wpa_supplicant restart

Presto! My wireless interface now comes up just like it should!
Now I have to figure how to setup wpa-supplicant for when I am away from my home network..