microsoft / tigertoolbox

Toolbox repository for Tiger team
http://aka.ms/sqlserverteam
Other
1.48k stars 740 forks source link

Failover Detection - Strong name validation failed #137

Open KenJ opened 5 years ago

KenJ commented 5 years ago

Downloaded latest failover detection utility on 2019-04-11 (exe modified on 2018-11-27 )

Gathered all log files together as outlined in the web instructions - https://techcommunity.microsoft.com/t5/SQL-Server/Failover-Detection-Utility-Availability-Group-Failover-Analysis/ba-p/386021

Followed the strong name workaround in the web instructions (update 11/27): sn -Vr "C:\ path \FailoverDetector" and sn -Vr "C:\ path \FailoverDetector\Microsoft.SqlServer.XEvent.Linq.dll"

Program exited with error: Validating log data instances includes: instance01 instance02

All data is ready for instance: instance01 folder. All data is ready for instance: instance02 folder.

Unhandled Exception: System.IO.FileLoadException: Could not load file or assembly 'Microsoft.SqlServer.XEvent.Linq, Version=15.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91' or one of its dependencies. Strong name validation failed. (Exception from HRESULT: 0x8013141A) ---> System.Security.SecurityException: Strong name validation failed. (Exception from HRESULT: 0x8013141A) --- End of inner exception stack trace --- at FailoverDetector.XeventParser.LoadXevent(String xelFileName, String serverName) at FailoverDetector.Program.Main(String[] args) in E:\FailoverDetector-master_v1\FailoverDetector-master\FailoverDetector\Program.cs:line 45

System Info: Windows 10 Enterprise 10.0.17134 Build 17134

fvanderhaegen commented 5 years ago

Did you manage to solve this problem? I have the same issue

fvanderhaegen commented 5 years ago

I managed to get it working. I've you add following registrykeys, you disable strongname validation for all assemblies with this public key.

[HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\StrongName\Verification\*,89845DCD8080CC91]
[HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\Microsoft\StrongName\Verification\*,89845DCD8080CC91]
NRajeshDBA commented 3 years ago

I am getting the same error.

_Unhandled Exception: System.IO.FileLoadException: Could not load file or assembly 'Microsoft.SqlServer.XEvent.Linq, Version=15.0.0.0, Culture=neutral, PublicKeyToken=89845dcd8080cc91' or one of its dependencies. Strong name validation failed. (Exception from HRESULT: 0x8013141A) ---> System.Security.SecurityException: Strong name validation failed. (Exception from HRESULT: 0x8013141A) --- End of inner exception stack trace --- at FailoverDetector.SystemHealthParser.LoadXevents(String xelFileName, String serverName) at FailoverDetector.Program.Main(String[] args) in E:\FailoverDetector-master_v1\FailoverDetector-master\FailoverDetector\Program.cs:line 84