Friday, November 02, 2007

Leopard pounced on me

Yesterday was an odd day for me, Macintosh-wise. Upon reading about the updated MacBooks, I ran off to the local Apple store. These were 'silently' updated, meaning that Apple had added a few 'under the hood' tweaks and didn't make a big deal about it. In this particular case, it _was_ a big deal. I'd been on the fence about getting a MacBook, but the 2 GB RAM limit and the anemic GMA 950 graphics held me back. The new MacBooks accommodate 4 GB of RAM and incorporate Intel's new Santa Rosa chipset, which boosts the front-side bus speed and integrates the new X3100 graphics chipset. In true Apple fashion, pricing remains the same as before.

Alas, the Apple store didn't yet have the new MacBooks. Unlike officially-heralded product releases, Apple's silent updates are slow to trickle in. I didn't get my MacBook and now I've decided to wait a week or three to hear what early-adopters are saying about them.

I then tried upgrading my venerable Mac mini to Leopard (OS X 10.5). I know that upgrading any OS is generally a very bad move, but I'd had such a great experience going from Panther (10.3) to Tiger (10.4) that I felt compelled to give it a try. I was one of the lucky recipients of the infamous Stunning Blue Screen Which Waits for Godot. I quickly determined that Godot would be a no-show and tried to extricate myself from the mess. I'd backed up my data, so reinstalling from scratch wasn't going to be a problem. I actually prefer to do that once a year, or so. Lo and behold, the mini wouldn't respond to any boot-time keystroke commands. I couldn't force a boot from the CD/DVD. I couldn't boot into single-user mode. I couldn't boot into Open Firmware. I couldn't do much of anything except marvel at how this beautiful little 6"x6" box of brushed aluminum and white plastic refused to acknowledge my existence. I thought it might be my Logitech Elite (Mac & Windows) keyboard, so I bought a Mac keyboard. No go.

Time for surgery. Maybe it was the optical drive upgrade I'd installed earlier this year that was causing the hang. I popped open the case and swapped the stock unit back in. No dice. Despite Googling for solutions the whole time, I found little that helped. I stumbled upon a post which suggested using the mini's remote to select the boot device. I'd forgotten that the mini even _had_ a remote, but it worked. The mini ignored the keyboard, but faithfully obeyed the God of Infrared. This time I did a clean installation of Leopard and I was up and running in just a few minutes. I had to reinstall my apps, but that's never as much of a pain as many make it out to be. Took me less than an hour. Then I pulled my data off a backup disk and now I'm good to go.

Looking back over the settled dust, I now have a clean, working Leopard installation on my mini and a new Mac keyboard that I've quickly fallen in love with. The keyboard takes up less than half the desk space that my Logitech unit occupied and has a great key feel - especially to a guy like me who doesn't touch-type. I don't have a MacBook, but I'll get one one of these days. That day might be next week and it might be next Spring, after MacWorld, when they tend to rev a bunch of products. For now, I'm up and running again and I'm very happy about it.

Wednesday, February 28, 2007

New Parallels release!

I've mentioned that I run Windows under virtualization on my Mac mini using Parallels Desktop for Mac. Today they released an update which optimizes the use of screen real estate, adds USB 2.0 support, binary file drag & drop and allows Windows and Mac apps to run seamlessly side-by-side via a feature known as Coherence.

Upgrading my current Parallels installation was a snap. I played with Coherence for awhile, running Visual Studio and SQL Management Studio on my Mac desktop, and I was quite impressed by the overall usability. The good folks at Parallels have done an amazing job. Unfortunately, Coherence doesn't jive with the way I work in Windows. I tend to make heavy use of the Windows Desktop, which (obviously) isn't visible when in Coherence mode. I had to back off and settle for the traditional VM window at full-screen resolution. People who just run a few Windows apps and make little use of the Windows Desktop will really benefit from Coherence. It's very well done and extremely cool.

Personally, I'm thrilled by how easy it is to maximize the VM window and take full advantage of my 1280x1024 monitor. I'm constantly switching between Mac & Windows apps, so running the VM full-screen doesn't make much sense. Being able to maximize the VM windows DOES make good sense and that's exactly what I can do now.

Great job, Parallels! I understand that 3-D graphics acceleration and SMP are in the works. I don't care too much about 3-D graphics, but adding this feature means graphics pass-through to the hardware, which translates into faster 2-D, including video, videoconferencing, etc.

Friday, February 16, 2007

Virtualization and platform freedom

I've been a big fan of running OSs in virtual machines for some time. Virtualization is very useful when you need an isolated environment for evaluating software, a QA test bed encompassing multiple OSs and versions and for a variety of other purposes.

Until fairly recently, virtualization often incurred a minor, but very real, performance penalty. This isn't surprising given that you're running one OS inside of another and each OS is designed to be the sole guardian and caretaker of a computer's hardware resources. Previously, a typical hardware setup might include a notebook with a fast single-core CPU, 1 GB of RAM and a fast hard drive. The host and guest OSs might split the RAM evenly and they'd probably share the same hard drive. To run the guest OS, you'd close all possible apps in the host OS to prevent CPU starvation. In either case, the guest was likely to become starved for RAM if anything too intensive was attempted. Still, this approach worked well enough to make virtualization a very useful tool.

Things have evolved rapidly (or perhaps they've been more intelligently designed - doh!). Now dual-core CPUs with hardware support for virtualization are common, RAM is cheaper and it seems like everyone has an external Firewire drive or three. When virtualization is set up correctly on a modern platform, it's difficult to tell whether you're working with the host OS or the guest OS, provided that accelerated graphics (esp. 3D graphics) don't come into play.

One caveat of virtualization is that disk fragmentation is inevitable, prevalent and cumbersome to correct. When you defrag the guest OS drive, the virtual disk image on the host becomes fragmented, and vice-versa. The only real way to ensure a proper defrag is to defrag the guest, move the disk image to another drive and then copy it back. Perhaps we'll soon see defragmentation products which maintain some kind of coordination between virtual machines and the host environment. This would be particularly useful for virtualized servers.

My current setup is a Mac mini with a 1.66 GHz Core Duo CPU, 2 GB RAM and a 7200 RPM drive. My XP VM is a non-expanding image on an external Firewire 2.5" 5400 RPM drive (no external power source). The disk image is the only file on the external drive. I run Parallels Desktop for Mac as my virtualization package and the 2 GB of RAM is evenly split between OS X and XP. The mini is a great platform. It's small, attractive, quiet and energy-efficient. It costs me about two dollars per month to run at a 50% duty cycle.

I don't baby my XP setup in any way. I use it to make my living. I expect it to compile code quickly and to efficiently run any and all apps which I need to get my work done - all in its 1 GB of RAM (contrary to popular belief, 1 GB of RAM is plenty for a Windows dev machine if it's properly tuned and maintained). In the mean time, I do all my emailing, IMing and Web surfing in OS X. Response on both sides of the fence is crisp, even under load. Multiple cores really make a difference here.

Thursday, January 04, 2007

OS X vs. Logitech Webcams

My Mac mini has become my everyday machine. I use it for everything except for my work (I'm a .Net developer). Even then, I run Windows on my Mac via Parallels virtualization.

Until the other day I'd never had problems getting peripherals to work. My printer (HP PhotoSmart 7760) was automagically detected and configured by OS X and I found OS X drivers for my scanner (Canon LiDE 30) on Canon's site. I have a Logitech Elite keyboard (w/Win & Mac keys) and trackball, both of which have excellent Mac driver support for their non-standard features.

Then I tried to get a Webcam going. I have a Logitech QuickCam Pro 5000 and QuickCam Pro for Notebooks. Both are modern devices. The 5000 is only a few months old. Both cameras work great with Windows, but lack OS X drivers. The QuickCam Pro for Notebooks does have a downloadable OS X driver, but it's circa 2003 and PPC-only.

iOXperts has been providing Webcam drivers for OS X for several years now, but they're all PPC-based and their site doesn't show any evidence of ongoing development. The macam project (freeware) looked promising, but they have the same PPC-only issue. In either case, the 5000 isn't supported and QCP for Notebooks support is questionable.

Needless to say, I'm pretty disappointed with Logitech. They've always seemed like a Mac-friendly vendor and I'm surprised that they haven't hired a person or two to write some OS X drivers for their Webcams. I respect that they're under no obligation to do so, as the cams in question have never claimed to feature Mac support, but c'mon. A year ago, my scanner didn't have a Mac driver and the good folks at Canon managed to create one. The Mac is a reality in the computing world, especially in the home. Customers will increasingly expect hardware to support it.

I'm sure that I can find a high-quality cross-platform Webcam out there somewhere, but there's no way that I can rationalize buying a THIRD unit. Parallels is promising virtualized Webcam support in its next release, so I'll just be patient. I don't expect 30 fps @ 640x480 performance under virtualization, but I'll take what I can get.

Friday, October 27, 2006

Mac mini optical drive upgrade

As an easy and inexpensive way to complete three of my four intended base-model Mac mini upgrades, I purchased a Pioneer DVR-K06L optical drive (SuperDrive equivalent) from Other World Computing. This unit has the required Mac firmware, and they'll even buy my stock mini Combo drive back for $20. Once again I followed OWC's excellent installation instructions. The process took about ten minutes.

Thus far, the mini has been running fast, cool and almost completely silent. I've been monitoring the CPU temperature and load using CoreDuoTemp and I range between high-30s and low 40s (°C) under low load and between mid-40s and upper-50s under higher loads.

These three modifications were much easier than the final one will be - upgrading the CPU. Even that won't be too bad, though. The tricky part is applying the right amount of thermal paste between the CPU die and the heat sink. I've been down that road a few times before with Pentium III and IV boxes, so I don't anticipate any problems. I'm still quite pleased with the performance of the stock 1.66 GHz Core Duo. A 2.0 or 2.13 GHz Core 2 Duo should really smoke, although hopefully not in a literal sense. :-)

Wednesday, October 18, 2006

Mac mini hard drive upgrade

Phase two of my Mac mini mods involved swapping out the standard 60 GB 5400 RPM hard drive for a 100 GB 7200 RPM unit. As before, I followed the excellent instructional video from Other World Computing.

I chose the Hitachi Travelstar 7K100 (HTS721010G9SA00) drive. Installation was as easy as the memory upgrade. Once you've taken the mini apart a few times, there's nothing to it. I didn't do before-and-after XBench runs, but the machine certainly feels quicker now. The mini is just as quiet as it was with the old drive. It's nearly inaudible and doesn't seem to run any hotter, either.

Now I have enough room to split the disk into two partitions and dual-boot OS X and Windows XP (courtesy of Apple's Boot Camp). I'll report on this once I get around to setting it up.

Phases three and four will involve upgrading the CPU to a >= 2.0 GHz Core 2 Duo w/4 MB cache and a SuperDrive, not necessarily in that order. I want to live with it as-is for awhile in order to guage the effect of the drive upgrade over time. Plus, the 1.67 GHz Core Duo which came standard on the mini is no slouch. The SuperDrive is more a convenience than anything else. It'll allow me to burn DVDs.

Thursday, September 28, 2006

Mac mini memory upgrade

The first phase of pimping out my Mac mini was upgrading the RAM from 512 MB to 2 GB. I followed the instructions in this excellent video from Other World Computing.

The tools I needed were a thin 1" wide putty knife (emphasis on thin), a #0 Phillips screwdriver with a magnetized head (emphasis on magnetized) and a thin, stiff plastic card. I used one of the $10 Vinny T's gift cards that seem to show up in the mail every week or three. They're thinner than a credit card and are just about right for the job. Anything that feels like a business card made out of plastic should do. A stiff business card might even work, too.

There was nothing to opening the case. The clips released easily. The whole process took less than ten minutes, following the steps outlined in the video. The airport antenna wire has zero slack, but everything went back together just fine. Needless to say, the mini really likes the extra RAM. The performance boost was impressive.

Tuesday, September 26, 2006

Windows Remote Desktop Client on Intel Macs

Microsoft had long ago released a decent Remote Desktop Client (RDC) app for PowerPC-based OS X Macs. It's still freely available on Mactopia. On the newer Intel-based Macs, RDC has to run under emulation via OS X's Rosetta. The experience, IMHO, leaves something to be desired. With any luck, Microsoft will release an Intel port of RDC one of these days.

In the mean time, it's slow enough that's it's almost unusable for doing Visual Studio work. It flickers way too much and goes nuts over-scrolling when I try to block-select. To be fair, I'm working with the most basic of the current Mac mini models: 1.66 GHz Core Duo CPU, 512 MB RAM and a 60 GB SATA drive. I know the machine is memory-bound. 512 MB is too light for any major OS these days. I have a 2 GB upgrade arriving in two days.

It would be easy to chalk up the RDC sluggishness to the RAM constraint, but after installing TSClientX, which incorporates the venerable rdesktop and TSClient packages into a seamless Mac .dmg, I had to cast a suspiscious eye on RDC. TSClientX ran like lightning, even with my measly 512 MB. The whole Aqua/X11 full-screen switching thing (see the docs) is a minor pain, but the performance is worth it.

I hesitate to really cast doubt on MS RDC until I upgrade my memory. Emulation is both CPU and memory-intensive. Still, I'd suspect that an Intel-native rdesktop app will always outrun an emulated app on an optimized machine.

One major edge enjoyed by the X11/rdesktop approach is in the use of the F keys while debugging in Visual Studio. With the MS RDC, F10/11 (corresponding to Step Over/Step Into in Visual Studio) are commandeered by OS X's Expose feature. This really hinders the debugging process. When X11 is run in full-screen mode I have the use of my critical F keys under rdesktop. On the flip side, running X11 in full-screen mode means that I have to toggle back & forth between X11 and OS X's Aqua (the normal Mac desktop) using Command-Option-A.

There's no perfect solution right now. I'll re-evaluate MS RDC once I upgrade my RAM, but my money's on TSClientX/rdesktop.

Saturday, September 23, 2006

Mac mini - the secret to silence?

A few months ago I talked about tricking out a Mac mini and creating a silent, high-performance desktop machine with a tiny form factor. I'd recently built a reasonably quiet server from the parts I had lying around from an earlier project and those from an existing Pentium 4 machine. The server lives in the basement and provides us with file sharing, HTTP, FTP, SQL and VPN services. It's got drive redundancy and is quite secure (protected by tight system security, good firewalling and Labrador Retriever).

Back to the mini. I broke down and bought one. Just the basic model w/a 1.66 GHz Core Duo CPU, 512 MB RAM and a 60 GB 5400 RPM hard drive. Since my plan had always involved chucking the CPU, memory and drive, it didn't seem to make much sense to consider any factory enhancements (Apple's prices and options leave something to be desired). I've been having a blast with it and I'm realizing just how much I missed having a Mac. Perhaps most importantly, my mini makes no detectable noise (it's approximately 18" from my left ear) and it's not warm to the touch. Although I've been very happy with my Alienware Sentia notebook for everyday work, I've been feeling that having a single point of computing failure doesn't make sense for a guy who makes his living writing code. Plus, I like to stay abreast of new technologies and Intel's Core Duo / Core 2 Duo lineup features concurrent processing, various CPU instruction extensions and virtualization support (I'll have more to say on this in the near future).

My intention is to build a dual-booting Mac/Windows box using Apple's Boot Camp. I'll use OS X for personal stuff and Windows for doing my work. The first order of business was to boost the RAM. 512 MB isn't really enough for any graphically-intensive OS these days. In addition, the mini's graphics chipset 'steals' some of the system RAM for its own use. I ordered 2 GB (2 x 1 GB) of Corsair ValueSelect PC2 5300 RAM from newegg.com. That was the easy piece of the puzzle. The remaining pieces include a larger (since I'll need separate Mac & Windows partitions) and faster hard drive and a Core 2 Duo CPU with the 4 MB L2 cache (2.0 GHz and above), in that order. I'm currently looking at several hard drives in the 100 GB - 160 GB range with spindle speeds of 5400 - 7200 RPM. 5400s offer more capacity while 7200s offer raw speed. The 7200s also throw off more heat, which concerns me in a tightly-packed fanless case. The hard drive decision may prove to be the trickiest piece. The Core Duo and Core 2 Duo CPUs have very similar thermal profiles (way to go, Intel!), so I'm not so concerned about the CPU swap. I might even hold off on it for awhile if I see the expected benefits from the RAM and hard drive upgrades. The only _real_ difference between the Core Duo and Core 2 Cuo lines is 64-bit support, which is currently not much of a motivator. The Core 2 Duo features an average 5 - 15% performance increase over the Core Duo.

My mini also has a ComboDrive, which can't burn DVDs. I'll eventually replace it with a SuperDrive (which can burn DVDs), but this isn't really on the critical path. This isn't the kind of rig that gamers would want. The Intel 950 graphics chip is fine for light 3-D work, but not for intense gaming. I'll have more to say once I get the 2 GB of RAM installed.

Sunday, September 17, 2006

Another Windows Vista review??

...nah.  Just a few random thoughts and opinions.  There are plenty of well-crafted reviews of Vista RC1 out there for those who are interested.  I'm just aiming to share my initial impressions from working with it for a couple of days on my Alienware Sentia notebook (1.8 GHz Pentium M, 1 GB RAM, 60 GB 7200 RPM hard drive, Intel Extreme Graphics 2).

I make my living as a Windows developer, so it's important for me to keep an eye on what's coming down the pike.  I begin taking Microsoft development tools seriously when they reach the beta 2 stage.  I take thier operating systems seriously when they reach release candidate 1.  I base this rule of thumb on my own historical experiences with these product lines.  Prior to reaching these milestones, Microsoft products have often been too unstable for critical evaluation.  Once this threshold is achieved it's time to begin beating on them.

I was fully expecting to not like Vista.  Everything that I cared about as a developer was either removed from Vista or targeted for retrofitting to XP.  WinFS, the object-oriented file system (actually a layer atop NTFS), was dropped early on.  WinFX, which has since been recast as .Net 3.0, Windows Presentation Foundation, XAML, Windows Communication Foundation, etc., will be just as much a part of Windows XP as it is of Vista.  I was concerned about Vista's use of a 3-D drawing surface for the desktop, since that can cost serious CPU cycles if your graphics card isn't up to snuff.  Not being a gamer, my graphics capabilities often lag behind the cutting edge.

Vista was a pleasure to install.  It requires very little information and completes quickly.  It found all my hardware and even set up my oddball 1280x800 resolution screen properly.  Apparently my GPU wasn't up to Aero's requirements, so I didn't get to play with Vista's cool transparency features or its 3-D task switcher.  That's OK, 'cause I turn off all the graphical glitz anyway.  I need my machines to compile code quickly more than I need pizazz.  I expected that disabling the glitz in Vista would be more difficult that it is in XP, but I found it was easier.  Similarly, I assumed that Vista would wrap the traditional tools and familiar configuration dialogs in many layers of 'friendliness'.  To my delight I discovered that Vista's 'grandma-friendly' UI was only a thin facade sitting atop the tools I've worked with for so long.

I like the Mac/Linux-style confirmation dialogs which stand guard over system-level changes and I especially like having to just click 'OK' rather than having to enter a root password.  After all, I _am_ logged in as a member of the Administrators group.  Jumping through more hoops might be appropriate for server administration, but it's a pain in the butt when you just want to change something on your single-user desktop machine.

I still don't know if I really care that much about Vista.  I need to better understand how well Microsoft is talking to me with this release.  I don't need help with multimedia or computer security and those features seem to be Vista's primary focus.  I suspect that it will be a lesser feature or three that drives me to Vista once it's officially out.  That and my need to be running the latest and greatest.  :-)