我在这里的安装项目中遗漏了一些东西吗?
我的 .NET/Winform 应用程序正在使用 Enterprise Library 5.0 日志记录块。它在我的机器上运行良好,但在 QA 机器上失败。我已经复制了所有必需的 DLL 但是应用程序仍然在 QA 机器上崩溃。我复制了应用程序安装目录中的所有 Enterprise Library 5.0 DLL,但这没有任何区别。有什么想法可能是错的吗?
我没有得到堆栈跟踪,但当我附加 WinDbg 时,我看到以下内容:
0:027> !threads
PDB symbol for mscorwks.dll not loaded
ThreadCount: 12
UnstartedThread: 0
BackgroundThread: 8
PendingThread: 0
DeadThread: 2
Hosted Runtime: no
PreEmptive GC Alloc Lock
ID OSID ThreadOBJ State GC Context Domain Count APT Exception
0 1 19ec 0085b620 6020 Disabled 12889fd8:12889fe8 008533c8 1 STA (GC)
2 2 2af8 008708d0 b220 Enabled 00000000:00000000 008533c8 0 MTA (Finalizer)
XXXX 3 0 0728aeb8 5820 Enabled 00000000:00000000 008533c8 0 Ukn
8 4 14cc 072c8e30 80a220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Completion Port)
16 5 13a8 0c5370d8 180b220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Worker)
17 6 23d4 00864560 200b220 Enabled 00000000:00000000 008533c8 0 MTA
XXXX 7 0 0c5c3448 9820 Enabled 00000000:00000000 008533c8 0 MTA
22 8 2718 0c796e18 80a220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Completion Port)
24 9 2208 07337c28 180b220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Worker)
25 a 16ac 0c563a58 180b220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Worker)
26 b d98 072ce618 180b220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Worker)
27 c 2760 0728e170 b022 Disabled 12855dfc:12856290 008533c8 2 MTA System.ExecutionEngineException (025210b4)
0:027> kb
ChildEBP RetAddr Args to Child
WARNING: Stack unwind information not available. Following frames may be wrong.
1074e318 70187125 0728e170 1074e890 00000002 KERNELBASE!DebugBreak+0x2
1074e7d4 7018735e 80131506 7018858e 00000000 mscorwks!GetAddrOfContractShutoffFlag+0x944f
1074e7ec 70188599 80131506 7018858e 00000000 mscorwks!GetAddrOfContractShutoffFlag+0x9688
1074e810 7007693b 1074e890 41f3b57e 0728e170 mscorwks!GetAddrOfContractShutoffFlag+0xa8c3
1074e844 700767d9 1074e890 41f3b542 1074ea04 mscorwks!StrongNameErrorInfo+0x1855f
1074e878 6ffdd478 1074e890 00004000 0728e170 mscorwks!StrongNameErrorInfo+0x183fd
1074e8a4 6ffdd675 1074e9b4 1074f1bc 1074e988 mscorwks!GetMetaDataInternalInterface+0x9a25
1074e8c8 77e96ac9 1074e9b4 1074f1bc 1074ea04 mscorwks!GetMetaDataInternalInterface+0x9c22
1074e8ec 77e96a9b 1074e9b4 1074f1bc 1074ea04 ntdll!RtlDosSearchPath_Ustr+0xada
1074e99c 77e6010f 0074e9b4 1074ea04 1074e9b4 ntdll!RtlDosSearchPath_Ustr+0xaac
1074ed8c 6e202eb5 00000000 738b1151 1074eda8 ntdll!KiUserExceptionDispatcher+0xf
1074edf4 6e719b9a 6ff6e268 12855de0 73947824 mscorlib_ni+0x1c2eb5
1074ee10 60fa0148 139077ac 12851b6c 125ecef8 mscorlib_ni+0x6d9b9a
1074ee24 60f9fc4a 1074f1bc 6ffe0178 ffffffff Microsoft_Practices_EnterpriseLibrary_Logging_ni+0xb0148
1074ee70 60f9fbe5 60e90585 1074ee8c 60e9074c Microsoft_Practices_EnterpriseLibrary_Logging_ni+0xafc4a
1074ee7c 60e9074c 1273b864 126a7b70 1074eeb0 Microsoft_Practices_EnterpriseLibrary_Logging_ni+0xafbe5
1074ee8c 60e9060b 1247ffa4 60ebe938 126a7b70 Microsoft_Practices_EnterpriseLibrary_Common_ni+0x8074c
1074eeb0 60e8ff01 1074eeec 60e90431 1247ff58 Microsoft_Practices_EnterpriseLibrary_Common_ni+0x8060b
1074eeb8 60e90431 1247ff58 738c58e2 1247ff58 Microsoft_Practices_EnterpriseLibrary_Common_ni+0x7ff01
1074eeec 60e9b984 1247ff58 1246dbd4 00000000 Microsoft_Practices_EnterpriseLibrary_Common_ni+0x80431
My .NET/Winform application is using Enterprise Library 5.0 logging block. It works fine on my machine but fails on the QA machine. I have all the necessary DLLs copied in
the setup project however the application still crashes on the QA machine. I copied all Enterprise Library 5.0 DLLs in the application installation directory but that does not make any difference. Any ideas what could be wrong?
I don't get a stacktrace but when I attach WinDbg I see following:
0:027> !threads
PDB symbol for mscorwks.dll not loaded
ThreadCount: 12
UnstartedThread: 0
BackgroundThread: 8
PendingThread: 0
DeadThread: 2
Hosted Runtime: no
PreEmptive GC Alloc Lock
ID OSID ThreadOBJ State GC Context Domain Count APT Exception
0 1 19ec 0085b620 6020 Disabled 12889fd8:12889fe8 008533c8 1 STA (GC)
2 2 2af8 008708d0 b220 Enabled 00000000:00000000 008533c8 0 MTA (Finalizer)
XXXX 3 0 0728aeb8 5820 Enabled 00000000:00000000 008533c8 0 Ukn
8 4 14cc 072c8e30 80a220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Completion Port)
16 5 13a8 0c5370d8 180b220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Worker)
17 6 23d4 00864560 200b220 Enabled 00000000:00000000 008533c8 0 MTA
XXXX 7 0 0c5c3448 9820 Enabled 00000000:00000000 008533c8 0 MTA
22 8 2718 0c796e18 80a220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Completion Port)
24 9 2208 07337c28 180b220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Worker)
25 a 16ac 0c563a58 180b220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Worker)
26 b d98 072ce618 180b220 Enabled 00000000:00000000 008533c8 0 MTA (Threadpool Worker)
27 c 2760 0728e170 b022 Disabled 12855dfc:12856290 008533c8 2 MTA System.ExecutionEngineException (025210b4)
0:027> kb
ChildEBP RetAddr Args to Child
WARNING: Stack unwind information not available. Following frames may be wrong.
1074e318 70187125 0728e170 1074e890 00000002 KERNELBASE!DebugBreak+0x2
1074e7d4 7018735e 80131506 7018858e 00000000 mscorwks!GetAddrOfContractShutoffFlag+0x944f
1074e7ec 70188599 80131506 7018858e 00000000 mscorwks!GetAddrOfContractShutoffFlag+0x9688
1074e810 7007693b 1074e890 41f3b57e 0728e170 mscorwks!GetAddrOfContractShutoffFlag+0xa8c3
1074e844 700767d9 1074e890 41f3b542 1074ea04 mscorwks!StrongNameErrorInfo+0x1855f
1074e878 6ffdd478 1074e890 00004000 0728e170 mscorwks!StrongNameErrorInfo+0x183fd
1074e8a4 6ffdd675 1074e9b4 1074f1bc 1074e988 mscorwks!GetMetaDataInternalInterface+0x9a25
1074e8c8 77e96ac9 1074e9b4 1074f1bc 1074ea04 mscorwks!GetMetaDataInternalInterface+0x9c22
1074e8ec 77e96a9b 1074e9b4 1074f1bc 1074ea04 ntdll!RtlDosSearchPath_Ustr+0xada
1074e99c 77e6010f 0074e9b4 1074ea04 1074e9b4 ntdll!RtlDosSearchPath_Ustr+0xaac
1074ed8c 6e202eb5 00000000 738b1151 1074eda8 ntdll!KiUserExceptionDispatcher+0xf
1074edf4 6e719b9a 6ff6e268 12855de0 73947824 mscorlib_ni+0x1c2eb5
1074ee10 60fa0148 139077ac 12851b6c 125ecef8 mscorlib_ni+0x6d9b9a
1074ee24 60f9fc4a 1074f1bc 6ffe0178 ffffffff Microsoft_Practices_EnterpriseLibrary_Logging_ni+0xb0148
1074ee70 60f9fbe5 60e90585 1074ee8c 60e9074c Microsoft_Practices_EnterpriseLibrary_Logging_ni+0xafc4a
1074ee7c 60e9074c 1273b864 126a7b70 1074eeb0 Microsoft_Practices_EnterpriseLibrary_Logging_ni+0xafbe5
1074ee8c 60e9060b 1247ffa4 60ebe938 126a7b70 Microsoft_Practices_EnterpriseLibrary_Common_ni+0x8074c
1074eeb0 60e8ff01 1074eeec 60e90431 1247ff58 Microsoft_Practices_EnterpriseLibrary_Common_ni+0x8060b
1074eeb8 60e90431 1247ff58 738c58e2 1247ff58 Microsoft_Practices_EnterpriseLibrary_Common_ni+0x7ff01
1074eeec 60e9b984 1247ff58 1246dbd4 00000000 Microsoft_Practices_EnterpriseLibrary_Common_ni+0x80431
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
您的应用程序是否正确加载然后崩溃了?
如果没有,您最好运行 Fusion Log Viewer 并查看哪些 dll 无法加载。
将 fusionlogvw.exe 复制到 qa 计算机上,在
HKLM\Software\Microsoft\Fusion
键下添加ForceLog
-DWORD 值 - 设置为0x1
。运行 fusionlogvw.exe,然后运行您的应用程序。您应该看到所有程序集绑定失败和成功的统计信息。
这应该可以让您了解哪些 dll 没有加载。
这篇帖子和这篇one 可能有用。
Is you app loading properly and then crashing?
If not you are better off running Fusion Log Viewer and see what dlls are failing to load.
copy the fusionlogvw.exe on the qa machine, add
ForceLog
-DWORD value - set to0x1
underHKLM\Software\Microsoft\Fusion
key.Run the fusionlogvw.exe, and then your application. You should see all assembly bind stats both failure and successes.
This should give an idea as to what dlls aren't loading up.
This post and this one might be useful.
确保两台机器都使用相同版本的.NET。尝试在另一个 QA 机器上运行它,看看问题是否仍然存在。目前使用 EntLib Logging,从未见过该错误 tbh
make sure both machines are on the same versions of the .NET. try running it on another QA box and see if the problem persists. Currently use EntLib Logging and never seen that error tbh