Friday, July 17, 2009

MobileMe (.mac) and the OS X Console - bug and the console dock bounce

I've been trying to track down an odd 10.5.7 software bug.

Every 1-3 days, my user session browsers hang. I can ping the net and browse the LAN, but Safari and Firefox are unable to get secure sessions or access the net (I need next time to check if email works).

Weird.

Anyway, to investigate this I launched the OS X Console app (called ... "Console) and studied the output. I didn't see that much about the browsers, but I saw a series of recurrent ".mac" sync requests that were failing. I looked into my MobileMe PreferencePane (new name for .mac) and I still had the credentials of a MobileMe account I was trying. I'd canceled the trial account, but the OS was still trying to sync it. I clicked 'log out' (or equivalent) and the problem went away.

So there's a 10.5.7 bug with discontinued MobileMe accounts. If you discontinue your MobileMe account, be sure to "log out" of the old account in the MobileMe PreferencePane

The Console's an interesting place to look for odd problems, in much the same way as in XP one checks the admin event monitors. It does, however, have issues of its own. It transiently uses 100% of my G5 CPU, and it has a very obnoxious bounce behavior. Every time a line is written to the Console it bounces in the dock to get my attention. I admit, I can't ignore the bounce.

I'm sure there's a way to kill the Console dock bounce, but a Google search didn't turn it up. (You can, however, toggle all bounces via the terminal).

Now back to that networking/browser/http bug ...

Update: I have to laugh. There's a Console.app preference for "when an open log is updated" that toggles the bounce. My expectations were too low; I didn't even look.

Update 7/20/09: The weird bug struck again. I tried to hit an https resource and both Firefox and Safari couldn't get a secure session -
Safari can’t establish a secure connection to the server...
In the past the next step is losing all http access. It's as though something were consuming a finite http related resource ...

I switch users and there's no problem, so it's a resource in my user session.

Then I check Console and find this ...
7/20/09 1:56:21 PM DashboardClient[23283] (ca.aquabox.widget.twidget) file:///Users/jfaughnan/Library/Widgets/Twidget.wdgt/Scripts/prototype.js: SyntaxError: Badly formed JSON string ... Twitter is over capacity
Huh?!

Yes, sure enough, I once installed a Twitter Dashboard client, Twidget, -- then forgot about it. It's making http requests in the background - constantly.

I wonder if it's consuming some resource ...

I've deleted it. Never occurred to me that the Dashboard client was sucking cycles -- I rarely run the db.

Update 7/25/09: Fixed. Turns out it was a Parental Controls bug.

Wednesday, July 15, 2009

Firefox 3.5 slow startup: It's a big bug

Firefox 3.5 can take up to 15 seconds to launch the first time each day I use it at home, but at work it can take, literally, minutes.

Disabling update checking seems to fix the problem. It's in Tools:Options:Advanced:Updates.

I disabled all update checking. Of course this is not optimal, I'm hoping FF comes out with a fix shortly (I'll have to manually request the fix update though!).

(Credit to a work colleague for this fix.)

Update 7/24/09: After a few days I realized removing update checking didn't really fix things. Another colleague spotted the bug report. Wow.

It's remarkable how long it took the Firefox team to admit there was a serious problem, and how egregiously bad the original security related design decision was. Per my colleague:
Apparently the issue is that the Firefox 3.5 NSS (Network Security System) reads all the files in the IE cache and the Windows Temp folder to generate a seed for its PRNG. Not only is that expensive in and of itself but it also might (!) cause your AV scanners to re-scan every one of the touched files. Apparently clearing your IE cache and Windows temp files may or may not help.
This should be a wake-up call for Firefox. How did this design make it into production? Why was there so much resistance to admitting something was badly wrong?

Update 7/24/09b: The newest release may have a fix.

Update 7/24/09c: It was a bad design flaw, but I now see why I was so affected by it. Some IE install glitch had given me a HUGE IE cache -- one that was above the IE 8 1GB limit! I only discovered this when trying to reset it, and discovering IE shrunk it to 1GB. I set it to 50MB and deleted what was in there. As usual my Windows Temp folder also held quite a bit of junk, but it was the IE cache that was huge.

The five incomplete ways to search a Google Blogger blog

There are several ways to search a Blogger blog, including the search box gadget, Google Custom Search, Google Blog Search, and and the Blogger editor search.

I'm just starting to use the search box gadget, but I suspect it's similar to Google Custom Search -- it turns out to use the very mediocre Google Blog Search indexing.

Google Custom search coverage of my blogs varies from very good to fair. It all depends on how Google feels about my blogs on a particular day. Sometimes it's keen, sometimes not so interested. When it's keen the material is well indexed, when I'm out of favor the indexing is shallow. It's never comprehensive however. (Google's variable affections reminds me of my 7yo daughter, but that's another story.)

Google Blog search has extremely poor coverage of my blogs. It seems to largely index the popular blogs.

The search function that's displayed in Blogger's NavBar is sometimes better than Google Custom Search, but it's shallower -- biased to newer stuff.

Finally there's the search function that's part of the Blogger editing environment. I thought that one was really comprehensive. I'd never known it to fail -- until today.

Google Custom Search found one of my very old (2003) posts in Gordon's Notes, but the Blogger editing search couldn't find it. I did some probing and it looks like I'm indexed from 2004 on, but it fails in 2003.

So from Google alone I count five different ways to search my Blogger posts, but none of them is perfect. The Blogger editor search is most comprehensive, but the Google Custom Search will sometimes turn up posts it misses.

Of course if this material were all on my hard drive Spotlight would index it all. The Cloud is not always your friend.

Stack Overflow now has global computer question site (beta)

First Stack Overflow came for the coders. Then they came for the Sysops. Now the dynamic duo of “Joel on Software” Spolsky and “Coding Horror” Atwood are going for all the rest of the geeks. I’ve joined the Super User beta (how did they get that url?!)…

… Super User is a collaboratively edited question and answer site for computer enthusiasts – on any platform. It's 100% free, no registration required….

Stack Overflow’s children are the heirs to the pre-spam usenet. Experts-exchange is finished.

Fantastic work, and very much appreciated. I very much hope there’s a fortune in it for them somewhere – I suspect there is.

I love these guys.

Monday, July 13, 2009

DIY video baby monitor and video broadcast review

I've had limited success with low cost broadcast video (ustream.tv) , iChat, and Google Video Chat. So I was impressed by the tips and lessons in this do it yourself baby monitor project (emphases mine) ...
The mighty mini, take two: DIY video baby monitor

... In response to Dave Caolo's recent ode to the Mac mini, I figured it was time to step up. I had two things gathering dust: my old standalone iSight, a gorgeous example of Apple design sadly idle since the advent of built-in iSights, and a lovely new Intel Mac Mini that was recently scored on sale at MicroCenter with plans to set it up for my older two kids once I could get my hands on a small LCD monitor.

I figured in the meantime it would serve nicely as a baby monitor, since I couldn't find a matching transmitter/receiver pair among the various baby monitors I had accumulated over the years. My idea was that it would live discreetly, headless and tailless (monitor, keyboard, and mouse-free) in the baby's room, and broadcast both locally on my network and also wide-area so grandparents could tune in remotely.

For the initial setup, I needed a monitor, but fortunately my TV has a PC (VGA) port, which I used to configure the mini. I set it to login automatically to the main account and join my Airport network. In System Preferences, I enabled screen sharing and added iChat as a login item.
In iChat, I enabled Bonjour and instant messaging, added myself as a buddy, and restricted chats to preapproved users under security preferences. Because I didn't want to connect via screen sharing every time I wanted to initiate a chat, I typed the following into Terminal so that it would auto-accept any incoming video chats:
defaults write com.apple.ichat AutoAcceptVCInvitations 1
... While this worked great for my own local use, it had some inherent restrictions: remote users (aka "grandparents who love to watch sleeping grandsons") couldn't join the chat easily. Spouses at work had issues with company restrictions on AIM. Plus, it was iPhone-unfriendly; the holy grail for me was turning the iPhone into a video terminal that followed me around.

I went through a few different ideas: private channel on Justin.tv (great for multiple viewers, but awash in advertising, restricted at work, and unavailable on iPhone), Skype (great video, automatic call acceptance and limited iPhone capabilities, but terrible for multiple viewers), and complicated setups involving QuickTime Broadcaster.
Not wanting to reinvent the wheel (well, no more than I already was doing), I hit upon SJKM's iCam software, which is an iPhone application & accompanying cross-platform video streaming tool specifically designed for video monitoring, available in the iTunes store for $4.99....

Saturday, July 11, 2009

When did Aperture get faster?

I was working with Aperture on my old G5 iMac today and I realized edit operations are significantly faster than they used to be. My hardware hasn't changed at all.

It's a noticeable difference. Kind of crept up on me.

I'm guessing it's something in 10.5.7 or in some RAW update.

Nice.

Friday, July 10, 2009

Airport Extreme: Firmware update, Time Capsule bugs, tips and fixes

Update 12/31/09: Time Machine failed me on an iPhoto Library restore.

Update 10/12/09: There may be a manufacturing defect with Time Capsule power supplies. The average lifespan is 18 months. Until Apple addresses this issue I'd advise against buying a TC.

--

As best I can tell from very old posts and an ancient (1999) web page, I bought my flying saucer Airport Extreme base station around August 2003.

It served me faithfully for almost six years, but in the past two weeks I’ve been having obvious network outages. At first I blamed my poor ISP (Qwest DSL, and ever since I upgraded to their higher service level they’ve been very reliable), but I finally stripped my network down until I could figure out where the failure point was. It was the AEBS. As of yesterday it worked for about an hour after reboot and then dropped off the network.

Cough.

Ok, I’m simplifying. I’ve had network wonkiness on and off for 5 months. It’s possible that a not-quite-dead AEBS played a role. Lord, I hate hardware failure. I can’t complain about the lifespan of my AEBS though; most wireless base stations seem to last about 1-2 years (heat? something about the radio?). So five-six years is excellent.

I tried reflashing the firmware just for kicks. I figured I’d reflash to the previous release (@2006 I think) then bring it up to the latest release (@2007). At first I couldn’t figure out how to do this, then I learned Apple has a very elegant (if slightly obscure) solution:

All about Time Capsule, AirPort Extreme, and AirPort Express base station firmware updates

… how can I install previous (earlier) versions of firmware?

Open AirPort Utility.
From the AirPort Utility menu, hold the Option key (Control key in Windows XP and Vista) and choose Check for Updates....
Select the specific firmware version you require.
Select your base station and choose Manual Setup from the Base Station menu, or double-click on the AWD icon.
Choose Base Station > Upload Firmware.
Select a firmware version and click OK.

Wow, that’s elegant. The UI displays images of the appropriate device. I had to scroll a bit since I was going back in time, but it worked. I think I had some odd thing where I had to do this twice, but I wasn’t paying much attention.

I flashed to old then reflashed to new, but it was still busted.

At last! Finally, I could buy new hardware!

I’ve been hurting ever since I fell on my shield and added Gordon’s Laws of Geekery to Gordon’s 4 Laws of Acquisition. Under the new regimen I’ve not been able to buy a darned thing! I thought I’d have a 3GS by now, but I’d misremembered a phone contract termination date so that won’t happen until October 1 (Em is getting my 3G).

I was leaning towards the 1TB Time Capsule because I like the idea of an Apple secured file share and the lightweight NAS approach – but the price differential between the Airport Extreme and the 1TB Time Capsule is absurd. My personal Guru of The Deal (A.M.) advised me to the buy the more reasonable priced 500GB Time Capsule and to track down the ever reusable 10% off Best Buy Coupon (harder to find these days). I don’t normally buy retail, but BFF will slaughter me if I don’t resurrect the WLAN tonight.

The 500 GB will do for now. It’s possible, though not super easy, to replace a Time Capsule drive. In a year or so I might swap in a 2TB drive.

Update: A few observations after installing the Time Capsule

  • It doesn't include any USB or ethernet cables. Apple assumes you have these; I certainly did.
  • There's no power brick, just a cord. The power adapter is internal. Nice.
  • There's no WEP. It's WPA or nothing. Good.
  • I created a guest network with no password. My old G3 10.4.11 iBook still asked for a password when I connected to guest. I clicked cancel on the WPA password dialog and it connected. So a bug somewhere!
  • I have NAT on my DSL router and I ran NAT on my old AEBS. This device objected. I had to click the amber icon on the status link to stop warning me of the double NAT configuration. The TC wanted to go into Bridge mode, but then there's no public network share, etc. Odd. It seems fine in double NAT. There's a setting on my 2WIRE Qwest DSL router to allow all ports to pass (disable firewall) so if I discover issues with double NAT I can disable that. I can also put my DSL router in Bridge mode.
  • There's only one USB port. So if you want to connect a printer and hard drive you need to use a powered USB hub (per the manual). I don't know if you could connect multiple USB printers or multiple drives. I'll play with that eventually.
  • The 5GHz 802.11n only network is disabled by default. I enabled it. It's hidden away in Wireless Options. (See bugs below, however)
  • If you connect a printer, you can share it over the Internet (WAN) including using Bonjour.
  • If you connect an external USB disk, you can archive your Time Capsule data (all of it, I think) to the external disk. Then you can take it offsite. I've not seen this feature mentioned; seems like it should get more play.
  • Windows File Sharing is configured under the Disk File Sharing menu. It asks for a Workgroup name and a WINS server. I don't have a WINS server, so I entered my workgroup name. When I tried to connect it declined my authentication request. This isn't covered in the manual and, as near as I can tell, is not documented anywhere! Weird. There are several alternative security options for the NAS drive. Since I haven't exposed it to the public net I enabled Guest access. On my PC when I was prompted for a user name I entered "Guest" and then left the password empty. That worked.
  • In theory you can share disks over the Internet including with Bonjour access without a MobileMe account. I've not tested this.
  • The 802.11n range is impressive. I'm typing this in the basement, two floors beneath my TC. The signal is excellent. I've disabled my old AirPort Express WDS, it now only an AirTunes client.
  • The Time Capsule is fanless and very hot to the touch. Uncomfortably so. It lives in a cabinet with my cables, I think I'm going to move it to an area with more air circulation. The heat output might be a good reason to purchase an Airport Extreme rather than a Time Capsule -- heat is bad for gear.
  • Note that if you use the Time Capsule disk as a file share, you have to figure out how to back it up. You can't use Time Machine!
  • When you use Time Machine with a Time Capsule it creates a sparse disk image for each backup. So you can use the Time Capsule both for backup and and as a file share.
Update: I've found several issues - of course
  • There's a bug affecting my iBook running 10.3.9 with an 802.11b network card. It connected fine to the AEBS using WPA but it can't connect, using the same password, to the Time Capsule. If I enable the Guest network with no password it can connect. The connection failure error message is cryptic: "There was an error joining the AirPort network ..."
  • If you enable BOTH the 5GHz 802.11n network and the Guest network then an 802.11b client will see ONLY the Guest network. With this combination there's no 802.11b LAN connection.
  • My AirPort Express had no trouble running AirTunes when paired to the saucer AEBS (802.11g) in WDS mode. It's now stuttering in conventional client mode.
Update: I somehow fixed the G3 iBook 802.11b 10.3.9 access problem.

I played around with various features. I was abruptly connected, but I'm not sure what happened.
  • I turned off "use wide channels"
  • I turned off 5GHz support
  • I read this 2004 Airport 3.4 knowledge base article and followed the advice ...
    If you see the message after updating to AirPort 3.4, try these steps:
    1. Dismiss the message after it appears.
    2. Press and hold the Control key.
    3. While holding it, reselect the network from the AirPort menu.
The iBook console log had repeated error messages of the form "malloc[273]: error for object ... : Double free".

I see lots of complaints, but I can't find anyone else who's had success getting a machine this old to connect to Time Capsule. I'll update this post as I learn more. I did open an Apple Discussion thread on this problem.

Update 7/11/09:
  • I reenabled the 5Ghz 802.11n support and my 802.11b 10.3.9 iBook is still connected - for the moment. So far my 5.8GHz phones still seem to work.
  • After moving the 802.11n connection to 5GHz my 802.11g connected Airport Express AirTunes service stopped stuttering. (Try saying that quickly.)
  • My iPhone seemed to have some trouble seeing the network prior to connecting, but then seemed fine after connection. That may be a separate iPhone 3 bug.
I've done some further research. It's surprisingly hard to learn this, but it turns out that adding 802.11n to the default 2.4GHz spectrum used by 802.11b/g is a bridge too far. I think the 802.11n was knocking out the 802.11g AirTunes connection.

When I moved the 802.11n to the 5GHz frequency the dropouts stopped.

AirPort Utility Advanced:Statistics:Logs and Statistics shows all devices and throughput. My current signal, after moving 802.11g to 5 GHz looks like (higher, meaning less negative, is better):
  • iBook (16) 802.11b: - 71 (1 floor down)
  • MacBook (21) 802.11n: -41 (next to AirPort)
  • AirPort Express (61) 802.11g: -80 (downstairs and across the house)
  • iPhone (47) 802.11g: -54 (next to AirPort) and -90 (next to AirPort Express)
Note that the MacBook (802.11n) has a much stronger signal than the iPhone at the same physical distance, and the AirPort Express (802.11g) also has a stronger signal at the same distance.

My impression is that the combination of 802.11n interference and the distance to the 802.11g AirPort Express was causing the AirTunes dropouts. The fix was to move the 802.11n signal to 5 GHz.

It's so sad that I bet Emily this would be easy to configure.

Update 7/13/09: Since migrating the 802.11n to 5GHz and disabling wide channels it's working pretty well. This morning I had another "There was an error joining the AirPort network" message from my 802.11b 10.3.9 iBook; I'd not configured it to auto-connect and I got this on a manual connect. I clicked 'retry' and it connected; it also worked when I restored the auto-connect feature. It's an odd behavior, I wouldn't rule out some distance/interference effect playing a role.

I did test Time Machine from my wired iMac and that worked well. As noted above when you use Time Machine with Time Capsule it creates a sparse bundle DMG for each client machine. So you can use a single Time Capsule disk as both a file server and a Time Machine store.

I'm going to use Time Capsule from my MacBook as well. I'm still using Retrospect as my primary backup with offsite rotation, but I like the idea of a secondary backup that relies on a completely different technology.

I've yet to see how Time Capsule manages multiple external USB drives connected through a powered USB hub and I've no plans to test the print server capabilities.


Update 12/15/09: Things have settled down. It had to be reset a month ago, but otherwise stable. I did read an extremely complex article on 5GHz configuration; hard core geeks will want to study it closely.