C# Mysql会话状态错误
当IIS应用程序池在特定时间重置工作进程时,mysql会话状态存储将使w3wp.exe进程崩溃,网站请求将导致崩溃错误消息。这是mysql connector 6.7.4.0版本C# Mysql会话状态错误,c#,asp.net,mysql,mysql-connector,C#,Asp.net,Mysql,Mysql Connector,当IIS应用程序池在特定时间重置工作进程时,mysql会话状态存储将使w3wp.exe进程崩溃,网站请求将导致崩溃错误消息。这是mysql connector 6.7.4.0版本 System.Security.SecurityException was unhandled HResult=-2146233078 Message=Requested registry access is not allowed. Source=mscorlib StackTrace:
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:
有什么想法吗
我还向网络服务和AppPoolIdentity添加了阅读权限你搜索了错误消息了吗?你在这里查看了答案了吗:@JustinHomes,有193000个结果@Daz是的,这正是我尝试过的。正如我在第一篇文章中提到的,通过提供注册表访问权限。谢谢