SQL Server 2005 Express Edition

According to Microsoft “SQL Server Express is a version of SQL Server 2005 designed to helps developers build robust and reliable applications by providing a powerful database that is also free and easy to use.”

I know nothing about SQL Server, except that there is a free cut-down version called the Microsoft database engine (MSDE), used by many products where a full-blown SQL Server installation would be overkill.

With SQL Server 2005 Express Edition (the replacement for MSDE), Microsoft have made some changes in the packaging and promotion of the product – it’s better in some ways, but more limited in others. It also has a partner product – Microsoft SQL Server 2005 Express Manager, which can be used for database administration (including existing SQL Server 2000 and MSDE installations).

You can read more about SQL Server 2005 Express Edition, including a comparison with MSDE and links for download on Mat Stephen’s weblog (Mat is one of the Microsoft UK IT Evangelists).

Battle spammers with Outlook’s tracking options

I just came across a top tip on the Microsoft website to stop spammers from verifying your e-mail address using a read/delivery receipt.

Basically, it involves enabling the tracking option to “ask me before sending a response”. That way you can tell when someone has attempted to validate your e-mail address – I had thought that sending a fake non-delivery report (NDR) would be enough but it seems without this setting I could also have been sending a read receipt without realising it when I deleted the spam.

Even more problems with a Dell Latitude D600

I’ve decided that the notebook PC that I use for work must have been built on a Friday afternoon (or a Monday morning). Over the last five months it has had a replacement motherboard (3 weeks, 4 engineer visits, 2 no-shows before the PC was fixed), a replacement hard disk, and last week the battery had to be replaced. Sure enough, Dell replaced all of these parts under warranty, but it doesn’t say much for the build quality of the equipment.

Why some middleware should be bundled with the operating system

Anti-trust laws are supposed to protect consumers from monopolistic companies. As such, it is hardly surprising that Microsoft regularly finds itself in court facing yet another anti-trust suit, but the latest move by the US government concerns me greatly.

I have a licensed version of Windows XP Professional on my laptop, so I’m not bothered by the Windows Genuine Advantage program, whereby users have to prove that their copy of Windows is legitimate before downloading additional software.

According to the Windows IT Pro magazine network WinInfo Daily Update:

“Windows Genuine Advantage is designed to reward owners of non-pirated Windows copies with value-added advantages for being legitimate customers. Like Product Activation, Windows Genuine Advantage seeks to curb software piracy, which various analyst groups say is rampant around the world. IDC reports that software piracy is a $30 billion problem, with pirated software accounting for about 30 percent of all software used worldwide; in the United States, that figure is 23 percent.”

After all, Microsoft is facing competition in areas where it has previously dominated (desktop and low-mid range server operating systems, office productivity suites) and it needs to protect its revenues whilst not being seen as anti-competitive. As such, users need to see that they get something back – additional functionality for example, which is where my anti-trust worries come into play.

Last week, federal regulators at the US Department of Justice (DOJ) revealed that they will soon begin an investigation of the next version of Windows (codenamed Longhorn) to ensure that it doesn’t violate the terms of Microsoft’s US antitrust settlement. The DOJ are also voicing concerns about Windows XP Service Pack 2 (SP2), claiming that they require further information from Microsoft in order to determine whether Windows satisfactorily honours user middleware choices.

SP2 is a massive security update, but it does include some new functionality – most significantly a much improved Windows Firewall. That may or may not be considered middleware, but we can’t continue to lampoon Microsoft for security flaws at the same time as stopping them from shipping security features within the operating system. On the same level, we should expect anti-malware functionality too, and for that matter, anti-spam capabilities in Exchange. These features are all being implemented, but if the DOJ (and the European Union) get their way, Microsoft will be severely limited in what it can ship to its legitimate, paying customers.

In the same way that many of the infrastructure deployment techniques that I have practised for years are now viewed as commodities and my company has to find new areas in which to add value, so are some of the software products which Microsoft is criticised for bundling within Windows (browser, firewall, etc.). Or to take another example, who would consider an operating system without a TCP/IP stack today? (something which once upon a time was an added extra with an associated cost). Those who have built a business around such commodities must find new areas in which to innovate, and leave Messrs Gates, Torvalds, and Jobs to include what have become basic system requirements in their operating systems.

Troubleshooting an MS-DOS application which hangs the NTVDM subsystem in Windows XP and Windows Server 2003

I’ve been working on an intriguing (and frustrating) issue for a few weeks now and a couple of days back we finally resolved the issue.

My client has an MS-DOS (FoxPro 2.6a database) application running within an NTVDM on Windows XP. Every now and then, the application will hang – seemingly randomly. Windows XP did have service pack 2 applied, but the issue also occurs on service pack 1 PCs (I didn’t try the RTM version). Only the application hangs – it is possible to terminate the NTVDM process and carry on working as normally.

Normal actions for troubleshooting MS-DOS applications in Windows XP were not helping to resolve the issue, but the software vendor managed to narrow the issue down to FoxPro waiting for input. Occasionally, the input does not timeout and return control to the calling program – it seems that this is the root cause of the NTVDM hang. Identifying this allowed them to construct a test program which polled for input, timing out every few seconds and would reliably hang an NTVDM at a seemingly random time, but always within an hour.

Using their test program on a variety of PCs, the software vendor found that the problem was related to the Intel hyper-threading technology (my client has standardised on a version of the IBM ThinkCentre M50 which includes a single 3GHz Intel Pentium 4 processor with HT technology). Whilst disabling hyper-threading is unlikely to result in any significant performance degradation (hyper-threading only provides an average 10-20% performance gain as most applications do not fit completely with the hyper-threading model), it was still considered by IBM, Microsoft, my client and myself as a tactical workaround, rather than a strategic fix.

After seeking advice from Microsoft, I ran the test program on a Compaq ProLiant DL380 G2 server with two Pentium III 1.26GHz processors and found that the issue is not limited to Windows XP and hyper-threading, but to both Windows XP and Windows Server 2003 when running with an ACPI Multiprocessor PC HAL. Turning off hyper-threading on the PCs was no longer good enough as we can expect to see multiple processor cores constructed on a single die in the near future, leading to a rise in the use of multi-threaded applications (the logical processor provided by the hyper-threading technology in the Intel Pentium 4 processor is simply a precursor to this).

So why does an MS-DOS application running within an NTVDM on a 32-bit version of Windows use multiple processors? The answer it seems is that although the MS-DOS application is not multi-threaded, modern versions of Windows are, and can allocate parts of the NTVDM process to any available processor. With that in mind we re-ran the test program with processor affinity set to use only CPU0 in Task Manager. The results were the same as disabling hyper-threading – no NTVDM hang! Obviously, setting processor affinity manually is not sustainable outside the test environment, and short of running the application on Windows Server 2003 Enterprise Edition (with the Windows System Resource Monitor to control processor affinity) we needed to find an alternative solution.

That solution came in the form of the imagecfg.exe tool provided with the Microsoft Windows 2000 Resource Kit (supplement one). This can be used to edit an executable file and permanently set the processor affinity for a given application:

Using the imagecfg -a 0x1 c:\windows\system32\ntvdm.exe command did the trick, although Windows File Protection/System File Checker quickly restored the original ntvdm.exe file so I needed to perform this on a copy of ntvdm.exe in a temporary folder, and then overwrite both c:\windows\system32\ntvdm.exe and c:\windows\system32\dllcache\ntvdm.exe.

Once updated, the NTVDM process runs on CPU0. Of course, this limits all programs under the control of the NTVDM subsystem but it is far more preferable to disabling logical or physical processors in the BIOS; however, as this is a change to an operating system file, it must be considered alongside the implementation of any service packs and/or hotfixes from now on. Reversing the change is simply a case of restoring the original ntvdm.exe file.

Batch file command reference

Even though modern versions of Windows have rich scripting capabilities I regularly find myself writing batch (.bat) or command (.cmd) files for automating system tasks, sometimes during migrations from older versions of MS-DOS or Windows which do not have the same command set. I generally consider my batch file writing skills to be pretty good, but I have found the Computer Hope Batch File Help website to be a useful resource for checking syntax between different operating system versions.

Gartner’s top predictions for 2005 and beyond

I’ve been reading Gartner’s top predictions for 2005 and beyond.

Some of the predictions, make interesting reading, for example the rise in “microcommerce” opportunities and the prediction that “by 2009, counterfeit reality will account for at least one major media and political scandal” (scary when translated into real-world connotations).

Of more interest to me directly are the predictions that:

  • “Cyberattacks against software flaws will double by 2006” (although Gartner note that attacks against misconfigured software will actually decrease because vendors are beginning to ship software with more secure default configurations).
  • “By 2007, three of the top 10 PC vendors will exit the market” (IBM have already sold their PC business since the original Gartner research note was written in November 2004).
  • “By 2008, the technological differences between PCs, mobile devices, e-books, TVs and cellular phones will be eradicated”.
  • “By 2015, 40% of today’s IT job roles will be lost to automation”.

If that last prediction is correct, it looks like I’d better start thinking about retraining as a plumber/electrician/builder…

Discovering unknown devices in Windows

Whilst developing my unattended Windows XP build, I came across a number of devices that were not automatically detected by Windows.

Sometimes, right-clicking the unknown device in Device Manager and selecting the Update driver… option allowed Windows Update to connect to the Internet and locate updated drivers (which in turn identified the device and allowed me to download and integrate the OEM drivers into the Windows XP installation source).

On other occasions it was not so simple, and I needed to do some research to identify the device using the PCI device instance ID (found on the details page of the device properties).

A couple of years back I was introduced to Craig Hart’s PCI and AGP bus sniffer. I could have just run the utility, but in this case I chose to search its companion file (pcidevs.txt) for the vendor and device PCI IDs. Using this technique, I was able to identify my unknown device as the Broadcom (vendor 14E4) BCM4306 802.11g Wireless NIC (device 4320), which is also known as a Dell Wireless 1350. Once I had that information, all that was required was to download the drivers for integration.

Make your own iPod advert

I confess.

I don’t own an iPod.

I think they look great, but I just don’t need one (and I have concerns about the use of Apple’s proprietary AAC media format).

I like technology.

I am also a photographer, which makes me passionate about some of the fantastic images I see around me every day – like some of those featured in advertisements – and I think the silhouetted Apple iPod ads are cool.

Now there is iPod My Photo, which lets you turn any image into a mock iPod advert. You can choose one of 5 background colours, add a caption, and optionally add an iPod into the photo. Look closely and they’re not just 2-tone – check out the samples to see the shadow details etc.

All I need to do is select the right photo…

Microsoft’s new malware removal and anti-spyware products

This week, alongside the January security updates, Microsoft released the first version of its malware removal tool, called the Microsoft Windows Malicious Software Removal Tool (MSRT). New versions will be released on the second Tuesday of each month (with the monthly security updates) and each version will be cumulative.

Note that this is not the Microsoft Windows AntiSpyware tool (a separate beta of that product was released last week, based on the anti-spyware application gained in the purchase of Giant Company), nor is it an anti-virus tool – MSRT is simply a rollup of all the malware removal utilities that Microsoft has previously released.