THE SQL Server Blog Spot on the Web

Welcome to SQLblog.com - The SQL Server blog spot on the web Sign in | |
in Search

The Bit Bucket (Greg Low): IDisposable

Ramblings of Greg Low (SQL Server MVP, MCM and Microsoft RD) - SQL Down Under

SQL Server 2008 R2: StreamInsight changes at RTM: Event Flow Debugger and Management Interface Security

In CTP3, I found setting up the StreamInsight Event Flow Debugger fairly easy. For RTM, a number of security changes were made.

First config: To be able to connect to the management interface, your user must be added to the Performance Log Users group. After you make this change, you must log off and log back on as the token is only added to your login token when you log on. I forgot this and spent ages trying to work out why I couldn't connect.

Second config: You need to reserve the URL that the management service will be exposed on. For current operating systems, this involves a command like:

netsh http add urlacl url=http://*:8090/StreamInsight/MSSQLSERVER user=GREGWIN7\Greg

This must be executed from a command prompt with elevated privileges (ie: right-click command prompt and Run As Administrator). This says that my user is allowed to use the URL reserved above. The user specified would need to be the user that is the identity your StreamInsight server would run as.

Third config: You need to open a WCF endpoint. I did this by declaring the following members:

private WSHttpBinding _binding = null;

private ServiceHost _host = null;

and then configuring and opening the host as:

_host = new ServiceHost(_server.CreateManagementService());

if (_binding == null)

{

  _binding = new WSHttpBinding(SecurityMode.Message);

  _binding.HostNameComparisonMode =

                  HostNameComparisonMode.WeakWildcard;

}

_host.AddServiceEndpoint

               (typeof(IManagementService),

                _binding,

                @"http://localhost:8090/StreamInsight/MSSQLSERVER");

_host.Open();

Once this was working I could connect to the endpoint using Event Flow Debugger, using the address in the AddServiceEndpoint call.

Another thing that tripped me up at first was that my app was too UI-bound and the management service wasn't responding in a timely manner. I either saw timeouts on connection or I saw a message telling me that my server was too busy. Turns out that was an accurate message. I just hadn't believed it while I couldn't get it working!

 

 

Published Saturday, May 08, 2010 8:45 PM by Greg Low

Comment Notification

If you would like to receive an email when updates are made to this post, please register here

Subscribe to this post's comments using RSS

Comments

No Comments

Leave a Comment

(required) 
(required) 
Submit

This Blog

Syndication

Tags

No tags have been created or used yet.
Powered by Community Server (Commercial Edition), by Telligent Systems
  Privacy Statement