Windows Is Depressing

Ok, here’s a super odd bug on Windows. I started getting a bunch of errors in various programs.

CoolTerm said: “Runtime Error” with “Failure Condition: mutex.mLockFile”

CoolTerm error

Process Explorer complained that it was “Unable to extract 64-bit image. Run Process Explorer from writeable directory.”

Process Explorer Error

This of course didn’t make sense, as the program was in a writeable folder, but then it dawned on me that both of these programs could be trying to use my account’s TEMP folder.

So, I’m super annoyed. Somehow my user account’s TEMP folder got wiped out, and replaced as a file instead, which obviously can’t contain more files.

Temp folder is a file now?

The solution in this case was to erase the Temp file and create a new TEMP folder. But it is insane to me that all the programs that rely on a writeable TEMP folder would give such terrible hints that this was the problem’s source. It also would be awesome if Windows would autorepair this condition at startup.

Windows 7’s Updater Sucks

I reinstalled Windows 7 from a recovery disc recently and have had to suffer through the seemingly drawn-out process of applying all the patches via Windows Update. After failing to install Service Pack 1 for Windows 7 a number of times, the Service Pack installation finally succeeded, and I was then greeted with the option to install 164 other patches.

Seriously? I wish Microsoft could figure out a way to slipstream the install, or just do like Apple does and download the latest operating system image before doing a clean install*. There has to be a way for them to know what the state of the system should be, given patches X, Y, and Z (to infinity) have been applied. Maybe they could treat the Windows system directory as a super-secret / protected storage area that they can just update bitwise with binary diffs (you know, like real firmware). Maybe they should stop differentiating their operating system features so much and just unify them into 2 versions with no subversions (Home and Business). It’d certainly make it easier to unify what the operating system actually needs to install.

And if they still can’t do this, if they still can’t override the inertia of useless business units and middle management (seriously, who came up with Windows Home Premium versus Ultimate, and why? What benefit was it to all users to sell a crappier version of your OS, en masse? The incremental price for one additional unit of software is what, exactly?), they should get one of their people at Microsoft Research to figure this out. It’s only a few million man hours per year of wasted time at stake.

What an utter waste of bandwidth and time, not to mention the wear and tear on the hard disks of the world.

updater-2

As it chugged through the 164 patches, I also noticed that the memory usage on my system seemed to be rising inexorably.

And wouldn’t you know it, Process Explorer told me this:

updater-1

That’s right. The Trusted Installer component felt the need to consume over 4 gigabytes of memory during the update process. Why? I have no idea, but screw you for asking! Seriously, does nobody test this stuff in Redmond?

Thank goodness my system has 8GB of RAM, or who knows how badly the system would be swapping right now.

Update

And of course, right after I finish that big batch of updates, after the next reboot, Windows Update tells me I have 21 more:

updater-3

I feel like I’m living Zeno’s Paradox. It’s a mathematical certainty that I will reach my goal, but from the halfway point it certainly doesn’t feel like it.

*I know, I know, I’m not a huge fan of Apple’s Software Update system either, why they can’t do binary diffs like Google or JetBrains can, doesn’t make sense to me.

Windows 7 Not At Fault

Damn it, not again. So Windows 7 started bluescreening immediately at boot, before I was even logged into my normal user account. Reason? Turns out my solid state disk is hosed. I’m not happy, but I’m also not surprised.

I’d bought two OCZ Vertex 2’s sometime in 2010, and not put all too many bytes onto them over the past four years. One of them had already died some years back, but I was too lazy to call in the warranty service. Now the second drive has died, and both of them are out of warranty! Booo. I thought they had 5 years, but turns out it was only 3. Oh well.

I put a copy of Ubuntu Linux onto a USB stick and booted off of it to see if there were any kernel messages reminiscent of what I’d seen a few years back. Sure enough, ad infinitum:

[...]
[   45.391281] sd 0:0:0:0: [sda]  
[   45.391282] Add. Sense: No additional sense information
[   45.391284] sd 0:0:0:0: [sda] CDB: 
[   45.391284] Write(10): 2a 00 00 60 d1 a8 00 00 a8 00
[   45.391339] sd 0:0:0:0: [sda]  
[   45.391340] Result: hostbyte=DID_OK driverbyte=DRIVER_SENSE
[   45.391342] sd 0:0:0:0: [sda]  
[   45.391342] Sense Key : Aborted Command [current] [descriptor]
[   45.391344] Descriptor sense data with sense descriptors (in hex):
[   45.391344]         72 0b 00 00 00 00 00 0c 00 0a 80 00 00 00 00 00 
[   45.391349]         00 60 d6 40 
[...]

And:

[   45.392104] ata1: EH complete
[   45.392338] ata1.00: exception Emask 0x50 SAct 0x7fffffff SErr 0x400801 action 0x6 frozen
[   45.392339] ata1.00: irq_stat 0x0c000000, interface fatal error
[   45.392341] ata1: SError: { RecovData HostInt Handshk }
[   45.392343] ata1.00: failed command: WRITE FPDMA QUEUED
[   45.392346] ata1.00: cmd 61/a8:00:78:dd:60/00:00:00:00:00/40 tag 0 ncq 86016 out
[   45.392346]          res 50/00:e8:40:d6:60/00:00:00:00:00/40 Emask 0x50 (ATA bus error)
[   45.392347] ata1.00: status: { DRDY }
[   45.392348] ata1.00: failed command: WRITE FPDMA QUEUED
[   45.392351] ata1.00: cmd 61/a8:08:d0:dc:60/00:00:00:00:00/40 tag 1 ncq 86016 out
[   45.392351]          res 50/00:e8:40:d6:60/00:00:00:00:00/40 Emask 0x50 (ATA bus error)
[   45.392353] ata1.00: status: { DRDY }
[   45.392354] ata1.00: failed command: WRITE FPDMA QUEUED
[   45.392357] ata1.00: cmd 61/a8:10:28:dc:60/00:00:00:00:00/40 tag 2 ncq 86016 out
[   45.392357]          res 50/00:e8:40:d6:60/00:00:00:00:00/40 Emask 0x50 (ATA bus error)
[   45.392358] ata1.00: status: { DRDY }
[   45.392359] ata1.00: failed command: WRITE FPDMA QUEUED
[   45.392362] ata1.00: cmd 61/a8:18:80:db:60/00:00:00:00:00/40 tag 3 ncq 86016 out
[   45.392362]          res 50/00:e8:40:d6:60/00:00:00:00:00/40 Emask 0x50 (ATA bus error)

So I guess I need a new hard drive. Lame.

Windows 7 Getting Me Angry

I’m not sure how it’s still possible in 2014, but, between yesterday and today I changed nothing on my computer and now it is blue-screening every time I log in or shortly after I log in. No hardware changes were made. The only thing I changed (but which seemed to work fine) was to activate Hibernation, by setting a multi-gigabyte hiberfil.sys file, and disabling the “Hybrid sleep” function on Windows 7.

So I went ahead and uninstalled a bunch of things I’d been meaning to clean up (but which didn’t seem to be the source of the crash, since it’s still crashing). I really don’t know what could have changed overnight, but it’s already a huge time suck.

Even after I ran the various uninstallers, a bunch of leftover executables and other garbage are still running on my system, and which I am currently attempting to root out, with the help of AutoRuns, a tool from the Sysinternals gurus. AutoRuns shows all of the various places where a executable (or shell extension DLL, or etc) code is invoked by Windows.

So far, the code that is autostarting that I don’t want to run at all anymore looks like this:

SPIRunE                        SPIRun Endpoints Dynamic Link Library                                            Creative Technology Ltd.        c:\windows\syswow64\spirune.dll             5/9/2007 3:07 AM
AMD External Events Utility    AMD External Events Service Module                                               AMD                             c:\windows\system32\atiesrxx.exe            4/20/2011 4:04 AM
amdkmdag                       ATI Radeon Kernel Mode Driver                                                    ATI Technologies Inc.           c:\windows\system32\drivers\atikmdag.sys    4/20/2011 3:53 AM
amdkmdap                       AMD multi-vendor Miniport Driver                                                 Advanced Micro Devices, Inc.    c:\windows\system32\drivers\atikmpag.sys    4/20/2011 3:22 AM
amdsata                        AHCI 1.2 Device Driver                                                           Advanced Micro Devices	        c:\windows\system32\drivers\amdsata.sys     3/19/2010 2:45 AM
amdsbs                         AMD Technology AHCI Compatible Controller Driver for Windows - AMD64 platform    AMD Technologies Inc.           c:\windows\system32\drivers\amdsbs.sys      3/20/2009 8:36 PM
amdxata                        Storage Filter Driver                                                            Advanced Micro Devices          c:\windows\system32\drivers\amdxata.sys     3/19/2010 6:18 PM
AODDriver4.2.0                 File not found: C:\Program Files\ATI Technologies\ATI.ACE\Fuel\amd64\AODDriver2.sys

These are all old support drivers and executables from AMD/ATI and Creative Labs. I did once have a Radeon video card in the system, which I replaced with a much more powerful Nvidia card. Frankly, if AMD can’t get their driver development, updating, and cleanup code in order, they should stop making graphics cards. There’s so much extra crap they install (Catalyst Control Center anyone?) but don’t maintain, that it’s very frustrating being left with this crap on my system when I clearly want it gone. Same goes for Creative Labs, talk about a company that makes it a pain in the ass to get new drivers. It’s been like that as long a I can remember.

I probably should not have swapped video cards between manufacturers like that, but come on. Again, it’s 2014, and this is disappointing if this stuff is getting through the Windows hardware certifications. Nvidia’s software also has plenty of bloat which can be cleaned up (which I also just did), but at least they have a fairly regular update schedule and solid support for their older graphics cards too.

Basically, I’m disabling all the drivers except what I think is actually in the system.

Here’s what the AutoRuns Drivers tab looks like after I finished disabling things. These are all drivers that the Windows bootloader will attempt to load when Windows is starting up. You’ve probably seen this list of files when starting Windows in Safe Mode. The thing is, most of this hardware either doesn’t exist anymore, or never existed in widespread use on desktop PCs. So why is Windows checking for it, anymore? Some of those devices are for high-end server systems, with Fibre Channel or SAS connections, but seriously, this code runs on all of the desktops in the world, so who knows how many million seconds are wasted because of these checks? If someone wants to run server-grade hardware on their home computer, let them, but make sure it doesn’t slow everyone else’s boot process down.

autoruns

Turns out after I disabled all those extra drivers, the system both a) boots faster and b) seems to run more smoothly. No more crashes, no more extra crap getting started in the background. So I’m happy.

But one other thing I noticed, before I go: Why the hell isn’t the Microsoft Windows Defender DLL “mpsvc.dll” a signed binary?