2

I have very strange thing I can't beat up for couple of days. I have a self-written .NET based 32-bit service (compiled with x86 flag), that has worked on Win 10 Pro 64-bit machine, which consumes DCOM component {6F17505C-4351-46AC-BC1E-CDE34BB53FAA} (OPC Server started as a Service). It worked for couple of months without problems before NY, but last week my service has failed to start with 0x80070005 Error.

System.UnauthorizedAccessException: An instance of the COM component with the CLSID {6F17505C-4351-46AC-BC1E-CDE34BB53FAA} could not be created by the IClassFactory because of the following error: 80070005 Access denied (exception HRESULT: 0x80070005 (E_ACCESSDENIED)). at System.RuntimeTypeHandle.CreateInstance(RuntimeType type, Boolean publicOnly, Boolean noCheck, Boolean& canBeCached, RuntimeMethodHandleInternal& ctor, Boolean& bNeedSecurityCheck) at System.RuntimeType.CreateInstanceSlow(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache, StackCrawlMark& stackMark) at System.RuntimeType.CreateInstanceDefaultCtor(Boolean publicOnly, Boolean skipCheckThis, Boolean fillCache, StackCrawlMark& stackMark) at System.Activator.CreateInstance(Type type, Boolean nonPublic) at System.Activator.CreateInstance(Type type) at OPCDA.NET.OpcServer.ConnectLocal(String SrvName) at OPCDA.NET.OpcServer.Connect(String SrvName) ...

Both services are running under local system account (SYSTEM), permissions are granted in dcomcnfg for component for Administrators and System, and in registry for HKEY_CLASSES_ROOT\AppID{6F17505C-4351-46AC-BC1E-CDE34BB53FAA} (well, I see no reason for checking permissions for that branch, but I've read a lot and tried it also). I've also tried to reinstall them all without success. Uninstalled windows updates - no luck. There are couple of products, installed by third party, which were installed in the meantime, but I believe it could not be harmful for DCOM communication. I've also tried creating user with admin rights and starting both services under this user.

I hope you can suggest me something useful in this strange situation.

Andrew Schulman
  • 8,561
  • 21
  • 31
  • 47
kosmo
  • 31
  • 1
  • 4
  • This is a bug in one of the Windows 10 updates that was then fixed with a more recent update. More details regarding a similar case at https://www.prosysopc.com/blog/sentrol-sdk-dcom-issues/ – Jouni Aro Feb 23 '18 at 15:12

1 Answers1

1

Well, I've contacted OPC Server manufacturer and support told me that (freely translated from German) "Since beginning of this year there are many error reports, telling that Windows Updates break OPC communication". So, I've uninstalled all updates since the end of December and - volia - it works now!

Support suggested me to run following batch:

wusa /uninstall /kb:4056888 /quiet /norestart
wusa /uninstall /kb:4056890 /quiet /norestart
wusa /uninstall /kb:4056891 /quiet /norestart
wusa /uninstall /kb:4056892 /quiet /norestart
wusa /uninstall /kb:4056893 /quiet /norestart
wusa /uninstall /kb:4056897 /quiet /norestart
wusa /uninstall /kb:4056898 /quiet /norestart

but I had none from listed installed. Pity, but I haven't listed any really uninstalled updates (could not find update history in Win10, can see only installed updates).

kosmo
  • 31
  • 1
  • 4