I recently had an issue where a contractor provided one of our divisions with a web service to deploy on of their servers. When everything was deployed and the web.config all modified, we kept getting errors IIS 500 errors with:
Requested registry access is not allowed
After much finger pointing, and use of the phrase, "I can't suplicate the problem in my development environment". I isolated the problem down to this one call in the contractor's web service:
evntLog.WriteEntry( sOut, System.Diagnostics.EventLogEntryType.Error);
The contractor had specified a custom event source for the EventLog control. A Source being the value that appears in the source column of the event log. Custom being that the source is not currently registered in the event log.

The evntLog object, which has its Source property set to CustomSrc, attempts to make a log entry. The operation of this method is detailed in the Framework docs and is as follows:
You must set the Source property on your EventLog component before writing entries to the log. You can call CreateEventSource on a new source to register it before writing to the event log, but this is not necessary. If the source specified in the Source property of this EventLog instance is not registered on the computer your component is writing to, WriteEntry calls CreateEventSource and registers the source.
This problem occurs because the user account that you used to log on does not have sufficient permissions.
The first time that you call the EventLog.CreateEventSource() method to create a custom event log, the custom event log entry is created under the following registry subkey:
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Eventlog
To create this subkey entry, you must have permission to write. However, the regular user account does not have permission to write. Therefore, you receive the error message that is mentioned in the "Symptoms" section.
The reason the developer did not see this problem on his development environment is that the event source was already registered while the web service was running with Administrator privileges. So, when he later lowered the web service's account priveledge, subsequent calls to WriteEntry did not trigger a call to CreateEventSource. So rather than keep banging my head against the wall on this, I wrote a simple application that an administrator can run on the server to register the event source: RegEventSource.exe (28 KB)
So, in a nutshell... if you make use of System.Diagnostics.EventLog.WriteEntry with a custom Event Source, provide your client with an installer or some way to register the event source in their production enironment. This is just another reason why I love VirtualPC. It gives you an ideal environment to test these sort of deployments out to ensure you don't waste your client's time with trivial issues like this.