Firmware Update 1.3 fixes Airport issues?

The Santa Rosa MacBook Pros have an issue where, depending on the type of wireless access point, if you use WPA (or perhaps even WEP, although why you would even bother is beyond me), when you run on battery power you get a kernel panic. The latest firmware update seems to have fixed this issue. It also seems to have fixed the issue where my machine wouldn’t automatically connect to a wireless network when waking up from sleep. Finally, the third issue I had, with not being able to permanently trust a certificate because I don’t have the root certificate, also seems to be fixed. Finally, painless wireless networking.

iCal Annoyance

Here’s an interesting little bug. Create a copy of a timed event in iCal (or just go to any timed event, I’m just making a copy so I can delete it later). Edit the start or finish time or date. When you are finished editing, press Tab. The time or date change will stick. If you chose a start time, the end time will adjust so the event is the same length. This is very cool, if, like me, you have lots of fixed-time events. Okay, now edit the time again. This time, instead of pressing Tab when you are finished, press Enter instead. Notice how the edit was actually discarded? This is crazy, crazy behaviour. The sort of thing you should be shot for. I mean, since when does Enter imply “ignore the edits I just made”? I mean, seriously. And this is before the fact that most of my friends hate me sending iCal invitations, as they don’t see the link for them to click on. I have to resort to sending gCal invites if I want responses!

Why AFP is better than SMB.

With netatalk, I can serve AppleShare Filing Protocol shares from my Ubuntu box. Since this is where all of my media files are stored, this is kind of nice. So, why use AFP over SMB (or NFS, for that matter)? Well, I still haven’t been able to get NFS shares to work properly from my MacBook Pro. It just sits there Connecting to nfs://poul … forever. So NFS is out. (I have configured the shares under Ubuntu, or at least, I think I have. I did use the GUI tool, which as you’ll read below, didn’t fully set up the shares for SMB either…) As I mentioned in a previous post, if you use the GUI tool to set up Samba (SMB) shares, you also need to use the smbpasswd -a [username] command. Finder doesn’t handle Samba shares very well. It takes an age to connect to them, and if they disconnect (ie, the network disconnects, such as when you move from one location to another, and change WiFi network; or the server restarts) you get a long Finder hang while it looks for the connection. OS X also used to disconnect Samba shares when you went to sleep, or if you slept for a long time. (This may have been the server, I don’t know) I can reconnect to an AFS share almost immediately. This means I can wake my MacBook Pro from sleep, wait a few seconds while it reconnects to the Airport network, and then press play on iTunes. All of my music lives on an AFP share, but it started playing immediately. It is little things like this that make computing nice again.

Move to NearlyFreeSpeech nearly complete.

Well, I’ve moved over from Blogsome to It’s very cool, and looks to be pretty cheap. I might have a high bandwidth bill for the last two days as I had to keep uploading SQL dump files (much faster than editing using nano over ssh!). When I imported all of my comments, the posts weren’t updated with the number of comments they each had, so I needed to run the following PHP script:

 1     <?php  
 2     require_once('admin.php');  
 4     echo "Approving comments...";  
 6     // Approve all comments  
 8     $wpdb->query("UPDATE $wpdb->comments SET comment_approved = '1'");  
10     echo "Updating post counts...";  
12     // Populate comment_count field of posts table  
14     $comments = $wpdb->get_results( "SELECT comment_post_ID, COUNT(*) as c FROM $wpdb->comments WHERE comment_approved = '1' GROUP BY comment_post_ID" );  
16     if( is_array( $comments ) ) {  
18     foreach ($comments as $comment) {  
20     $wpdb->query( "UPDATE $wpdb->posts SET comment_count = $comment->c WHERE ID = '$comment->comment_post_ID'" );  
22     }  
24     }  
26     echo "Done.";  
28     ?>

Nokia E65

I’m really liking the look of the Nokia E65 as my next phone. It has WiFi, Bluetooth, and Nokia also supply an iSync plugin. And it works with Salling Clicker, which looks like the must have phone/Mac interface program. Edit: Had N65 in the body, meant E65.

Top Posting

I like John Gruber, who writes for Daring Fireball. He usually hits the mark, but recently he’s been really harking on about the iPhone. Since they aren’t likely to be available over here in Oz for sometime, I’m not that interested, just yet. His latest post, Daring Fireball: On Top reverts back to a less iPhone topic, Top Posting in email replies. I ‘grew up’ using text-only interfaces on the internet, so email and usenet were king (and queen). I used to be a bottom/middle posting advocate, but have stopped for one very good reason. People think you haven’t replied at all when you bottom post. They don’t read down when they see that there is no response at the top. It’s as simple as that. I really prefer bottom/middle posting, it makes it much easier to structure a decent response to someone, yet it had really fallen out of favour. Perhaps I’ll restart this ancient practice. Except that every email client available nowadays is configured to automatically top post. Oh well. It just occurred to me that IM is much more mid-posting-like. You respond immediately to an argument, and the threads are mixed. Email is dead anyway (any situation where you receive 100 times as much Spam as Ham has passed its usefulness).

Proper Web Hosting

Well, I’ve actually felt like I outgrown Blogsome for some time. Don’t get me wrong, she’s been excellent to me, but there is lots of stuff I can’t really do properly that I want. For instance, I have some serious javascript hackery going on to get the data I want displayed. Stuff that does find and replace on dates, for instance. It would be much nicer to have this all done in PHP on the server. But some of it is very cumbersome to do in Smarty Tags, which are all Blogsome allows. I also have stuff scattered across various servers. The scripts for this site, for instance live at, which is just a redirect to somewhere else. is also another redirect. So, I’ve considered a hosting plan. When I originally registered, it came with 12 months of free hosting with DreamHost (originally, it appeared to be free for life, but as soon as I realised it wasn’t, I didn’t bother using it), and I’ve looked at them for hosting this, and several other domains. From what I can understand, you can point limitless domains there, and host them all under the one account. I’ve read the terms and conditions, and from them I also think I can resell my hosting space. That is, I can be webmaster for other domains, and have them all under the one hosting plan. Their data limits are far more generous than other hosts I have come across, and they are also rather inexpensive. $9.95/month for monthly payments, which drops to $7.95/month if you pay 2 years in advance. I might set up one of these accounts, unless anyone knows of a better place to host. And by better, I mean cheaper, with similar data limits (ie, very large), whilst still fairly stable.

tail -f /var/log/syslog is your friend

I’ve just spent about three hours troubleshooting encrypted passwords for netatalk. Basically, the plain netatalk that comes with Ubuntu, due to licensing reasons, does not include SSL support, which means only plaintext password authentication is supported. That wouldn’t be too bad for my purposes (I’m running on a secure network), but OS X complains each time you try to connect using plaintext only passwords. So, I followed the instructions from coderspiel: A year of plaintext AFP passwords is enough, but it wouldn’t work. Firstly, it needs BerkelyDB 4+, but will uninstall this to install 3+, which the package manager thinks it needs. Stupid. Secondly, some bits and pieces won’t compile. I did do some editing, but I felt this may break the whole thing, so I didn’t want to install the whole lot, just the missing uams. Basically, was missing. So, I built this, and others, and installed them. Still no joy. I did kind of get or something to work, but it kept saying incorrect password. Then, I stumbled on the idea to use tail -f /var/lov/syslog. This immediately showed me I was missing the symlink from to So that’s all there was to it. Now connections work perfectly. And AFP connections seem to be a bit more robustly handled (ie, less spinning beachballs of death), and faster for things like iTunes.

Don't forget to smbpasswd -a [username]

Aargh! I’ve just spent ages troubleshooting SMB networking on Ubuntu, only to realise that there weren’t any SMB users - which is crazy. Why not just default to having the local users match up with the SMB users. After finally getting that working, I did also get AFP sharing working. Which does appear to just use the users. Still, I need to keep SMB going, for the Windows/Xbox machines that sometimes visit my network…

Airport Extreme DHCP and LAN DNS

I use a local DHCP server to also act as my caching DNS, with the nice side effect that it also serves DNS requests for machines inside my LAN that have gotten their IP addresses via DHCP. Until this afternoon, this was my clunky old SpeedTouch modem. Today, I put that modem into bridge mode, and set up my brand spanking new Airport Extreme to do the PPPoE connection, and handle all of the routing, DHCP and DNS duties. It’s newer, right, so it should do a better job? Wrong. It does everything I want, except serve local DNS results. So, if I try to connect to one of my many machines, then it fails. And since I’ve gone from DHCP with reserved leases to a free-for-all DHCP, I have no idea which machine is which IP address! This is very frustrating, and is exactly the reason I retired the Netgear from this task, as it had exactly the same behaviour. It hands out IP addresses, but doesn’t store the machine names. Now, let me remind you this was working perfectly with the Airport Extreme just running in bridge mode. Everything else is set up right (apart from the fact it isn’t really using the DNS settings I set for it!), but it won’t do this. I’m sorely tempted to go back to how I had it all set up before. The only functionality I will lose is that VM machines connected over a bridged airport connection will not get an IP address from the SpeedTouch DHCP server. They do from either the Netgear, or the Airport Extreme, if I configure that way. I’m really annoyed about this. It’s a vital part of my daily use - I have fileservers, including one that stores all Music, and a fax/scanner server, which I don’t want to have to hard code IP addresses into. I’m thinking I may be able to go all Bonjour/Zeroconf/mDNSresponder. I’ll see how that goes.