Microsoft KB Archive/254659

From BetaArchive Wiki

Starting Local COM Server Returns Error Code 0x80080005


The information in this article applies to:

  • Microsoft Windows 98 Second Edition
  • Microsoft Distributed Component Object Model (DCOM), version 1.2
  • Microsoft Windows 95
  • Microsoft Windows 98


When you start your computer without a network and then dynamically add a network (by inserting a PCMCIA network adapter or by using Dial-Up Networking), the first attempt to start a local COM server is unsuccessful if Distributed Component Object Model (DCOM) is installed.

The underlying error message is detailed in the following table.

Type Value
Standard Error Text Server Execution Failed
Error Code (hexadecimal) 0x80080005
Error Code (decimal) -2146959355
Error code (symbolic) CO_E_SERVER_EXEC_FAILURE


When there is no network, DCOM identifies the local computer using RPCSS with the loopback address ( When you dynamically add a network, remote procedure call (RPC) does not detect the new Internet Protocol (IP) address until it is reinitialized. However, COM initializes first and sends a request to RPC to locate the local server. This does not trigger an RPC reinitialization, and subsequent attempts to start the local server can succeed.


To work around this behavior, start the client program a second time.

The following code sample shows how to bypass the problem programmatically:

#include "stdafx.h"

int fIsWin9X(void)
    ZeroMemory(&info, sizeof(OSVERSIONINFO));
    info.dwOSVersionInfoSize = sizeof(OSVERSIONINFO);
    GetVersionEx( &info );
    if ( 4 == info.dwMajorVersion && VER_PLATFORM_WIN32_WINDOWS == info.dwPlatformId )
        return TRUE;
    return FALSE;

HRESULT myCoCreateInstance(
   REFCLSID rclsid,
   LPUNKNOWN pUnkOuter,
   DWORD dwClsContext,
   REFIID riid,
   LPVOID * ppv
    HRESULT hr = CoCreateInstance( rclsid, pUnkOuter, dwClsContext, riid, ppv );
    if ( CO_E_SERVER_EXEC_FAILURE == hr && fIsWin9X() )
        return CoCreateInstance( rclsid, pUnkOuter, dwClsContext, riid, ppv );
    return hr;


Microsoft has confirmed this to be a problem in Windows 95 and Windows 98 with DCOM 1.3 installed.

Additional query words: nic fail failed dun

Keywords : kberrmsg
Issue type : kbprb
Technology : kbAudDeveloper kbWin95search kbWin98search kbWin98SEsearch kbSDKSearch kbDCOM120 kbZNotKeyword3 kbWin98 kbWinSDKSearch kbWin98SE kbDCOMSearch

Last Reviewed: June 26, 2001
© 2001 Microsoft Corporation. All rights reserved. Terms of Use.