I am working with Windows 7, VS2010, SqlServer 2008.
My application takes data form a third party dll (which takes data from another process that must be running in the background) and processes the data and send it over a WCF service to the front end.
The application is done and does what it supposed to do. Now when I want to distribute it and Run it in IIS. I am facing a strange problem. The application get the data from a dll when I run it in IIS it fails and gives an error while connecting to the dll.
Retrieving the COM class factory for component with CLSID {FCEC6861-5866-4F9E9A09-7CC868C30A8B} failed due to the following error: 80070005 Access is denied. (Exception from HRESULT: 0x80070005 (E_ACCESSDENIED)).
After some research I found out going to component service and inside DCOM config I change the security of the dll to everyone. The error stopped.
But now I don't get the error but I don't get the data like when the software which provides the data is closed. But work ok with my ASP.net development server.
Also I found that when I run Visual Studio in administrator mode I must run the third party data software in administrative mode too.
The dll reference is not copied in bin folder automatically, it put in obj folder and I manually copied it but it does not work.
What I think happens is that the COM component is running in the same context as the caller and it needs elevated permissions to perform its job.
So:
My troubleshooting suggestion would be to have the IIS application pool that your app is running under changed to be local admin. If that works OK, restore the access rights on your DCOM to the defaults (before changing to everyone) and try again. You might also try to run the app pool under the local system account to see what happens. If that still works, you have confirmed this behavior to be the problem.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With