Disable Logging in an Apache VirtualHost

VirtualHosts and logs are invaluable features of a web server. However, you may not always want to log things for every VirtualHost. If you simply comment out the logging commands of a VirtualHost, then transfers to and from the VH will be logged to the main (ie, parent) log file; commenting them does not disable logging for a VirtualHost.

If you want to disable logging for a VirtualHost, one option is to log to a file in a temporary directory that gets flushed regularly, but a better solution is instead to have it log to a non-existent file (nul in Windows, /dev/null in *nix/Mac), such as in the following—mixed example—commands:

<VirtualHost …>

ErrorLog nul
CustomLog "nul" common
CustomLog dev/nul referer
CustomLog "dev/nul" agent


Windows Installer Error 2203

After much testing, I have determined that the reason that I was experiencing problems installing drivers, software, or updates in Windows recently was because I had removed the user-level environment variables for TEMP and TMP even though they were still available via the system-level environment. Creating copies for the user environment fixed the problem (at least the installation problem, now there is the issue of redundant environment variables, but that’s not so bad).

Windows Screensavers Textures

Windows includes several built-in screensavers, including one that shows 3D text. In the settings dialog for the 3D text screensaver, you can select to have it render with a reflection or texture, thus giving it a metallic look. When you select either the reflection or texture settings, you can then specify a bitmap file to have Windows use that when rendering the 3D text. If you do not specify a bitmap, it still renders it with a texture using a built-in graphics file. Interestingly enough, even though the custom-text-dialog box defaults to only bitmap (.BMP) files, the built-in textures are actually JPEGs.

If you have ever wondered what they look like, you can see them by opening the screensaver file (ssText3d.scr) in a resource editor and looking in the JPG section. The two files look like this (they are identical in Windows XP and Windows 7):

Reflection texture from Windows’ 3D Text screensaver
The reflection texture has been used in some of the DirectX samples in the DirectX SDK and if I remember correctly, is a photo of the lobby at Microsoft.
Texture from Windows’ 3D Text screensaver
The generic texture looks an awful lot like those from some texture packs like Absolute Cross or Propaganda Tiles.

Fontographer on Windows XP with 1GB+ Ram

Macromedia Fontographer is one of the still few font editing applications there are. Unfortunately, it has barely been updated since the days of Windows 95; the focus has been on the Mac version, and even that has not been updated much.

Fontographer for Windows is a port of the Mac version and as such, it is less stable than native Windows programs, which is why it has not fared as well with newer hardware and operating systems. Running Fontographer on modern systems does not work well and can simply fail and exit the app or cause a catastrophic crash which can actually bring all of Windows down and require a hard reset.

There are two main problems with Fontographer on modern systems. The minor problem is that when the combined physical+virtual RAM exceeds 1.5GB, Fontographer complains that you do not have enough memory and quits. This is because it uses smaller pointers which overflow and look like there is a minuscule amount of RAM.

The solution to this problem (if practical) is to reduce the amount of virtual RAM so that the total memory is less than 1.5GB. Of course this won’t help if you have more than 1.5GB of physical RAM and you would have to actually pull some out for the one program. This problem has been around for a long time but there do not seem to be any plans to fix it. Another option is to add enough RAM to the system so that the wrapped available RAM meets Fontographer’s requirements (in other words, ACTUAL_RAM_SIZE mod RAM_POINTER_LIMIT_SIZE >= FONTOGRAPHER_MINIMUM_RAM); surely it can’t need too much (depending on the version, it needs 6-16 megabytes).

The other problem that can occur with Fontographer on modern systems is a complete crash. When run, Fontographer can completely freeze Windows in it’s tracks and require pressing the reset button on the case to bring the system back up. This is probably also caused by it’s memory allocation problems but may be caused by something else.

One thing to try with this that has had success is to run Fontographer in “compatibility mode”—this is available in Windows 2000 and up. Select the Fontographer executable (eg: “C:\Program Files\FOG41\FONTOG.EXE”) and bring up it’s properties dialog. Select the Compatibility tab and set it to run as Windows 95.

Fontographer should now work and allow you to create fonts in Windows.

Outlook Express Folder Compaction Error

If you get the following message for FOLDERS.DBX when trying to “compact all folders” in Outlook Express

The folder is currently in use by Outlook Express or by another application.

there is a simple solution. The error message is deceptive since the actual cause has nothing to do with being in use. The problem occurs when you try to compact all folders and not all folders are actually present on disk. This can happen if a .DBX file got deleted somehow (for example if you decided to save some space by deleting the .DBX files of empty folders.) When OE tries to compact, it checks the folders.dbx file to see what .DBX files to expect, and when it can’t find one, it complains with the inaccurate message above.

The fix is simple, just replace or recreate the files. The easiest way to do this is to simply open the missing folders in OE because it will automatically create a .DBX file if one does not exist.

If you do not know which ones are missing, you can click on “Local Folders”, press the * key on the keypad to expand all branches, then click on each and every folder—you could also use the Down key instead of clicking, but then you have to wait a second on each folder for OE to open them, clicking opens them instantaneously.

After you’ve ensured that all .DBX files exist, you can successfully compact all folders.

Registry Cleaners/Repairers: Caveat Usurpator

The registry is where Windows keeps most of it’s settings. It is also where most programs keep their settings. Ever since it was introduced in Windows 95, it has been a mysterious place where some people have dared to venture in the hopes of finding computing treasure. There are all kinds of articles on how and where to make modifications and tweaks to improve system performance, increase stability, add new features, and other enhancements to the OS.

One aspect of the registry that has been popular is the concept of cleaning or repairing it. The idea that it can get cluttered with traces of old, uninstalled programs, invalid file references, corruption, and manipulation by nasty programs, and that cleaning these out and repairing them, will help a system run better. There is of course truth in this, and making sure that the registry is free of debris is certainly a good thing. Unfortunately, doing so requires some skill and more patience than even the best of us have. It is now a vast storage with more entries than there are stars in the sky. A proper audit would take far too long. As a result, numerous programs have been written to help automate this process. They scan the registry for what they consider to be problems and list them for the user, eager to delete them. Unfortunately, few if any such programs does the job adequately or even properly. Most of them do little more than look for references to files that do not exist. Some will check other components as well, but searching for missing files tends to be the most popular function of these programs.

Modifying the registry is not always as hazardous as some would have you believe. There are plenty of changes that can be done or undone safely. Of course there are some which can make it extremely difficult to fix and can potentially require reinstalling the OS. Making changes to entries without noting what the previous value was, or deleting entries altogether, is an irreparable operation and so must be done carefully. The better cleaner/repair tools will allow you to back up the entries they modify before altering them, but some do not; be vary wary of these.

Another thing to look out for when using a registry cleaner/repair utility is whether or not it provides detailed explanations of the entries it deems problematic. If all it gives is a one-line reason (eg: missing file/invalid entry/etc) or says nothing at all, then you should be extremely careful. A proper utility will give you the option of viewing a thorough explanation of why they flagged an entry as being bad, and what it means. That way you can examine it and determine if it really is a problem or not.

The vast majority of these registry fixing applications return more false positives than they do genuine items to fix. There are numerous reasons why they can report a false positive:

MRUsA lot of apps keep track of files that have been opened with them and often the file no longer exists because they were temporary, moved, renamed, etc. So when the cleaner checks the MRU, it sees a file reference but the file is not there, so it complains.
Variables in filenamesMost of these types of apps are not capable of handling filenames that have variables in their path. For example while %systemroot%\explorer.exe is an existing file, the cleaner will nag that it can’t find it.
Other types of unsupported file pathThese apps usually only support simple filepahts (eg: c:\folder\file.exe) so they choke on other types of filenames like network paths (eg: “\\somecomputer\folder\file.exe”). Services often use this format: “\??\c:\myservice\service.sys” which they can’t read. URLs are another that can’t be checked by them. Some may, but most don’t support relative paths: “system32\blah.exe”.
Empty keysWhen some cleaners find an empty key(s) they figure that it’s just residue from an uninstalled program, and thus obsolete. This may be the case but no necessarily. It could just be that the app has not yet been run since installation, that the app hasn’t had reason to write to it yet, or that it uses the key itself as data: perhaps keeping a version number in the keyname, or using the fact that the key exists at all to indicate that the app is installed. Obviously removing it even though it’s empty, would mess things up.
Hidden/system files/folderSome of these apps are unable to determine if a file or folder exists if it is a hidden or system file/folder even if it does.
Special formatSome programs have entries that are in their own special format (eg: “something”=”c:\blah|The Blah Game|3|always”). These apps won’t be able to parse the value and identify just the file/folder part. (They should not be messing around with things they can’t handle anyway.)
Temp filesThere are often traces of temporary files, Internet caches, etc. left behind for a while. For example a browser may keep a list of it’s temporary files. When the user clears them out, they are still listed until the browser overwrites them with new entries, so the cleaner nags. Of course if the use cleared them through the browser, it should have wiped them from the registry as well, but the user may have manually cleared them or use another tool. In this case it’s perfectly fine since they are temp files, but the registry entries are still there. And, since the cleaner can’t tell the difference between an important file and a temp file, it complains about all.
Icon indexesPlain icon files (icon.ico) have a single icon while DLLs, ICLs, EXEs, and such may have more than one. In this case the specific icon inside is indicated in this manner: “c:\folder\icons.dll,32”. This means that the target is the 32nd icon in the file icons.dll. Almost all of these cleaners are unable to handle this and can’t find the file.

As you can see, the results from these apps are not very reliably and you should be wary of what they report. Not all of the entries they flag will be problems so you should examine them before making any changes. You should be aware that even if you run these programs immediately after a fresh installation of Windows, they will find quite a lot of things to complain about.

That’s not to say that you should not use these programs at all; they definitely have their use, just be careful. The best advice is to limit yourself to items you know for sure are incorrect, such as those for a program you have uninstalled, or for a file you deleted. If you are unsure about something, leave it be at least until after you have looked it up, and always make a backup (export a .REG file) so that you can recover from any mistakes.