0
votes

I have a COM+ application consisting of a client DLL and many middle-tier DLLs. The application gets run by using an MSC application file.

When I am in die IDE and run my client DLL, I have the following run parameters to launch, run and debug my client DLL (this works great):

enter image description here

The theory is that I should be able to debug my middle-tier by running the DLL with the following parameters (I get the ProcessID from my COM+ Application in Component Services): enter image description here

Once it is running, I should then be able to start my client MSC application and that should allow me to attach and debug my middle tier. I have seen this working before. Running my Client DLL from the IDE or as an MSC application works without issues but when I try to debug my middle-tier, as described above, I get a "The RPC server is unavailable" error. I am running everything locally so I am not sure what server it is referring too. I have also made sure the following services are up-and-running: DCOM Server Process Launcher, Remote Procedure Call (RPC) and RPC Endpoint Mapper

Any idea what else could cause this error or what server it is trying to connect too?

1
The RPC server referred here is the COM "server" (in COM there's client and a server, it's - in general - not related to network, other machines, etc.). This message is very frequent, used mostly in out-of-process scenario and just means the process that "serves" COM objects (here it would be an instance of dllhost.exe) is not there, or is dead, or doesn't answer, etc. Not sure what you mean by "MSC".Simon Mourier
Are you running your debugger and process at the same permissions level? I would guess your server process/DLL is running at an administration level and maybe even with different credentials (like machine or system). I'd at least make sure you run your debugger with elevated with your administrator permissions.Joseph Willcoxson
@SimonMourier, thanks for the feedback. What you say makes sense but dllhost it there and seems to be working fine. MSC is a Microsoft management console file format. Some bloke implemented it at our company 10 years ago but now nobody really knows how it works...Johan
@JosephWillcoxson, my eyes start to go wonky when people talk about permission levels. What I do know is that I run my IDE as Administrator and also my host app. How would I check what permissions are used for which level? Thanks.Johan
I wouldn't start dllhost myself. Instead, have you tried attach to it once it's started?Simon Mourier

1 Answers

0
votes

It turns out there were more than 1 version of the DLLs registered on my pc. I inherited the pc from a previous employee and noticed some install files of the application on the C drive (all my stuff is on the E drive). I ran the uninstall procedure on the C drive that also unregistered some DLLs and my RPC problem was resolved.