I recently encountered the following error when deploying a service in the NServiceBus generic host (NServiceBus.Host.exe) on a 64bit machine,
System.InvalidOperationException: The 'Microsoft.Jet.OLEDB.4.0' provider is not registered on the local machine.
It turns out that this is actually a symptom of a problem which can show itself in a number of ways and is caused by running a service which depends on a 32bit dll (in this case the Microsoft Jet drivers) on a 64bit system in the generic host.
To fix it you can create a version of the generic host which is configured to run as 32bit as follows:
Run a visual studio command prompt and cd to the directory where NServiceBus.Host.exe is. You will also need the NServiceBus.snk file from the NServiceBus download in the same directory so that you can resign the assembly after configuring it
At the command prompt type:
corflags /32BIT+ /Force NServiceBus.Host.exe
sn -R NserviceBus.Host.exe NServiceBus.snk
You can now deploy this version of the host onto your 64bit server and services which use it will run in 32bit mode