Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations gmmastros on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

RPC_S_SERVER_UNAVAILABLE what am i doing wrong?

Status
Not open for further replies.

NTmuncher

Programmer
Jan 31, 2001
6
GB
Hi

Ive been trying to use a VB6 COM object via DCOM.
I have 2 NT Server (both PDCs) and 1 NT Workstation.

Ive set registry entries as follows after registering COM object...

HKEY_LOCAL_MACHINE "Software\Microsoft\Ole"

"EnableDCOM" "Y"


HKEY_LOCAL_MACHINE &quot;Software\Classes\CLSID\<CLSID>&quot;

&quot;AppID&quot; &quot;<CLSID>&quot;


HKEY_LOCAL_MACHINE &quot;Software\Classes\AppID\<clsid>&quot;

&quot;DllSurrogate&quot; &quot;c:\\winnt\\system32\\dllhost.exe&quot;
&quot;RunAs&quot; &quot;Interactive User&quot;
&quot;AuthenticationLevel&quot; 2

And set up trusted relationship between two NT servers
(NT wrkstn is member of trusted domain).

used DCOMcnfg to allow connections from authenticated users
and domain users of trusted domains.

Im using TCP connection orientated protocol and Ive tried both specifying a port range (5000 - 5020) or using the default.

I use a C++ dll to invoke the DCOM using

CoCreateInstanceEx(blah)

using CONNECT level and specifing a username \ password recognised by all domains. requesting IUnknown ptr..

The situation is this...

If I install fresh NT wrkstn / server, apply registry changes and register COM object all works fine!!

When I use DCOMcnfg and alter connection protocol or alter default access, all goes T*ts up.

Sometimes the CLSID for my COM object dissapears from the registry!!!!

Ive got all settings as *i think* they should be and I get the RPC_S_SERVER_UNAVAILABLE hresult return from the
MULTI_QI structure of CoCreateInstanceEx.

I realise this message is very long, and I apologise, but I wanted to get as much detail as possible in the question!

any help appreciated.

PS there's a short but good summary of common COM problems here :

I found it very useful.
cheers.

J.
 
ah ha.... found some answers..

Needed to delete registry key
HKLM\Software\Microsoft\Rpc\Internet..

Seems IIS had an argument with DCOM about who got the ports.
In the end neither won, and nothing worked!

Still have problems specifing a port range for TCP/IP connection orientated protocol though....?
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top