Jaa


Walkthrough: Non-Hosted Event Provider Deployment

This walkthrough shows how to deploy a non-hosted event provider for an instance of Notification Services. You use these deployment steps when a non-hosted event provider is on a server that does not run Notification Services engine components.

Note

All deployments of Notification Services are unique. Use the procedures in this topic as a guideline for developing and testing your own deployment instructions.

Prerequisites

Before you deploy a non-hosted event provider, verify that you have installed the non-hosted event provider and granted all necessary Microsoft Windows permissions to the accounts used by the event provider. For the purpose of this walkthrough, the account used by the non-hosted event provider is DOMAIN\EventProvider Windows account.

Also verify that TCP/IP or the named pipes network protocol is enabled on the Database Engine. In SQL Server 2005, these network protocols are disabled by default. For more information, see SQL Server Surface Area Configuration.

Non-Hosted Event Provider Server Tasks

Perform the following steps on the non-hosted event provider server. However, if the non-hosted event provider is located on a server where the instance is already registered, you can skip the steps on this server.

Step 1: Install Notification Services Client Components

  1. Install Notification Services client components.

    For more information, see Installing SQL Server Notification Services.

Step 2: Register the Instance of Notification Services

  1. On the Start menu, point to All Programs, point to Microsoft SQL Server 2005, point to Notification Services, and then click Notification Services Command Prompt to open a Notification Services Command Prompt window.

  2. Type the following command to register the instance without creating the Windows service.

    nscontrol register -name instanceName -server databaseServer

SQL Server Tasks

You must grant SQL Server and database permissions to the DOMAIN\EventProvider account. If you have SQL Server client components installed on the non-hosted event provider server, you can perform these steps on that server.

Grant SQL Server and Database Permissions

  1. Open a Command Prompt window.

  2. At the command prompt, type the following command to create a SQL Server login for the DOMAIN\EventProvider account:

    sqlcmd -E -S databaseServer -Q "CREATE LOGIN [DOMAIN\EventProvider] FROM WINDOWS;"

  3. Type the following command to grant the DOMAIN\EventProvider account access to the instance database and to add the account to the NSEventProvider database role:

    sqlcmd -E -SdatabaseServer-Q "USEinstanceDatabase;

    **    CREATE USER [DOMAIN\EventProvider];**

    **    EXEC sp_addrolemember N'NSEventProvider', N'DOMAIN\EventProvider';"**

  4. If you have separate databases for applications, type the following command to grant the DOMAIN\EventProvider account access to an application database and to add the account to the NSEventProvider database role:

    sqlcmd -E -S databaseName -Q "USE applicationDatabase

    **    CREATE USER [DOMAIN\EventProvider];**

    **    EXEC sp_addrolemember N'NSEventProvider', N'DOMAIN\EventProvider';"**

    If the instance hosts multiple applications, repeat this step for each application database.

You have now deployed the non-hosted event provider. You should be able to submit events to the notification applications.

Troubleshooting

If you cannot submit events, check the status of the instance by running the following command from the Notification Services command prompt:

nscontrol status-name instanceName

Verify that the instance of Notification Services and its applications are enabled. For more information, see Viewing the Status of Instances, Applications, and Components.

Also, check the Windows Application log for errors. For more information, see Troubleshooting Notification Services.

See Also

Concepts

Deploying an Instance of Notification Services
Deploying a Non-Hosted Event Provider
Deploying a Subscription Management Interface

Other Resources

Deploying Notification Services

Help and Information

Getting SQL Server 2005 Assistance