The Desktop App is still King

Although all the “cool kids” these days seem to be writing web apps, and the word “cloud” has taken on a new meaning that is sure to confuse meteorologists and normal people alike, I still think that desktop apps are very important. Maybe even important enough to deserve a little more attention than they’ve been getting lately (living, as they do, in the shadow of the buzzword friendly “web app”).

Now, I’m not deriding web apps here – I use them, too! But let’s face it – the web was not designed to be an application. Look up the history of what hypertext means and you’ll see how far we’ve had to stretch it to get to where we are today.

Even the very best web apps tend to spend a lot of effort to look just like a desktop app. When the lazy programmer in me sees this sort thing, it causes me to develop an unhealthy twitch (in minor cases) or curl up into a ball in the corner (in extreme cases), muttering something about “code reuse.”

Of course, this is just a generalization – there are web apps that have absolutely nothing in common with desktop apps – take Google and Twitter, for example.

But even truly unique web apps still end up tied to the desktop in one way or another. I use Google all the time; but most of my searches happen through the “search” box in Firefox. I use Google Notebook, but I get to it through a Firefox add-in. I use Twitter, but I do so through a client (I’m currently using Witty Twitter, but there are literally dozens and dozens of clients out there).

Sometimes I worry that we focus too much on web app design, to the detriment of desktop app design (UI design in particular). Web apps are cool, sure, but the desktop app is still “king,” and it’s not wise to ignore the king!

I Think I’ll Use Windows 7

So, I’ve been trying out the Windows 7 beta lately… and I think I’ve decided, that when Windows 7 is officially released, I will upgrade to it.

…Let me explain.

As you probably already know, I currently use Windows XP. It came with my computer when I bought it, and I just didn’t see the incentive to upgrade – what with the horror stories of driver incompatibilities and so forth. Given everything, it just seemed like it was better to wait until the device manufacturers got around to updating their drivers for Vista, and all the dust had settled (and there was a lot of dust, as you’ll recall).


The new Windows 7 Desktop you've probably seen a million times already.

Of course, by the time the dust had settled to my satisfaction, along comes the announcement of Windows 7. And after giving it a try (and having used Vista before as well), I can say that Windows 7 is just what many people say it is – basically, a “Vista Super Service Pack.” Vista 2.0. Vista “as it should have been.”

I mean, I do like some of the features of Vista and Windows 7 – the graphics sure do look nice, and I’d love to have the new Windows Media Center to play with. But Vista had some annoyances (some of which I’ve written about before) that annoyed me just enough to not upgrade.

But Windows 7 does some things to help that (Vista’s first Service Pack did too, to be fair). The improvements to the UAC (user account control) service were long-overdue (and, in my opinion, the problems with it should have been caught in beta testing). Windows 7 is now smart enough to realize when you (the user) actually clicked on something, and not second-guess you and ask you to “please approve what you just did.”

It’s worth noting, of course, that there were probably some BIG technical challenges to this, even though it seems simple (in principle). After all, it is possible to use functions like “SendKeys” and the like to simulate user interactions – and how is the computer supposed to know the difference between a “real” user action and one that was “simulated” by another program? Without a lot of re-working, hacks, and clever tricks, the answer is “it can’t.” But, being difficult isn’t a good enough excuse in this case, and I’m happy to see Microsoft went ahead and did the Right Thing, even though it was hard.


You can even make the new taskbar smaller, like it was in Vista, if you prefer.

Speaking of the “Right Thing,” that brings me to the new taskbar – a hotly debated topic among Windows 7 reviewers!

The new Windows 7 taskbar is, and will continue to be… controversial. It is, arguably, better than the old taskbar. It is also quite obviously a sort-of-copy of the Mac OS X “dock” –  the idea of using the same icons for launching an application and for switching windows. It sounds confusing at first, and honestly, it is. It will take some getting used to.

In a way, though, I think of Windows 7 as being similar to Office 2007 – yes, things look all different, and yes, you’re going to have to learn some things over again, and what you used to have memorized won’t work anymore. But in the end, once you get used to it, you see that it really is better.

I was one of those people who, at first, was really annoyed with Office 2007. But after I got used to it (and as Yoda would say, “unlearned what I had learned”) I found I could find things easier, faster, and do more. I even found things I didn’t know about before. And isn’t that the point?

Likewise with Windows 7. Yes, it’s different, but really, it is better. And after you “unlearn what you have learned,” you’ll find you don’t really have to “learn” anything new, really. It all just makes sense, once you open your mind to it. And that’s a good thing – that’s what “intuitive” is supposed to be like.

An exchange from the movie The Lion King sums it up nicely:

Rafiki: Change is good.

Simba: Yeah, but it’s not easy!

Making the decisions for Windows 7 undoubtedly weren’t easy for Microsoft. But sometimes, you have to make the “hard” decision to do what you know is right (or better), no matter how much people will complain that they can’t get back their classic start menu or whatever. (Coincidentally, although the classic start menu is really gone, most of the things people gripe about – the “run” dialog box and the quick-launch toolbar – are still there; they’re just hidden a bit. But you can bring them back – just do a Google search and you’ll find people telling you how, if you don’t want to change.)

But there are other factors at play here, at least for me. For one, I’m getting ready to upgrade to a 64-bit CPU this year – finally making the jump to the land of 64-bits (which is where we’ll all be, eventually – it’s inevitable). I’ve basically maxed out the RAM that my computer can address, and I still find myself needing more – and the only way to get more than 4GB of RAM is to upgrade to a 64-bit CPU and a 64-bit OS.

So, the move to 64-bits is going to force me to upgrade my OS one way or another – it might as well be to the latest Windows version, right?

Now I just need to wait and see whether an upgrade from XP to Windows 7 will even be supported – because I don’t want to have to do a “clean” install. Here’s hoping!!

Bad Sectors? Low-Level Format

It seems like there IS a way to “clear” bad sectors from your hard drive so you can use tools like GParted and the like – but I use “clear” in a very loose sense here!

First off, I MUST point out that I’m talking about file-system bad sectors. I’m NOT talking about physically damaged disk platters.

It seems NTFS keeps a list of bad sectors, and as long as those sectors are there, most partition-resizing tools will refuse to touch the disk with a 10 foot pole. HOWEVER… those of you who are beyond a certain age might remember something called a “low-level format.” (I’ll wait a moment for you while the moment of nostalgia passes.)

I thought I’d never see a need for low-level formatting in today’s world of super-reliable, super-fast, super-S.M.A.R.T, super-big hard drives – but it seems there is still one use for it.

The hard drive manufacturer’s low-level formatting utility will detect “bad” sectors and put them in the drive’s internal list of “bad” sectors – this is in the drive’s own firmware mind you, not in any file system structure (because at this point, your file system has been wiped out!).

Once this is done, the drive’s own controller will silently avoid those bad sectors – from any software’s point of view, those sectors or clusters just don’t exist anymore. (Since software rarely – if ever – directly addresses the disk, this sort of behind-the-curtain hiding of sectors or clusters is easily done by the drive’s on-board controller.)

After the low-level format, you can partition & format the drive normally, and your OS or whatever disk-checking tool you use should find a nice, clean disk with no errors.

Astute readers will note the downside to this “solution” – you have to low-level format your hard drive! Obviously this erases everything on it, without any possibility for recovery. So it’s not for the faint-of-heart.

And, coincidentally, it’s not for me, either. I’ve simply got too much data on my 2nd hard drive to back it up easily (and cheaply). And doing this to my primary hard drive (and thus being forced to re-install Windows) is simply out of the question.

For those that are interested, I found a lot of this information in this EASEUS Software Forum posting, while looking for the reason why (you guessed it) their software wouldn’t re-size my partition.

In the end, it looks like I’m stuck running the Windows 7 beta in a virtual machine – which is of course super-slow.

Maybe someday I can shell out the cash for an external hard drive so I can back up my data and do the low-level format… but until then… I’m stuck with my partitions the way they are. Bummer!!

Interested readers may want to catch up on the previous entries in this saga:

GParted, Why Hast Thou Forsaken Me?

UPDATE March 16 2012 – there is finally a solution to this problem – read the updates at the end of this article for details.

Longtime readers will remember the computer drama that unfolded back in May of 2008 when I bought my new 500 GB hard drive. Basically, when I tried to resize my NTFS partitions, GParted (or, more specifically, the tool ntfsresize) said “you’ve got bad sectors on your disk, I’m not touching anything” and refused to run. I eventually lost the battle and settled for a (less than ideal) configuration for my new disk.

Fast-forward to today – the public beta of Windows 7 is meant to come out today, and although there’s always the virtual machine route, for something like this I thought it might be worthwhile to dual-boot so it could have the full power of my machine (Vista under Virtual PC is OK, but sloooooow – imagine what a beta version of an even newer OS would be like?).

Since Microsoft’s web servers seem to be totally overwhelmed with the demand for Windows 7, they’ve taken the download off-line for the time being. So, given that it seems like I might have to wait a bit, I figured I might as well download the latest GParted LiveCD (version 0.4.1-2 in case you’re curious) and make a little partition space available.

As you might imagine from the title of this post, I wasn’t able to do it. It was the same problem as before – there were “bad” sectors on the disk, so ntfsresize refused to do anything. Oh, sure, I could have tried to do it from the command line and used the --bad-sectors option of ntfsresize, but I’m not one for specifying disk sizes based on cluster locations, which is how you’d have to do it. And I couldn’t even get the parameters that the GUI interface would have used when resizing, because it wouldn’t even let me try to resize under the GUI to get the parameters!

After all, what’s the point of a GUI LiveCD if you can’t use the GUI!

What’s even more confusing/infuriating is that every forum post or help document I could find on this subject seems to go like this:

Novice User: I’m getting this “bad sector” warning – but I ran CHKDSK two times like it said, it found no bad sectors (or it found one and repaired it), but I still can’t run ntfsresize!

Linux Guru: Your disk is failing, get a new one.

Novice User: But…


I have, of course, embellished this somewhat for dramatic effect, but you get the idea. The assumption is always that the problem is with the hardware. (Even the Wikipedia article on ntfsresize seems to support this point of view, although in fairness it is marked as [citation needed]!) I can understand a certain amount of healthy skepticism (in many cases bad sectors are a legitimate sign of a dying hard drive), but there seems to be a certain amount of… I don’t know, denial – for lack of a better word – going on with respect to bad sectors that aren’t actually all that “bad.”

If your hard drive develops a bad sector (as a result of a sudden power loss situation, for example – which is what caused my bad sectors), CHKDSK for Windows will find the problem, recover what data it can, and mark the sector as “bad” so it doesn’t get used again. Barring another power loss situation (fixed for me since I now have a UPS for my computer), the drive should be just fine for the rest of its natural life.

Likewise with defects that were detected by the manufacturer (but not bad enough to reject the disk over) and marked as “bad” before they left the factory. I know they used to do this with disks – I assume they still do.

So, it certainly seems like there are situations (possibly quite common) where a drive will have “bad” sectors, but should still be safe to use and operate on. After all, the fact that they were marked “bad” means that they were detected and won’t be used again.

Of course, I do have to mention again that ntfsresize has a --bad-sectors option which will ignore bad sectors… but there’s no way to access this option from the GParted GUI. You HAVE to do it from the command line – which kind of defeats the point. The whole wonderful thing about GParted in the first place is that it’s a graphical way to resize your disk partitions. I’m a geek, but even I don’t like to have to specify partition sizes by sector/cylinder offsets.

So, if you were to ask me, I’d say that either:

  • ntfsresize should be a little more forgiving regarding bad sectors; or
  • The GParted UI should detect the ntfsresize error and allow the user to proceed with the --bad-sectors option, obviously with a stern warning about making sure you’ve checked the disk thoughougly with CHKDSK or some other tool to make sure there are no further problems and the drive isn’t failing even more.

I know this post ended up being sort of just me whining – but I do wish that I could resize my disks with GParted. I like GParted – I think it’s a great tool – but, unfortunately, it’s just not a tool I can use anymore.

If anyone has any tips or ideas on how I might be able to work around this limitation – or of perhaps another partition-resizing tool (free and/or open source preferred, of course!), I’d love to hear from you – feel free to speak up in the comments!

UPDATE: I’ve found a program called EASEUS Partition Manager – it’s free for the “home” edition. (But not open-source, unfortunately.) I’ll update with a new post if I’m able to resize my partition, but first I need to do a full backup, just in case!

UPDATE 2: Follow up article here – the news isn’t good, I’m afraid.

UPDATE 3: A very nice reader emailed me to point me to this solution from Unfinished Teleporter: Gparted won’t shrink an NTFS partition with a bad sector.

Basically, you create an executable bash script which adds the --bad-sectors option to the original ntfsresize program. You can see the steps in the article I linked above, or follow these general steps:

  1. Locate the ntfsresize executable (for the GParted live CD it will be in /usr/bin, for Parted Magic it is in /usr/sbin).
  2. Rename it to ntfsresize.orig.
  3. Create a new bash script at the same location named ntfsresize. (See below for what you should put in this script.)
  4. Use chmod to ensure the new script is executable (chmod 755 will do the trick).
  5. Run GParted as normal.  It will ignore the bad sector(s).

In the bash script itself, you’ll want to add these two lines:

exec ntfsresize.orig --bad-sectors "$@"

This will call the original ntfsresize that you renamed, tack on the --bad-sectors option, and then pass whatever other options GParted (or whatever you are using) called it with originally.

I haven’t been able to try this myself (I’ve long since upgraded to another, newer computer), but I’ve been told this works like a charm. So if you are having this same sort of problem, give this a try!

Of course, before doing this you should be sure you’ve backed up all your data, since this is technically overriding a fail-safe feature of ntfsresize.

Anyway, I hope someone finds this useful – and thanks again to that very nice reader who pointed out this solution to me!