Docstoc

Hosting Services Windows Service Installation

Document Sample
Hosting Services Windows Service Installation Powered By Docstoc
					                       Hosting Services Windows Service
                                                                       Installation and Configuration
                                                                                             Prepared for
                                                                                        Microsoft
                                                                                        Thursday, 4 March 2010
                                                                                        Version 1.0 Release
                                                                                        Prepared by
                                                                                        Mark Stevenson (MCS)
                                                                                        Sr. Consultant
                                                                                        markstev@microsoft.com




                                                                                                                 Page 1
Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
Prepared by Mark Stevenson (MCS)
"caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
Table of Contents
Hosting Services Windows Service .......................................................................................................... 1

Installation and Configuration ................................................................................................................... 1

1     Introduction .......................................................................................................................................... 3

2     Installation ............................................................................................................................................ 4
    Dependencies ........................................................................................................................................... 4
    Installing the service ................................................................................................................................. 4

3     Configure the service .......................................................................................................................... 8

4     Set the identity of the service ............................................................................................................. 9

5     Appendix ............................................................................................................................................. 10
    5.1      Microsoft.Hosting.exe.config contents .......................................................................................... 10




                                                                                                                                                         Page 2
                                   Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                                   Prepared by Mark Stevenson (MCS)
                                   "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
1         INTRODUCTION
    The Windows Service based host for IIS7 Hosting services includes all of the functionality of the IIS7
    based version of the host. The only difference is that the services are hosted in a Windows Service
    instead of an IIS7 based web application. This is useful for managing configurations where IIS7 is not
    installed or running the hosting services on the web is not desired.




                                                                                                                 Page 3
                         Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                         Prepared by Mark Stevenson (MCS)
                         "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
2         INSTALLATION

Dependencies
    Prior to installation, the application server role must be setup in the server role management. This
    installer requires the .NET Framework 3.0 as well as the Windows 3.1 installer.


    Under server features, make sure the WCF Activation feature is installed.




Installing the service
    To install the Service based host, double click on the HostingWindowsService.msi file to start the
    installation process.




                                                                                                                 Page 4
                         Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                         Prepared by Mark Stevenson (MCS)
                         "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
Choose Next to select the location of the installed files.




                                                                                                              Page 5
                      Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                      Prepared by Mark Stevenson (MCS)
                      "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
Set the folder and make a note of the installation location of the service to make configuration changes.
Choose Next to confirm installation and allow the install to continue.




                                                                                                             Page 6
                     Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                     Prepared by Mark Stevenson (MCS)
                     "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
When the install is complete choose close to exit the install.( Figure 1 - Complete)




Figure 1 - Complete




                                                                                                              Page 7
                      Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                      Prepared by Mark Stevenson (MCS)
                      "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
3         CONFIGURE THE SERVICE

    The service must be configured by modifying the application configuration file in the installation
    directory. The file is named Microsoft.Hosting.exe.config.
    The entire contents of the file are listed in the appendix. The configuration file is very similar to the
    configuration of the web based host with the addition of the following host tag for each service.


    By default the windows service will run on http://localhost:8000


    You may change the port or change the name to be the machine name as required. In addition each
    service has its own path as in the following example which is /WebProvisioning.


    <host>
           <baseAddresses>
           <add baseAddress="http://localhost:8000/WebProvisioning"/>
         </baseAddresses>
    </host>


    Make note of the path for each service as it will be needed to update the binding configuration of the
    client. If you have a client that calls the IIS7 based version of the services. All you need to do is
    change the endpoint address to point to the Windows service based host.


    <endpoint address="http://IIS7Live/HostingServices/WebProvisioningService.svc"
         binding="wsHttpBinding" bindingConfiguration="WSHttpBinding_IWebProvisioningService"
         contract="IWebProvisioningService" name="WSHttpBinding_IWebProvisioningService">
                  <identity>
                           <servicePrincipalName value=“host/iisserver.iishosting.com”/>
                  </identity>
    </endpoint>
    Becomes
    <endpoint address="http://localhost:8000/WebProvisioning"
         binding="wsHttpBinding" bindingConfiguration="WSHttpBinding_IWebProvisioningService"
          contract="IWebProvisioningService" name="WSHttpBinding_IWebProvisioningService">
                  <identity>
                           <servicePrincipalName value=“host/iisserver.iishosting.com”/>
                  </identity>
    </endpoint>
                                                                                                                  Page 8
                          Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                          Prepared by Mark Stevenson (MCS)
                          "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
4         SET THE IDENTITY OF THE SERVICE
    By default the service installs under the local system account. If you wish for the service to
    communicate across the network or it needs administrative access, you much change the identity of
    the service by configuring the service in the services control panel. The service name is
    WCFHostingService as seen in the following figure.




                                                                                                                Page 9
                        Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                        Prepared by Mark Stevenson (MCS)
                        "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
5     APPENDIX

5.1   Microsoft.Hosting.exe.config contents

 <?xml version="1.0" encoding="utf-8" ?>
<configuration xmlns="http://schemas.microsoft.com/.NetConfiguration/v2.0">
      <system.serviceModel>
            <services>

                  <service
name="Microsoft.Hosting.Web.ServiceImplementation.WebProvisioningService"
behaviorConfiguration="Microsoft.Hosting.Web.ServiceImplementation.WebProvisi
oningService_Behavior">
                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.Web.ServiceContracts/2007/04"
contract="Microsoft.Hosting.Web.ServiceContracts.IProvisioningService"/>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                        <host>
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/WebProvisioning"/>
                               </baseAddresses>
                        </host>

                  </service>
                  <service
name="Microsoft.Hosting.Web.ServiceImplementation.WebManagementService"
behaviorConfiguration="Microsoft.Hosting.Web.ServiceImplementation.WebManagem
entService_Behavior">
                        <host>
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/WebManagement"/>
                               </baseAddresses>
                        </host>

                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.Web.ServiceContracts/2007/04"
contract="Microsoft.Hosting.Web.ServiceContracts.IManagementService"/>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                  </service>
                  <service
name="Microsoft.Hosting.Web.ServiceImplementation.WebQueryService"
behaviorConfiguration="Microsoft.Hosting.Web.ServiceImplementation.WebQuerySe
rvice_Behavior">
                        <host>
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/WebQuery"/>
                               </baseAddresses>
                        </host>

                                                                                                         Page 10
                 Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                 Prepared by Mark Stevenson (MCS)
                 "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.Web.ServiceContracts/2007/04"
contract="Microsoft.Hosting.Web.ServiceContracts.IQueryService"/>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                  </service>
                  <service
name="Microsoft.Hosting.Ftp.ServiceImplementation.FtpProvisioningService"
behaviorConfiguration="Microsoft.Hosting.Ftp.ServiceImplementation.FtpProvisi
oningService_Behavior">
                        <host>
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/FTPProvisioning"/>
                               </baseAddresses>
                        </host>
                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.Ftp.ServiceContracts/2007/04"
contract="Microsoft.Hosting.Ftp.ServiceContracts.IProvisioningService"/>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                  </service>
                  <service
name="Microsoft.Hosting.Ftp.ServiceImplementation.FtpManagementService"
behaviorConfiguration="Microsoft.Hosting.Ftp.ServiceImplementation.FtpManagem
entService_Behavior">
                        <host>
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/FTPManagement"/>
                               </baseAddresses>
                        </host>

                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.Ftp.ServiceContracts/2007/04"
contract="Microsoft.Hosting.Ftp.ServiceContracts.IManagementService"/>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                  </service>
                  <service
name="Microsoft.Hosting.Ftp.ServiceImplementation.FtpQueryService"
behaviorConfiguration="Microsoft.Hosting.Ftp.ServiceImplementation.FtpQuerySe
rvice_Behavior">
                        <host>
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/FTPQuery"/>
                               </baseAddresses>
                        </host>
                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.Ftp.ServiceContracts/2007/04"
contract="Microsoft.Hosting.Ftp.ServiceContracts.IQueryService"/>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                  </service>
                  <service
name="Microsoft.Hosting.ContentStorage.ServiceImplementation.ContentStoragePr
                                                                                                         Page 11
                 Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                 Prepared by Mark Stevenson (MCS)
                 "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
ovisioningService"
behaviorConfiguration="Microsoft.Hosting.ContentStorage.ServiceImplementation
.ContentStorageProvisioningService_Behavior">
                         <host>
                                <baseAddresses>
                                      <add
baseAddress="http://localhost:8000/ContentProvisioning"/>
                                </baseAddresses>
                         </host>
                         <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.ContentStorage.ServiceContracts/20
07/04"
contract="Microsoft.Hosting.ContentStorage.ServiceContracts.IProvisioningServ
ice"/>
                         <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                   </service>
                   <service
name="Microsoft.Hosting.ContentStorage.ServiceImplementation.ContentStorageMa
nagementService"
behaviorConfiguration="Microsoft.Hosting.ContentStorage.ServiceImplementation
.ContentStorageManagementService_Behavior">
                         <host>
                                <baseAddresses>
                                      <add
baseAddress="http://localhost:8000/ContentManagement"/>
                                </baseAddresses>
                         </host>
                         <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.ContentStorage.ServiceContracts/20
07/04"
contract="Microsoft.Hosting.ContentStorage.ServiceContracts.IManagementServic
e"/>
                         <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                   </service>
                   <service
name="Microsoft.Hosting.ContentStorage.ServiceImplementation.ContentStorageQu
eryService"
behaviorConfiguration="Microsoft.Hosting.ContentStorage.ServiceImplementation
.ContentStorageQueryService_Behavior">
                         <host>
                                <baseAddresses>
                                      <add
baseAddress="http://localhost:8000/ContentStorage"/>
                                </baseAddresses>
                         </host>
                         <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.ContentStorage.ServiceContracts/20
07/04"
contract="Microsoft.Hosting.ContentStorage.ServiceContracts.IQueryService"/>
                         <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                   </service>
                   <service
name="Microsoft.Hosting.UserAccount.ServiceImplementation.UserAccountProvisio
ningService"
                                                                                                         Page 12
                 Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                 Prepared by Mark Stevenson (MCS)
                 "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
behaviorConfiguration="Microsoft.Hosting.UserAccount.ServiceImplementation.Us
erAccountProvisioningService_Behavior">
                        <host>
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/UserProvisioning"/>
                               </baseAddresses>
                        </host>
                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.UserAccount.ServiceContracts/2007/
04"
contract="Microsoft.Hosting.UserAccount.ServiceContracts.IProvisioningService
"/>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                  </service>
                  <service
name="Microsoft.Hosting.UserAccount.ServiceImplementation.UserAccountManageme
ntService"
behaviorConfiguration="Microsoft.Hosting.UserAccount.ServiceImplementation.Us
erAccountManagementService_Behavior">
                        <host>
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/UserManagement"/>
                               </baseAddresses>
                        </host>
                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.UserAccount.ServiceContracts/2007/
04"
contract="Microsoft.Hosting.UserAccount.ServiceContracts.IManagementService"/
>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                  </service>
                  <service
name="Microsoft.Hosting.UserAccount.ServiceImplementation.UserAccountQuerySer
vice"
behaviorConfiguration="Microsoft.Hosting.UserAccount.ServiceImplementation.Us
erAccountQueryService_Behavior">
                        <host>
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/UserQuery"/>
                               </baseAddresses>
                        </host>
                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.UserAccount.ServiceContracts/2007/
04" contract="Microsoft.Hosting.UserAccount.ServiceContracts.IQueryService"/>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                  </service>
                  <service
name="Microsoft.Hosting.Sql.ServiceImplementation.SqlProvisioningService"
behaviorConfiguration="Microsoft.Hosting.Sql.ServiceImplementation.SqlProvisi
oningService_Behavior">
                        <host>
                                                                                                         Page 13
                 Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                 Prepared by Mark Stevenson (MCS)
                 "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/SQLProvisioning"/>
                               </baseAddresses>
                        </host>
                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.Sql.ServiceContracts/2007/04"
contract="Microsoft.Hosting.Sql.ServiceContracts.IProvisioningService"/>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                  </service>
                  <service
name="Microsoft.Hosting.Sql.ServiceImplementation.SqlManagementService"
behaviorConfiguration="Microsoft.Hosting.Sql.ServiceImplementation.SqlManagem
entService_Behavior">
                        <host>
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/SQLManagement"/>
                               </baseAddresses>
                        </host>
                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.Sql.ServiceContracts/2007/04"
contract="Microsoft.Hosting.Sql.ServiceContracts.IManagementService"/>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                  </service>
                  <service
name="Microsoft.Hosting.Sql.ServiceImplementation.SqlQueryService"
behaviorConfiguration="Microsoft.Hosting.Sql.ServiceImplementation.SqlQuerySe
rvice_Behavior">
                        <host>
                               <baseAddresses>
                                     <add
baseAddress="http://localhost:8000/SQLQuery"/>
                               </baseAddresses>
                        </host>
                        <endpoint binding="wsHttpBinding"
bindingNamespace="http://Microsoft.Hosting.Sql.ServiceContracts/2007/04"
contract="Microsoft.Hosting.Sql.ServiceContracts.IQueryService"/>
                        <endpoint contract="IMetadataExchange"
binding="mexHttpBinding" address="mex"/>
                  </service>
            </services>
            <bindings>
                  <wsHttpBinding>
                        <binding name="wsHttpBinding_Unsecure">
                               <security mode="None"/>
                        </binding>
                  </wsHttpBinding>
            </bindings>
            <behaviors>
                  <serviceBehaviors>
                        <behavior name="returnFaults">
                               <serviceDebug
includeExceptionDetailInFaults="true"/>
                        </behavior>
                                                                                                         Page 14
                 Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                 Prepared by Mark Stevenson (MCS)
                 "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
                        <behavior
name="Microsoft.Hosting.Web.ServiceImplementation.WebProvisioningService_Beha
vior">
                              <serviceDebug
includeExceptionDetailInFaults="false"/>
                              <serviceMetadata httpGetEnabled="true"/>
                        </behavior>
                        <behavior
name="Microsoft.Hosting.Web.ServiceImplementation.WebManagementService_Behavi
or">
                              <serviceDebug
includeExceptionDetailInFaults="false"/>
                              <serviceMetadata httpGetEnabled="true"/>
                        </behavior>
                        <behavior
name="Microsoft.Hosting.Web.ServiceImplementation.WebQueryService_Behavior">
                              <serviceDebug
includeExceptionDetailInFaults="true"/>
                              <serviceMetadata httpGetEnabled="true"/>
                        </behavior>
                        <behavior
name="Microsoft.Hosting.Ftp.ServiceImplementation.FtpProvisioningService_Beha
vior">
                              <serviceDebug
includeExceptionDetailInFaults="false"/>
                              <serviceMetadata httpGetEnabled="true"/>
                        </behavior>
                        <behavior
name="Microsoft.Hosting.Ftp.ServiceImplementation.FtpManagementService_Behavi
or">
                              <serviceDebug
includeExceptionDetailInFaults="false"/>
                              <serviceMetadata httpGetEnabled="true"/>
                        </behavior>
                        <behavior
name="Microsoft.Hosting.Ftp.ServiceImplementation.FtpQueryService_Behavior">
                              <serviceDebug
includeExceptionDetailInFaults="true"/>
                              <serviceMetadata httpGetEnabled="true"/>
                        </behavior>
                        <behavior
name="Microsoft.Hosting.UserAccount.ServiceImplementation.UserAccountProvisio
ningService_Behavior">
                              <serviceDebug
includeExceptionDetailInFaults="false"/>
                              <serviceMetadata httpGetEnabled="true"/>
                        </behavior>
                        <behavior
name="Microsoft.Hosting.UserAccount.ServiceImplementation.UserAccountManageme
ntService_Behavior">
                              <serviceDebug
includeExceptionDetailInFaults="false"/>
                              <serviceMetadata httpGetEnabled="true"/>
                        </behavior>
                        <behavior
name="Microsoft.Hosting.UserAccount.ServiceImplementation.UserAccountQuerySer
vice_Behavior">
                                                                                                         Page 15
                 Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                 Prepared by Mark Stevenson (MCS)
                 "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7
                                <serviceDebug
includeExceptionDetailInFaults="true"/>
                                <serviceMetadata httpGetEnabled="true"/>
                          </behavior>
                          <behavior
name="Microsoft.Hosting.ContentStorage.ServiceImplementation.ContentStoragePr
ovisioningService_Behavior">
                                <serviceDebug
includeExceptionDetailInFaults="false"/>
                                <serviceMetadata httpGetEnabled="true"/>
                          </behavior>
                          <behavior
name="Microsoft.Hosting.ContentStorage.ServiceImplementation.ContentStorageMa
nagementService_Behavior">
                                <serviceDebug
includeExceptionDetailInFaults="false"/>
                                <serviceMetadata httpGetEnabled="true"/>
                          </behavior>
                          <behavior
name="Microsoft.Hosting.ContentStorage.ServiceImplementation.ContentStorageQu
eryService_Behavior">
                                <serviceDebug
includeExceptionDetailInFaults="true"/>
                                <serviceMetadata httpGetEnabled="true"/>
                          </behavior>
                          <behavior
name="Microsoft.Hosting.Sql.ServiceImplementation.SqlProvisioningService_Beha
vior">
                                <serviceDebug
includeExceptionDetailInFaults="false"/>
                                <serviceMetadata httpGetEnabled="true"/>
                          </behavior>
                          <behavior
name="Microsoft.Hosting.Sql.ServiceImplementation.SqlManagementService_Behavi
or">
                                <serviceDebug
includeExceptionDetailInFaults="false"/>
                                <serviceMetadata httpGetEnabled="true"/>
                          </behavior>
                          <behavior
name="Microsoft.Hosting.Sql.ServiceImplementation.SqlQueryService_Behavior">
                                <serviceDebug
includeExceptionDetailInFaults="true"/>
                                <serviceMetadata httpGetEnabled="true"/>
                          </behavior>
                   </serviceBehaviors>
             </behaviors>
       </system.serviceModel>



     </configuration>




                                                                                                         Page 16
                 Hosting Services Windows Service, Installation and Configuration, Version 1.0 Release
                 Prepared by Mark Stevenson (MCS)
                 "caf57516-ab3a-4613-9511-ea4eedc5dbf2.doc" last modified on 4 Mar. 10, Rev 7

				
DOCUMENT INFO