3.1.4.5 Kill (Opnum 11)

This method is used to terminate the Internet services processes. This erases the IIS processes from memory, and is used to recover from failed instances of IIS processes.

The server can have all functionality through this interface disabled using actions taken local to the server machine. In this case the function MUST return an error when called (E_ERROR_RESOURCE_DISABLED) and MUST NOT perform any other action.

If the interface functionality is not disabled, the following SHOULD take place on the server when this method is called:

  • The method SHOULD terminate all processes involved in supporting the Internet services on the server.

How the processes are terminated is implementation-dependent.<7>

 HRESULT Kill();

This method has no parameters.

Return Values: A signed, 32-bit value indicating return status. If the method returns a negative value, it has failed. If the 12-bit facility code (bits 16–27) is set to 0x007, the value contains a Win32 error code in the lower 16 bits. 0 or positive values indicate success, with the lower 16 bits in positive nonzero values containing warnings or flags defined in the method implementation. For more information about HRESULT, see [MS-ERREF] section 2.1.

Each of the values that follow where the first byte contains 0x8007 is the HRESULT derived from the Win32 error code with the specified name.

The method MUST return S_OK (0x00000000) upon success.

Return value/code

Description

0x00000000

S_OK

The call was successful.

0x80070008

E_ERROR_NOT_ENOUGH_MEMORY

Not enough memory is available to process this command.

0x800710D5

E_ERROR_RESOURCE_DISABLED

The IIisServiceControl interface is disabled.