XP Mode (Windows Virtual PC for Windows 7) no longer requires hardware virtualisation - hurrah !

Windows Virtual PC (aka XP Mode)

When XP Mode was released, it insisted on hardware virtualisation being present on your CPU and enabled in the BIOS.  Given that Windows Virtual PC was based on an improved Virtual PC 2007, which provided hardware virtualisation as a user selectable option, I did wonder why on earth Microsoft thought this was a good idea. 

Not only do many people not have a CPU with hardware virtualisation support, some manufacturers don't provide a BIOS option to enable this setting, especially on laptops - yes Sony, Toshiba and Acer, I'm looking at you.

Dumb and dumber

This issue became a double whammy; not only was Microsoft a bit dumb on not supporting Windows Virtual PC without hardware virtualisation, your hardware manufacturer was also dumb in not supporting the option in the BIOS.

Microsoft update to Windows Virtual PC

Belatedly, Microsoft has seen the problem with this hardware virtualisation requirement and has now released a new version of Windows Virtual PC that works without hardware virtualisation.  This is really good news for those with older (or limited) CPUs and rubbish BIOS firmware.

You can details of how to download the new versions of XP Mode here,

http://blogs.msdn.com/virtual_pc_guy/archive/2010/03/18/windows-virtual-pc-no-hardware-virtualization-update-now-available-for-download.aspx

And there is also an explanation of why the hardware virtualisation requirement was in place for previous releases,

http://blogs.msdn.com/virtual_pc_guy/archive/2010/03/18/windows-virtual-pc-now-without-the-need-for-hardware-virtualization.aspx

 

Thanks to NxtGenUG Manchester - Hyper-V for Developers presentation now available for download

Thanks to Steve and Andy at NxtGenUG Manchester for making me very welcome and for the guys who didn't head down the pub for a Guinness for St Patrick's Day and came to NxtGen instead.  I hope you all got something from the presentation, if not technical insights, at least a can of Guinness of Tunnocks caramel wafer as swag.

As promised here is the presentation in both PowerPoint and Adobe PDF format (with speaker notes),

http://www.tigernews.co.uk/blog-twickers/nxtgenugmanc/hyperv4devs-ppt.zip

http://www.tigernews.co.uk/blog-twickers/nxtgenugmanc/hyperv4devs-pdf.zip

Since I gave the presentation Microsoft has released XP Mode (Windows Virtual PC for use under Windows 7) without the requirement for hardware virtualisation. Read more about that here, http://blogs.msdn.com/Virtual_PC_Guy/

For anyone who has seen this presentation at other user groups, there is a new section at the end of the presentation dealing with the various networking configurations under Hyper-V; not connected, private network, internal network and external network.  This includes details of what these mean, and a Venn diagram to aid understanding of the implications.

Running Remote Desktop Connection client (mstsc.exe) from inside Hyper-V Server 2008 R2

One of the annoying absences in Hyper-V Server 2008 is the lack of a remote desktop connection client (mstsc.exe).  This is due to the (welcome) reduction in clutter within Server 2008 Core, on which Hyper-V Server is based. 

However, a remote connection client allows you to logon at a Hyper-V server console and then remote connect to the virtual machines directly which can be quite useful.  

Thanks to this blog by Jason Huitt, http://jasonhuitt.com/blog/post/Server-Core-2008-No-Built-In-MSTSC.aspx, I discovered it's just a matter of copying the relevant files from a matching Windows Server 2008 installation.  In my case I copied the files from Windows Server 2008 R2, and had to include an additional file msacm32.dll which wasn't listed on Jason's blog.

  • \Windows\System32\mstsc.exe
  • \Windows\System32\mstscax.dll
  • \Windows\System32\msacm32.dll
  • \Windows\System32\en-US\mstsc.exe.mui
  • \Windows\System32\en-US\mstscax.dll.mui

Once you install these files into the relevant folders in your \Windows area on your Hyper-V Server you can just use the command line to run mstsc.exe and you can start to connecting to all the virtual machines on which you have enabled remote connection.  Great if your VMs are running on an internal network not visible outside the Hyper-V host.

Hyper-V for Developers presentation - GL.NET, Gloucester

Thanks to Jimmy Skowronski and the guys at Gloucester.NET user group for inviting me over to give my Hyper-V for Developers talk.  Additional thanks to Marc Gravell for giving me a lift from Gloucester town to Symantec (kindly providing facilities) and for DevExpress for supplying the pizzas for tonights user group.

As promised, here are the slides to download as either PDF or PowerPoint,

  http://www.tigernews.co.uk/blog-twickers/glnet/Hyperv4Devs-PDF.zip

  http://www.tigernews.co.uk/blog-twickers/glnet/Hyperv4Devs-PPT.zip

I really enjoyed the chance to talk for 90 minutes, rather than usual 60 mintues I'm used to as it gave the topic time to breathe as well as discuss Hyper-V features with experienced VMWare ESX users.  Good to learn more stuff about the VMWare products.

Thanks

Liam

UPDATE 18 February 2010 : Following Greg's question regarding Type 1 / Type 2 categorisation (see below) I thought I'd post a direct link to the free PDF eBook, Understanding Microsoft Virtualization R2 Solutions, which you can download from here.

Hyper-V for Developers - UK tour dates

For those who would like to know when I'll be presenting my Hyper-V for Developers talk around the UK, to see if they can pop in, here's the latest dates (always subject to change),

13th August 2009   DevEvening, Woking
16th September 2009   Edge UG, London
14th January 2010   NxtGenUG, Southampton
      
17th February 2010  

GL.Net, Gloucester (details)

17th March 2010   NxtGenUG, Manchester (details)
25th March 2010   .Net Developers Network, Bristol (details)
     
8th May 2010   DDD Scotland (if voted in, vote here)
     
13th May 2010   VBUG, Bracknell (details tbc here)
9th June 2010   NxtGenUG, Oxford (details)
15th July 2010   North East Bytes, Newcastle-Upon-Tyne (details tbc here)

Phew! That's nearly a 12 month tour, but the eagle eyed may have spotted that April is free at the moment.  So if any UK user group thinks they have members who haven't seen my Hyper-V presentation, and meets on a Thursday (or every other Wednesday) then drop me a line and we'll see what we can arrange.

Using Gnome Partition Editor (GParted) to transfer Windows Server 2008 R2 and Hyper-V Server R2 images to different drive; but you'll need a Windows 7 Recovery Disc to actually get it to boot

UPDATE 15 February 2010 : See Virtual PC Guy's Blog here for a crucial item of information about the Windows Startup repair not restoring the Hyper-V service as an automated service.  Basically once you reboot, although the o/s loads, you cannot run any virtual machines. To resolve this you should remote login to the Hyper-V Server (or direct for Windows Sever 2008 R2) and execute the following command; bcdedit /set hypervisorlaunchtype auto


I had recently successfully used Gnome Partition Editor (GParted) to resize some of my Virtual Machines running under VirtualBox (see http://www.my-guides.net/en/content/view/122/26/). So I decided that maybe it was time to use GParted on some real hard drive disk partitions.

I had freed up a larger hard drive for my Hyper-V laptop, so I used GParted to transfer the volumes from the original (internal eSata drive) to an external drive caddy (eSata drive, but connected via USB 2.0).  There were three volumes on the original drive; a 100Mb system boot partition, a 20Gb Hyper-V R2 partition and a 60Gb Windows Server 2008 R2 partition.

Using GParted from a USB key

A spare 'bingmaps' 2Gb USB thumbdrive boot the whole of GParted from a USB key, see http://gparted.sourceforge.net/liveusb.php. Nothing like a Microsoft freebie allowing me to run open source software.

Although the boot partition copied successfully, it looked like I couldn't copy the main NTFS partitions, as it kept failing.  However, that was just a case of needing to make the new partitions at least slightly bigger than the original. I had neglected to do this with the Hyper-V partition as I was trying to maximise my Windows Server 2008 R2 partition.  So, once the main partitions were successfully copied, I expectantly rebooted. The reboot failed. Back in GParted, I realised I'd forgotten to flag the 100Mb system boot partition on the new drive as a BOOT partition.

Bootmgr - you can't boot Vista, WIndows 7 or 2008 after using GParted

However, on rebooting, although I got to view the boot menu, selecting either operating system failed.  I encountered the issue mentioned in the blog that talked about resizing virtual machines; any operating system after Windows Vista uses the more modern Boot Manager (Bootmgr) rather than the old fashioned NTLOADER and BOOT.INI menu system.  This means both Hyper-V Server R2 and Windows Server 2008 R2 both refused to boot due to warnings about missing and/or corrupt files.

Using the standard Hyper-V R2 or Windows 2008 R2 install discs, and selecting the Repair Option turned out to be no help as there was is option to repair the boot options.  I searched and found, http://gparted-forum.surf4.info/viewtopic.php?id=13803, which mentioned a Windows Server 2008 Recovery Disk but what the hell was that, not something I could find elsewhere?  Another search found a superuser.com question, http://superuser.com/questions/47454/vista-server-2008-bootmgr-is-missing, and that gave away what was required; I definitely needed a recovery disk, possibly Vista, or better still, Windows 7.

Windows 7 recovery disk to the rescue

Before booting up Windows 7, I did check out a Windows Server 2008 R2 machine to see if it provided an option to create a recovery disk, it did not.  So it was off to my development laptop which runs Windows 7 (the workstation o/s that matches the 2008 R2 server release, like XP matches Server 2003 and Vista matches Server 2008). That did have an option to make a recovery disk.  Minutes later I booted my Hyper-V laptop from that newly created Windows 7 recovery CD, and unlike the Windows Server 2008 installation CDs, it immediately notified me of a boot manager issue and removed the 'old' entries, and created 'new' entries for the Windows installations it had found on the drive.

After a reboot the only difference was that the menu now had '(recovered)' on the end of my boot menu options, but apart from that everything working exactly as before on the new drive.  A quick use of the utility bcedit (http://msdn.microsoft.com/en-us/library/ms791534.aspx) had my boot menu friendly descriptions back to normal.

So, in my 'it pro' toolbox there is now a USB thumb drive ready to run GParted, and a Windows 7 recovery CD to fix any boot manager issues that it might cause.

Step by Step: Trac on Windows, how to install a brand new SubVersion and Trac installation onto a Windows System

What is Trac and why would you want it?

I have already documented in a previous blog how I restored my Trac backup from hosted-projects.com (see http://geekswithblogs.net/twickers/archive/2010/02/02/137766.aspx) but given I also mentioned my use of Trac in a recent presentation at the .NET developers conference, DDD8, (see http://geekswithblogs.net/twickers/archive/2010/01/30/137718.aspx) I thought it only proper to document how to install both SubVersion and Trac from scratch on a new Windows system.

I believe Trac excels as an easy to use, lightweight project management system that is well suited to a small development team (compared to TFS).  It benefits from the tight integration of a mature source code management system (SubVersion) with project management.  This allows check in comments to directly link to work items, a wiki that can easily refer to work items or source code branches and provides a full web interface for SubVersion.

Trac is an open source issue tracking system, written in Python, with both command line and web interfaces and you can find out more about it here, http://trac.edgewall.org/

The following installation notes were made on Windows 7 Ultimate 64 bit running under VirtualBox 3.1.2.  All the software components installed are 32 bit versions (necessary, as not all components have 64 bit setup files readily available).

Documentation available for installation of Trac on Windows

The general installation instructions for Windows can be found at, http://trac.edgewall.org/wiki/TracOnWindows,

More importantly there are incredibly useful step by step instructions at, http://trac.edgewall.org/attachment/wiki/TracOnWindows/Step_by_Step-installation-manual.txt

These instructions provided a great starting basis for the installation, although they do assume some knowledge of SubVersion and Trac, and don’t include details of how to configure initial permissions or run Trac as a Windows service that starts automatically with the operating system.

SubVersion

The most likely server installation for Windows users will be VisualSVN Server (you can download it from here, http://www.visualsvn.com/).  I do realise that I may be annoying open source purists by recommending VisualSVN Server, rather than using completely open source components via the svnserve.exe application that I remember configuring back in 2004.

In truth, VisualSVN Server is much easier to install, generates it's own SSL certificate for secure (https) repository access and presents an management utility via an MMC snap-in which is familiar to the average Windows user.  The basic version is also FREE.  So in these instructions I will use this to provide access to the SubVersion repository.

Installation order

I’m going to take a similar approach to my previous blog on restoring Trac, but if you’ve already read that, do pay attention, as we are adding in installation of VisualSVN Server and the creation and user configuration of the SubVersion repository.

The location of all the components is detailed in my previous blog post (http://geekswithblogs.net/twickers/archive/2010/02/02/137766.aspx) so I decided not to repeat them.  The only update is that this used the latest version of python that Trac can use, 2.6.4, with the corresponding 2.6 versions of setup tools and Genshi. 

The SubVersion components being installed are all based on SubVersion 1.6.6 as this matches the version contained in VisualSVN Server 2.1.  The setup includes all the SubVersion command line tools so if you are familiar with using them to create a repository and/or users feel free to skip the VisualSVN Server Manager steps.

  1. python-2.6.4.msi (install for all users)
  2. setuptools-0.6c11.win32-py2.6.exe (Run As Administrator)
  3. Genshi-0.5.1.win32-py2.6.exe (Run As Administrator)
  4. (reboot system)
  5. Add c:\Python26;C:\Python26\Scripts to path. (Windows 7, Control Panel -> System and Security -> System -> Advanced System Settings, Environment Variables button)
  6. Setup-Subversion-1.6.6.msi (install for all users)
  7. svn-python-1.6.6.win32-py2.6.exe (Run As Administrator)
  8. Create the root folders c:\svn (SubVersion) and c:\projects\trac (Trac installations)
  9. VisualSVN-Server-2.1.msi (subversion 1.6.6, using SubVersion authentication, repositories set to c:\svn) Visual SVN installation options
  10. Trac-0.11.6.win32.exe (Run As Administrator)
  11. Start the VisualSVN Server Manager (Start -> All Programs -> VisualSVN folder) and create a new user, ‘liam’ with password ‘4trac’.
  12. Still in VisualSVN Server Manager, right click on the Repositories root and click Create New Repository with the name NewRepo. Right click on the new repository, click Properties, and select the Security tab.  Add the new user ‘liam’ and provide that user with read/write permissions.Adding the new user
  13. Still in VisualSVN Server Manager, right click on the Repositories root, click Properties, and select the Security tab.  Remove Everyone (this should remove Everyone from all child repositories).  I prefer not to provide blanket access to all users to my source code respositiories.
  14. Creating a new Trac installation, beneath the root directory we created earlier, is performed from the command line; trac-admin c:\projects\trac\NewTrac initenv (this starts the setup wizard)
    1. Project Name set to NewTrac
    2. Database connection string, hit Enter for default
    3. Repository type, hit Enter for default of svn
    4. Path to respository, c:/svn/NewRepo (note the forward slashes!)
    5. Note: this wizard will create a file called c:\projects\trac\NewTrac\conf\trac.ini and this is where you can edit these settings in the future.  This includes setting up your SMTP server settings if you wish to enable e-mail notifications for ticket updates.
  15. Create the file c:\Python25\Scripts\trace-digest.py as detailed in the step by step guide to support creating a ‘users’ text file to provide authentication with encrypted passwords
  16. You can then use this script, trace-digest.py, to create users; trac-digest.py -u "liam" -p 4trac >> C:\projects\trac\users.txt.
  17. This is a manual synchronisation of the user name and password for both SubVersion and Trac, as the user databases are held completely separately.  Once that user is created, you use trac-admin at the command line to add that user as a Trac administrator; trac-admin c:\projects\trac\NewTrac permission add liam TRAC_ADMIN
  18. Finally run the python script to start the Trac web server listening for requests; tracd-script.py -p 80 --auth="*",C:\projects\trac\users.txt,trac c:\projects\trac\NewTrac
  19. If you are running Windows Firewall a warning dialog will appear, and you will need to Allow Access to Python.exe.
  20. In an internet browser, browse to http://127.0.0.1/NewTrac, and log in as the user liam with the password 4trac, you should have full access to all functions including the administration options where you can begin to configure security permissions (see below).

Logging into trac

Configuring initial security permissions in Trac

The security in Trac is intentionally simple, there is only a single category, subject, to which permissions are assigned.  A subject could be a user or a group and there are two special subject categories, created automatically; anonymous and authenticated.  These provide the ability to assign permissions for someone who has not formally logged into Trac (to provide anonymous browsing) and also default permissions for any user who has logged in and been authenticated. 

In my repositories on hosted-projects.com these special permission categories do not exist.  Instead I create user name based permissions, or more usefully group names to which users are added. 

You manage the permission via the Admin menu on the far right of the menu bar, which is only visible because we assigned TRAC_ADMIN permissions via the trac-admin command line,
Accessing the Trac Admin pages

When you select permissions you will see the special subject categories, and if you are like me, and prefer to lock down access, you can tick all the boxes next to anonymous and authenticated, and the click on the Remove Selected Items button to remove them,

Trac permissions

To create a group you just add a new subject, i.e. group-allusers and grant a permission such as WIKI_VIEW. 

Trac Admin - adding an all users group

Then create add a new users to this group, i.e. ray.

Trac Admin - adding a new user to a group

Although we have provided permissions for a user called ray, that has not created a user with a password in our authentication file, users.txt.  We can create ray with a suitable password by running the trace-digest.py script we ran earlier at the command line,

trac-digest.py -u "ray" -p vistaSquad >> C:\projects\trac\users.txt

Once this is configured close down your internet browser, then reopen it and browse again to http://127.0.0.1/NewTrac. You can now login as ray and access should be limited to the Trac Wiki for viewing only.  All other menu options should be absent.


Running Trac as a Windows Service

Up to this point we have relied on an open command window running the Trac python scripts in interactive mode.  It make much more sense to run Trac as a Windows service so that it starts automatically and does not require a user to login to the system.  I found the simple steps on how to do this at a blog entry written by Joshua Thompson http://schmalls.com/blog/2009/10/install-trac-as-a-windows-service.

This uses the Windows 2003 Resource Kit Tools (download it from here).  I also checked out the official Microsoft instructions on using these tools, http://support.microsoft.com/kb/137890, but Joshua’s blog is a much easier read and gets the job done just as quickly.

  1. Install the Windows 2003 Resource Kit Tools, which by default were installed to C:\Program Files (x86)\Windows Resource Kits\Tools
  2. Open a command window as Administrator user (Windows key, cmd.exe, <Ctrl>+<Shift>+<Enter>)
  3. Run the following command to install the service and create the relevant root key in the registry; “C:\Program Files (x86)\Windows Resource Kits\Tools\Instsrv.exe” Tracd “C:\Program Files (x86)\Windows Resource Kits\Tools\Srvany.exe”
  4. As in blog post, edit the registry (run regedit.exe), add a *new* key Parameters, under which you add the following string values;
    1. Application; c:\Python26\Scripts\tracd.exe
    2. AppParameters; -p 80 --auth="*",C:\projects\trac\users.txt,trac c:\projects\trac\NewTrac
    3. AppDirectory; c:\Python26\Scripts
  5. Once the registry changes are complete, run the Service Control Manager (Start -> Control Panel -> Administrative Tools -> Services, or just run services.msc).  There should be a new service, called Tracd, that you can now stop/start and configure just like a standard Windows service.  By default it is set to Automatic startup so if you reboot Windows Trac should now be available without logging into the system.

Summary

This is obviously just a bootstrap to get you up and running with SubVersion and Trac as fast as possible so that you can have a play with it.  I haven’t dealt with creating an SSL certificate to provide secure https access to Trac, nor have I covered configuring alternate IP addresses and HTTP Ports other than the default (which would be an issue if IIS is already running on the same system). 

Final note

Although multi project hosting is also not addressed, it appears this installation method does support multiple Trac installations.  Try browsing to http://127.0.0.1 and you should be presented with a list of Trac projects available on the system.

 

Step by step: Trac on Windows – restoring a Linux backup of Trac onto a Windows system

Introduction

In September 2006 I made a major decision on my company Source Code Management (SCM) strategy and signed up with http://www.hosted-projects.com, which provide a hosted solution for SubVersion, Trac and Bugzilla.  A few years earlier, I’d already moved my SCM from SourceSafe to SubVersion hosted on my own server on a local network.  However, I really wanted to move to a hosted provider so I could have remote access to the SCM without worrying about firewall configuration and software updates, never mind having to leave a server on 24 hours a day in a home office.

As well as SubVersion I gained access to Trac and Bugzilla.  I never really got on with Bugzilla, but Trac became an essential tool for helping me to organise my own work schedule and enable remote development for clients.  Within months I realised how useful, and essential, a hosted solution had become and so signed up for backups of both SVN and Trac. I have access to daily backups and these are included them in my own weekly backups. 

During the last three years I’ve been shockingly neglectful and trusted the guys at Hosted Projects and never actually attempted to restore the Trac backups.  For my hosted service, Trac is run on a Linux server, but with a complete dump of the Trac folder structure in the backup I suspected getting it working under Windows was completely feasible.  I finally restored my first Trac/SubVersion combined backup last week, and was impressed at how quickly I had it working, although you do have to be careful. 

This blog details how I took my SubVersion and Trac backups and restored them to run under Windows 7.  Hopefully this should be the first in a series of blogs;

  1. Restoring a Trac installation onto Windows
  2. Installing a new SubVersion/Trac repository onto Windows
  3. Configuring Trac to use Mercurial instead of SubVersion
  4. Configuring Trac to use GIT instead of SubVersion

The following installation notes were made on Windows 7 Ultimate 64 bit running under VirtualBox 3.1.2.

Documentation available for installation of Trac on Windows

The Trac project is available at http://trac.edgewall.org, with the latest stable release of Trac being  0.11.6.  This is the version running on my Hosted Projects service.

The general installation instructions for Windows can be found at, http://trac.edgewall.org/wiki/TracOnWindows,

More importantly there are incredibly useful step by step instructions at, http://trac.edgewall.org/attachment/wiki/TracOnWindows/Step_by_Step-installation-manual.txt

Planning and downloading the correct setup components

It is possible to get information on the version of Trac you are running at Hosted Projects, you can click on the ‘Powered by Trac 0.11.6’ link at the bottom of the home page.  This provides a detailed list of the versions of all the components within the Trac site.

Trac system information, component versions
In addition to Trac 0.11.6, I needed Python 2.5.4, python-2.5.4.msi,

      http://www.python.org/download/releases/2.5.4/

I found the setup tools in the Python Packages area, http://pypi.python.org/pypi, under http://pypi.python.org/pypi/setuptools/0.6c11#downloads,

Finding the setuptools in Python Packages area
 

For the setup tools, I downloaded the MS Windows installer that matched my version of python, setuptools-0.6c11.win32-py2.5.exe

Genshi is the Python library used to generate web pages.  This package is hosted by edgewall.org, the same guys responsible for Trac, at http://genshi.edgewall.org/wiki/Download. Again, I downloaded the MS Windows Installer that matched my version of python (2.5), Genshi-0.5.1.win32-py2.5.exe.

Okay, who thought if was funny to hide the SubVersion download?

To enable the SubVersion integration I headed off to Subversion, http://subversion.tigris.org/, but was redirected to as they have been accepted to the Apache Incubator at http://subversion.apache.org/ . Click on Getting Subversion->Binary Packages on left hand menu (and then selecting Windows), you can locate the Windows installation files, http://subversion.apache.org/packages.html#windows

In the list is SlikSVN, which would by normal suggestion for your standard end user who wants a simple installer but not what I really needed for a Trac installation.  However, also present on this page is a link back to tigris.org, and it is where I ended up for the Apache 2.2 compatible files, http://subversion.tigris.org/servlets/ProjectDocumentList?folderID=8100.

I downloaded two files; the SubVersion command line setup and the SubVersion Python module integration; Setup-Subversion-1.6.6.msi and svn-python-1.6.6.win32-py2.5.exe.

Installation order

  1. python-2.5.4.msi (install for all users)
  2. setuptools-0.6c11.win32-py2.5.exe (Run As Administrator)
  3. Genshi-0.5.1.win32-py2.5.exe (Run As Administrator)
  4. (reboot system)
  5. Add c:\Python25;C:\Python25\Scripts to path. (Windows 7, Control Panel -> System and Security -> System -> Advanced System Settings, Environment Variables button)
  6. Setup-Subversion-1.6.6.msi (install for all users)
  7. svn-python-1.6.6.win32-py2.5.exe (Run As Administrator)
  8. Trac-0.11.6.win32.exe (Run As Administrator)
  9. For a restore, create c:\project\trac, then copy the entire backup folder tree to, say, c:\project\trac\tiger
  10. Assuming you have restored the SubVersion repository, edit the Trac configuration file to point at the restored SubVersion repository; repository_dir = c:\svn\tiger (for my folder layout the configuration file is at, c:\projects\trac\tiger\conf\trac.ini)
  11. Resynchronise the Trac database with the SubVersion repository in its new location using the trac-admin python script; trac-admin c:\projects\trac\tiger resync
  12. Create the file c:\Python25\Scripts\trace-digest.py as detailed in the step by step guide to support creating a ‘users’ text file with encrypted passwords
  13. You can then use trace-digest.py to create users (for myself that meant the same login names as already present in my Trac backup); trac-digest.py -u "admin" -p adminpassword >> C:\projects\trac\users.txt
  14. Finally run the python script to create Trac web server listening for requests; tracd-script.py -p 80 --auth="*",C:\projects\trac\users.txt,trac c:\projects\trac\tiger
  15. Browse to http://127.0.0.1/tiger, and log in as the admin user you have configured

Lesson learned

The lesson should be that I should have attempted this restoration of a vital backup many years ago, but it does prove that the Hosted Projects backup solution is happy to restore to a different operating system if required.

Next step

My aim is to write up how to create a completely new SubVersion/Trac installation which should be fairly similar to the above, but will include initial creation of the Trac installation and SubVersion repository.  I suspect it may also require more details regarding the configuration options, as this will not be a canned backup that has most of the options pre-configured.

Notes

  1. When I first installed Python I glibly installed the 64-bit version, ignoring the fact that the supporting modules were only 32-bit.  This meant that the 32-bit modules complained that Python was not installed, as they could not locate the correct registry entry.  Never forget that there are separate registry hives for 32-bit and 64-bit programs.  I went back to a 32-bit Python install as security/performance is not really a consideration for myself, I just want to be able to restore a Trac system in an emergency.
  2. User Access Control is present under Windows 7 (although this could equally apply to Vista or Windows Server 2008). While an MSI installer will ask for permission when it executes, any ‘old fashioned’ setup files that are a standalone EXE have to be Run As Administrator manually, otherwise they will fail;Running an EXE setups as administrator
  3. The first time I ran Trac I had not installed the SVN Python tools, something that was missing of the Trac on Windows installation notes.
  4. Once the SVN Python tools were installed, I then received a message within Trac that the location of the SubVersion repository had changed and I needed to use a trac-admin resync command to synchronise the local SubVersion repository check in data to the Trac database.
  5. If you have trouble in Windows 7 finding how to change the Path environment variable setting, this image might help,

Editing PATH environment variable

 

Commercial Software Development – my presentation for DDD8 now available for download

Thanks to everyone who voted me onto the DDD8 agenda. It’s always an honour to have a topic voted into a conference by an audience of fellow developers, especially when it is a non technical topic such as this.

I hope those who came enjoyed the session had a good time, and for them or those who were on one of the other tracks, or who couldn’t squeeze in; I’ve uploaded the presentation for you to download.  I created a more simple, and smaller, PowerPoint without all the fancy animations and video clips, which is available as a compressed ZIP file,

  http://www.tigernews.co.uk/blog-twickers/ddd8/commercialsoftwaredev.zip

I also printed the presentation with speaker notes (which contain most of the information I was talking about) using PDFCreator, which is available as an Adobe Acrobat PDF here,

  http://www.tigernews.co.uk/blog-twickers/ddd8/commercialsoftwaredev.pdf

Yet again, hats off to the DDD organisers for putting on a cracking event and surviving the speaker attrition that occurred at such late notice.  Thank you to SQLBits for sponsoring the free buses from Reading station, Microsoft and their team for providing a great venue and the excellent food (those breakfast rolls guys are a truly wonderful welcome).

Most importantly, thank you to all the attendees who spent a day of their own time coming to Reading, especially those who travel from all around the UK to be here.  Without the input from the community and the enthusiasm of the community, DDD would be JAC, Just Another Conference, and we wouldn’t want that would we?
 

UPDATE 2

The guys at DDD have been super quick at turning round the video of my presentation so if you didn't make the presentation and want to see me in action you can get it here,  http://vimeo.com/9216563

UPDATE 1

Forgive me for forgetting the exact titles of these books during the session, but as promised, here's a list of some books that touch on the software development process and general management that I have found useful in the past;

  Don't Just Roll The Dice, Neil Davidson - a free eBook from one of the founders of RedGate on how to price software

  Software Runaways (Lessons Learned from Massive Software Project Failures, Robert L Glass - the title says it all!

  The Mythical Man-month (Essays on Software Engineering), Frederick P. Brooks, Jr - managing software projects

  The Inmates Are Running the Asylum, Alan Cooper - a classic on software UX design, but check out chapter 3, 'Wasting Money'

 

Hyper-V for Developers presentation - NxtGenUG Southampton

Thanks to John and the guys at NxtGenUG Southampton for the invitation to come down to and present on Hyper-V for Developers tonight.  And thanks to the tips, definitely have new stuff to look into, will look into PowerTab for improving my PowerShell experience (thanks to Rob Cooper aka  @robcthegeek).

I’ll also take the hint of using a proper ‘Southampton’ image.  Next time you’ll have the Titanic as a desktop background instead of the mighty Spitfire whose first test flights were from Eastleigh airport (now Southampton International airport).

You can download a ZIP of the PowerPoint presentation file here,

  http://www.tigernews.co.uk/blog-twickers/nxtgenugsoton/HyperV4DevPPT.zip

Or download a ZIP of a full PDF of the presentation, including the Speaker notes here,

  http://www.tigernews.co.uk/blog-twickers/nxtgenugsoton/HyperV4DevPdf.zip
 

How to enable RemoteApp (via RDP 7.0) within VirtualBox or VMWare running Windows 7, Vista SP1+ or Windows XP SP3

UDPATE 20 February 2010 : Sorry for how long the final solution took to discover, but thanks to Aaron Parker's blog entry at http://blog.stealthpuppy.com we now have the final missing pieces that allow remote applications to be hosted within a standard Windows XP SP3 virtual machine.  

I have just tested the settings from Aaron on a Windows XP SP3 image running under VirtualBox 3.1.2 which previously failed with the dreaded 'The remote computer does not support RemoteApp ..'.  As soon as the two extra settings were added to the RDP file (see steps c and d below), I could run Notepad via RemoteApp quite happily.  I'll be doing more research into this and will update some of the screen shots in this post, but I thought I'd post this update as soon as possible to help people right away.


What is RemoteApp?

This is used within the XP Mode within Windows 7 to provide seamless application integration where applications running under Windows XP appear as application windows floating over the Windows 7 desktop. 

RemoteApp is only the remote display technology which enables this to occur.  It should be noted that XP Mode also includes logic to integrate start menu items and saving of documents and files which are not covered by RemoteApp alone.

Why would you want RemoteApp?

For all those people using XP Mode to run a nicely sandboxed IE6 for testing purposes, you can now achieve exactly the same result without having to install Virtual PC.  This is important if you are already running virtual machines in another platform, such as VirtualBox or VMWare Workstation (or Player) as running Virtual PC XP Mode has a habit of causing your other virtual machines to crash with very little warning.

Also, unlike XP Mode, seamless mode in VirtualBox or ‘unity’ mode in VMWare Workstation, you can use this on a non local virtual machine.  So you could happily have a network server with IE6 instances pooled for all developers.  With VirtualBox and VMWare Workstation this also means we can use an application on 64-bit or multi CPU installations which XP Mode does not support.

Step 1 - Configuring the guest virtual machine to allow RemoteApp access

For Windows Vista and Windows XP you will need to install updates on the guest to enable RemoteApp (see below).  Windows 7 requires now such updates.

This example uses a completely clean version of Windows 7 Ultimate RTM 64-bit, dual CPU, running under VirtualBox 3.1.  We are going to enable Notepad to be run as a RemoteApp.  The connecting client is Windows 7 Ultimate RC 64-bit, dual CPU.

This solution involved directly editing the registry, and this is not the ideal way of enabling RemoteApp, and I have omitted numerous registry keys which would be required by XP Mode (see resources for full registry value list).  This is a minimal bootstrap to enable RemoteApp until the virtualisation and remote desktop teams provide suitable tools and fully document the process.

1. Enable remote desktop connections on the guest.

Enable Remote Desktop Connections
 

2. Run regedit (registry editor) and locate the key TsAppAllowList

     a) New Key, Applications.
     b) Under Applications, create New Key, 1234567 (the key name is not important, we just need any key for next two steps)
     c) In the new key, Create New -> String Value, Name. Set value to Notepad
     d) Also in the new key, Create New -> String Value, Path. Set to c:\windows\system32\Notepad.exe
 

Editing Terminal Services Application Settings
 

3. Navigate back to the TsAppAllowList branch

     a) Edit fDisableAllowList value, and set to 1

Registry editing, DisbaleAllowList
 

Step 2 – Creating the RDP file to access the RemoteApp

Now the guest operating system has a RemoteApp created we need to use a Remote Desktop Connection to access that application.

1. Run remote desktop connection, setup your desired settings as you would in a normal connection
2.. Save the settings to an RDP file.


Creating the RDP file  

3) Use Notepad to open the RDP file to edit the configuration file,

   a) Modify the setting; remoteapplicationmode:i:0  to  remoteapplicationmode:i:1
   b) Add the setting; remoteapplicationprogram:s:Notepad
   c) Add the setting; disableremoteappcapscheck:i:1
   d) Add the setting; alternate shell:s:rdpinit.exe
   e) Save the RDP file

   (20th February 2010 - thanks again to Aaron Parker's blog for steps c and d)

Editing the RDP file in Notepad

 

4. You can now use the RemoteApp by double clicking on the RDP to open with Remote Desktop Connection,

     a) Click on Connect when you see the security warning


RemoteApp security warning
 

     b) And after a short start to initiate the remote desktop session you will be running notepad floating over your VM
 

Notepad running as a RemoteApp


Setting a Timeout for RDP connections

When using RemoteApp one of the issues you may find is that when you exit the application that does not close the Remote session on the guest machine.  This is clear on a desktop operating system as you will receive warning messages about users already being logged into the system.
Clearly this is less than ideal, so I decided to find out how to ensure that closing the application caused the user to logout in a very short time period.  This is configured on the guest operating system.

  1. Windows key, Edit Group Policy.
  2. Computer Configuration -> Administrative Templates -> Windows Components -> Remote Desktop Session Host -> Session Time Limits
  3.Double click 'Set time limit for disconnected sessions', change to Enabled, set to 1 Minute.

Final thought

Similar to VirtualBox seamless mode, you will not be able to move the floating guest application window between monitors, unless you save the RDP to use all monitors available.  Either set this option prior to saving the RDP file, or edit the RDP setting multimon:i:1.

Summary

As the keen eyed may have spotted, my laptop is still running the Release Candidate of Windows 7 as I have been too busy recently to upgrade to the RTM version.  However, over Christmas I will be upgrading the laptop to RTM and I’m glad I did, because I RemoteApp means there will be absolutely no need to install Virtual PC and XP Mode when I can just run IE6 under VMWare or VirtualBox instead.

Patches for Windows XP and Vista
 

To enable Windows XP SP3 or Vista SP1 (or higher) to host remote applications you will need to install one of the following patches.

Update for Windows® XP SP3 to enable RemoteApp™ (KB961742)

http://www.microsoft.com/downloads/details.aspx?FamilyID=2f376f53-83cf-4e5b-9515-2cb70662a81b&displaylang=en

Update for Windows® Vista SP1 or above to enable RemoteApp™, (KB961741)

http://www.microsoft.com/downloads/details.aspx?familyid=097B7478-3150-4D0D-A85A-6451F32C459C&displaylang=en

Resources

The original article which started all this, from Ben Armstrong, Virtualization Program Manager at Microsoft ‘Virtual PC Guy’s blog’, http://blogs.msdn.com/virtual_pc_guy/archive/2009/12/17/remoteapp-hyper-v-windows-xp-vista.aspx


.. which led to Remote Desktop Services (Terminal Services) Team Blog that revealed it’s all an RDP 7.0 thing, and not Hyper-V is just an enabling technology, http://blogs.msdn.com/rds/archive/2009/12/15/remoteapp-for-hyper-v.aspx


... as Aaron Parker suggested by including a VirtualBox example on his stealthpuppy blog, http://blog.stealthpuppy.com/virtualisation/remoteapp-for-hyper-v-hyper-what

20th February 2010 update ... and it was Aaron Parker's blog post here that revealed the final missing settings in the RDP file that allowed me to finally run a RemoteApp from within a Windows XP SP3 virtual machine.


Once I knew the TsAllowAppList registry key was involved I Bing later I found the very useful XP Mode analysis of this key at the C# Snippets blog, http://c-sharp-snippets.blogspot.com/2009/09/creating-shortcut-to-application-inside.html


And for RDP configuration file editing, I found an excellent clue in Paul Monaghan’s article here, http://support.yourofficeanywhere.co.uk/Customer/KBArticle.aspx?articleid=82


... which helped me guess that changing the remoteapplicationmode:i:0 value to 1 would help, and if you Bing remoteapplicationmode:i:1 then the careless folk at financelogix.com have kindly published their RDP file with the application name key within it, which gave me the last piece of the jigsaw.


Finally the ‘Set time limit for disconnected sessions’, example may be for Windows XP but gave enough information for Windows 7, http://howtonetworking.com/casestudy/tstimelimit1.htm

Multi monitor support for a Windows 7 guest operating system under VirtualBox, for different sized monitors

This nugget was generated by a fellow developer from the London .Net User Group who was trying to use multiple monitors with a virtual machine running under VirtualBox. His guest operating system was Windows 7, and he was attaching from a Windows XP host operating system.

I did suggest he might look at VMWare Workstation to run guest operating systems and this happily supports multiple monitors, even if the monitors are different sizes.  Even the latest free VMWare Player can handle multiple monitors, and Aero, and event better it can now create new virtual machines.

However, if your preference is for Sun's VirtualBox product, multiple monitors can only be achieved by using a remote desktop connection. Older version of remote desktop (prior to v7.0) can handle mulitple monitors by using the /span command line switch but this requires monitors that are the same resolution and creates a single desktop across all monitors.

The good news, is that with the release of RDP 7, you can now use remote desktop connection to connect from Windows XP SP3 into a Windows 7 or Windows Server 2008 R2 system and you can use full feature multiple monitors.  You need the support on the destination operating system, it must be running RDP 7 for remote connecitons, and only Windows 7 Enterprise and Windows 7 Ultimate support multiple monitors via RDP.

Here is a good explanation from the remote desktop services team at Microsoft,

  http://blogs.msdn.com/rds/archive/2009/08/21/remote-desktop-connection-7-for-windows-7-windows-xp-windows-vista.aspx

And the download for Windows XP SP3 and Windows Vista can be found here at KB969084,

  http://support.microsoft.com/kb/969084

I have to admit that I haven't tried to run RDP 7.0 from Windows XP as I long ago deleted Windows XP from any of my machines.

How to setup a SQL Server alias and when is a connection alias useful for developers?

Isn’t this old hat?

In a distant SqlBits, far, far away (actually the very first SqlBits) I gave two grok talks; the first on developers using SQL Server aliases to simplify development, the second on encrypting SQL databases using NTFS encryption.  As usual I promised to write it all up on this blog. 

Two years later, at the recent SQL Bits V, I mentioned aliases to a fellow developer. He followed up and asked for a link to my blog.  That’s when I discovered that although I wrote up the use of NTFS file encryption I didn’t write up the use of aliases. I can only apologise and have now finally get round to writing this up. As a bonus it now includes 64-bit goodness and a much, much faster (if dirty) way of configuring SQL Server Aliases.

Although a topic as old as SQL Server 2000, I still find it surprising how many developers are unaware of how useful a SQL alias can be so this may be useful to those new to this area of SQL Server.

So what is a SQL Server alias?

A SQL Server alias is simply a friendly name, configured on the client computer that points at a SQL Server instance.  This instance can either be installed locally or on a different machine on the network.  Think of an alias as an entry in a hosts file, a sort of hard coded DNS lookup a SQL Server instance.

Why would you want to use them?

A SQL Server Alias can be useful for several reasons

The first time I used them was in a small development team where most developers had installed SQL Server as default instances, (local), but some of the more anally retentive developers (myself included) had used named instances, i.e. <MyMachine>\SQL2005Std.  By using the same alias on all developer machines, any project could be checked out without having to edit the .config files to modify the database instance, reducing check in ‘noise’ within the version control system.

A second use is for simplifying the configuration of continuous integration (CI) servers. Similar to a shared development team, you create aliases on your CI server to perform integration testing on multiple variants of database servers, so you don’t have to change application configuration settings. Also, a developer can configure an alias on their local machine, run unit tests against that alias, and the CI server can use the very same alias pointing at a local SQL instance when the tests are run in an automated mode.

A third use allows a developer to quickly switch between different local database instances (i.e. SQL 2000, SQL 2005, SQL 2008, SQL Express), or between local instances and network instances such as staging or build servers to verify consistent operation of an application.  Again, all without editing (possibly) multiple application configuration files, or registry entries across numerous applications.

Pre-requisites for SQL Server Alias usage
 

  1. You must be willing for your clients to connect to the instance via a network protocol. It is not possible to use shared memory connections that are available when the client and instance are on the same system. I use TCP/IP connections for my aliases.
  2. On the system hosting the SQL Server instance you must have the SQL Server Browser service running (this is normally has Start Mode set to Automatic).
  3.  On a 64-bit system, if you have both 32-bit and 64-bit clients, you will need to create an alias for BOTH 32-bit and 64-bit clients.


Configuration of the SQL Server Instance (to enable a network protocol)

Microsoft now quite rightly ships products locked down by default, and SQL Server is no exception, so you will need to enable your chosen network protocol, in this case TCP/IP.

Run the SQL Server Configuration Manager, Programs -> Microsoft SQL Server 2005 (or 2008) -> Configuration Tools

Open the SQL Server Network Configuration tree branch (on my machine it is listed as 32-bit for SQLExpress, 64-bit for 2005 Dev, 2008 Std), and highlight the protocols option for your SQL Server Instance, you can see the protocols listed on the right hand pane, including TCP/IP

SQL Configuration Manager - Protocols

Double click the protocol you wish to open the protocol dialog, so you can modify the settings for that protocol,

SQL Configuration Manager - Protocols Dialog

While you are in the SQL Server Configuration Manager, it might be worth ensuring that the SQL Server Browser service is running and set to Automatic.  You can view the status of the services in the SQL Server Services tree branch.  The various services are listed on the right hand pane,

SQL Configuration Manager - Services

Double click on the SQL Server Browser service to modify it’s properties, and ensure the Start Mode is set to Automatic.

Client configuration - how to create a SQL Server Alias (easy, official way)

Run the SQL Server Configuration Manager, Programs -> Microsoft SQL Server 2005 (or 2008) -> Configuration Tools.

Open the SQL Native Client 10.0 Configuration tree branch (for 64-bit systems you will have a 32-bit specific branch and a default, 64-bit branch), and highlight the Aliases option.

SQL Configuration Manager - Alias

All current aliases are displayed in the right hand pane. To create an alias, right click and select New Alias. To modify an existing alias double click the alias name.  You edit the details in the alias dialog,

SQL Configuration Manager - Alias Dialog

In this dialog the alias is called NUnitAlias, the protocol has been set to TCP/IP, and the SQL Server instance is set to 6910p-WIN7BETA-SQL2005dev. When a client connects using the instance name NUnitAlias it will connect to 6910p-WIN7BETA-SQL2005dev using the TCP/IP protocol.

Client configuration - how to create a SQL Server Alias (quick, dirty, unofficial way)

You may have noticed that to configure an alias we were using the SQL Server Configuration Manager, which is part of the SQL Server Client Tools set. I decided to prove that was all you needed (i.e. you don’t need to install an actual SQL Server instance) by downloading these tools. Except you can’t, well, not as a standalone installation.

I grabbed my nearest MSDN SQL 2008 R2 DVD, and although the SQL Server Native Client has a separate installation the client tools did not.  So I installed the SQL Server Express, selecting a custom option, installing only Management Tools – Basic and SQL Client Connectivity Pack SDK. 

That worked fine, but I was uncomfortable with that amount of effort and a Bing or two later I found this useful SQL blog article from 2007,
 
   http://blogs.msdn.com/sql_protocols/archive/2007/01/07/connection-alias.aspx

So it’s all in the registry, it’s that easy. I tested this theory on a clean Windows 7 Ultimate installation running as a virtual machine under VirtualBox. I added the ConnectTo registry key, and a value for an alias, and used a simple UDL file to test a connection via Microsoft OLE DB for SQL Server using the alias I entered in the registry,

Registry Editor - Default Key

It occurred to me that on 64-bit operating system, if there were only one registry key, why would we need to create two aliases.  The registry settings shown in the image above are for the default for the operating system; for a 32-bit operating system this is for 32-bit clients, for a 64-bit operating system this is for 64-bit clients.

For a 64-bit operating system the 32-bit client alias values are stored in a separate Wow6432Node as shown here,

Registry Editor - 32-bit client on a 64-bit operating system

Summary

So that’s it really, aliases for 32-bit and 64-bit systems, including a very handy new discovery of setting the alias values directly via the registry.  With the registry solution you can include alias configurations in version control, and use simple .reg files to configure aliases on the fly (useful in a CI server script) so you no longer have to maintain a myriad of application configuration settings for each server instance you might want to use.
 

Excellent blog post on how to resize virtual disc partitions under VirtualBox (... and should work for other virtualisation platforms)

Via Mehul Harry on Twitter (http://twitter.com/MehulHarry/status/6122948078) I discovered this superbly detailed blog on how to resize a virtual partition running under VirtualBox,

  http://www.my-guides.net/en/content/view/122/26/

There is an issue with resizing Vista paritions with the Gnome Partition Manager, but the fix for that is detailed here,

  http://www.howtogeek.com/howto/windows-vista/using-gparted-to-resize-your-windows-vista-partition/

Resizing partitions is always a pain and I like the non destructive nature of this approach. It should be equally applicable for use under Hyper-V Server, Virtual PC or VMWare Workstation.

The next time I need a resize, I might take this approach.

 

Hosted exception collection for .NET applications made easy – Exceptioneer.com

I own a company, Tiger Computer Services Ltd, which is an Independent Software Vendor (ISV) providing .NET software solutions to clients in the London area.

One of the most significant considerations when running a small ISV is the cost of supporting software in the field. For some clients, support is not a billable item, especially if the fault is within the software we have provided. This means that every time the telephone rings, we bleed money, and if we have to actually go on site to resolve an issue it gets worse.

Whether the software solution is ‘packaged’ or is a custom solution, all our clients run the software on their own equipment at their own premises.  We have never asked for VPN access into their network.  We take the view that if you cannot easily VPN into a system you have a real incentive to write reliable software that works first time and doesn’t need continuous intervention.

However, although all the clients can be reached within about one hour by public transport, an on-site visit is bad for many reasons;

  1. It costs money; either to ourselves or to the client (the latter is even worse if someone has to approve the cost in advance of the visit)
  2. It takes time, which can lead to more issues; i.e. data corruption through continued use of the software
  3. It is highly disruptive of work being undertaken for other clients

Exception handling is a good thing

This may sound obvious, but however good your programming is, it’ll generate exceptions.  It is impossible to account for all eventualities and you need to be ready to handle them and log the state of the system when they occurred.

The solutions we deliver are generally a combination of ASP.NET web applications, Windows Services (Windows Forms applications with no user interface) and usually with some database server in the background (SQL Server, MySQL or Oracle).  Our exception handling is wrapped up in a set of reporting libraries whose history dates back to before Visual Basic 6.

The reporting libraries were overhauled in the transfer to C#, and they provide a simple method for logging messages and exceptions simultaneously to the Windows Event Log, text based log file, SMTP e-mail and interactive dialogs (for Windows Forms applications with a user interface).

The libraries consist of a central reporting engine, into which various reporters are plugged and these handle all the various methods for recording exceptions.  One call to the reporting engine to display a message or exception calls all the reporters in turn.  This allows new methods of reporting exceptions to be added quickly, and for various methods to be turned off as required (such as disabling writing to the Event Log on shared hosting providers).

Whether you use the Microsoft application block, log4net or some home grown exception handling, the biggest issue is getting access to the log files or event log messages once an exception has occurred.

Without remote access, we rely on the client IT team to either take the text log file, or dump the Event Logs to a CSV file, and e-mail the file to us. Of course, this assumes that the client is already aware they have a problem, which means it has very likely started to affect their use of the application.

Proactive exception handling

In an ideal world you would receive notification automatically about any exceptions in your applications, without requiring intervention from the client.

Nothing impresses a client more than when you phone them to tell them they have an issue, and that you have already got a solution which they can implement to fix it.

Although our reporting libraries do include an SMTP e-mail reporter which can provide some of this proactive functionality it is not always possible to persuade clients that their SMTP gateway or firewall should be ‘tweaked’ to allow support e-mails out of the building.

Exceptioneer

Earlier this year I was kindly invited into a beta program for a ‘hosted exception collection’ service called Exceptioneer run by the good chaps at Pixel Programming, Phil Winstanley (a Microsoft MVP, no less) and Chris Gaskell. 

These guys write .NET applications for a living and had already created their own centralised exception collection system for their own applications, solving the issues encountered when creating this type of solution.  Realising they had something well worth sharing, they turned their system into a packaged, hosted service for other developers and Exceptioneer was born.

.NET support

Exceptioneer supports ASP.NET, Windows Forms and JavaScript (although I have yet to use the JavaScript exception hander).

Integration in an ASP.NET application is simple; reference the Exceptioneer web client assembly and add a few lines in the Web.Config and it will be reporting unhandled exceptions right away. 

For Windows Forms, you need to reference a windows form assembly and integrate the API into whatever exception handling system you are already using.  We had it integrated with our reporting engine within an hour or so.

What does Exceptioneer provide?

The management interface of Exceptioneer provides a very clean web interface, where you can view all your registered projects (limited to three in the free service), and drill down into the various exceptions which might have occurred, when the last occurred and what application generate the exception.

Repeated exceptions are intelligently grouped with drill down for further detail, including stack traces and full source code from the PDB file if you are testing a debug compilation.  You can identify the exact line causing the issue, and 75% of the time it is possible to identify the underlying cause without even starting up Visual Studio to view the source code.

Exceptioneer provides e-mail notifications, and if you are a Twitter user, Exceptioneer can even send direct messages when new exceptions occur, which tends to catch the eye even quicker than e-mails.

... and it works

Since integrating Exceptioneer with a new system deployed in September, it has proved invaluable for resolving issues (related to user input which was not being verified correctly) which would have come close to an on-site visit to identify exactly what was happening.

Even better, on most occasions we phone the client first to inform them that they had the problem (which occurred more than once) and the IT support guys were able to fix the problem before the end user actually realised something had gone wrong.

Try it yourself

Now the beta program has been completed, the service has been opened for everyone.  I recommend heading over to http://www.exceptioneer.com and registering for a free account, and giving it a spin in your own projects.