0

When the IIS application pool resets the worker processes at a specific time, the mysql session state store will crash the w3wp.exe process and the website request will result in a crash error message. This is in version mysql connector 6.7.4.0

System.Security.SecurityException was unhandled
  HResult=-2146233078
  Message=Requested registry access is not allowed.
  Source=mscorlib
  StackTrace:
       at Microsoft.Win32.RegistryKey.OpenSubKey(String name, Boolean writable)
       at System.Diagnostics.EventLog.CreateEventSource(EventSourceCreationData sourceData)
       at System.Diagnostics.EventLogInternal.VerifyAndCreateSource(String sourceName, String currentMachineName)
       at System.Diagnostics.EventLogInternal.WriteEntry(String message, EventLogEntryType type, Int32 eventID, Int16 category, Byte[] rawData)
       at System.Diagnostics.EventLog.WriteEntry(String message)
       at MySql.Web.SessionState.MySqlSessionStateStore.HandleMySqlException(MySqlException e, String action)
       at MySql.Web.SessionState.MySqlSessionStateStore.CleanupOldSessions(Object o)
       at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
       at System.Threading.ExecutionContext.Run(ExecutionContext executionContext, ContextCallback callback, Object state, Boolean preserveSyncCtx)
       at System.Threading.TimerQueueTimer.CallCallback()
       at System.Threading.TimerQueueTimer.Fire()
       at System.Threading.TimerQueue.FireNextTimers()
  InnerException: 

Any ideas?

I also added a Read permission to network service and AppPoolIdentity

Justin Homes
  • 3,739
  • 9
  • 49
  • 78
  • Did you google the error message? – Ash Burlaczenko Aug 11 '13 at 21:38
  • Have you checked out the answers here: http://stackoverflow.com/questions/1274018/system-security-securityexception-when-writing-to-event-log – Daz Aug 11 '13 at 21:50
  • @JustinHomes, theres 193,000 results https://www.google.co.uk/search?q=Requested+registry+access+is+not+allowed&oq=Requested+registry+access+is+not+allowed&aqs=chrome.0.69i57j69i61j69i60j0l2.1126j0&sourceid=chrome&ie=UTF-8#bav=on.2,or.r_cp.r_qf.&fp=5b70968a870a59de&q=%22Requested+registry+access+is+not+allowed%22&safe=off – Ash Burlaczenko Aug 11 '13 at 21:54
  • @Daz yes that is exactly what i had tried. by giving Registry access as i mentioned in the initial post. Thanks – Justin Homes Aug 12 '13 at 00:33

0 Answers0