Monday, October 17, 2016

A connection cannot be made. Ensure that the server is running. Sql Server Analysis Services. ADOMD client




Error again on an application that worked before!!! Aaah! this is what we face every other day. in the tech world. 
Without going into details of those errors, let's focus on an error message as follows:- 
"A connection cannot be made. Ensure that the server is running." 
and then the inner exception message 

INNER EXCEPTION MESSAGE
===========================
Unable to write data to the transport connection: An existing connection was forcibly closed by the remote host.

so yes i am talking about a .Net application trying to connect to SSAS (Sql server Analysis services) in order to process a cube.
so the cube was already there, and it gets processed every night smoothly but how come if i try to process the cube manually via the application, it results in an error! 

well, looking at the error it gives you a feel that the following might have happened 
  •  Analysis services aren't running
  • OR it has something to do with the Sql browser service 
  • OR some network restriction
hmmm ... Not any of above! then you can follow the remaining post :) 

The issue was that the user we used to launch the application doesn't have rights on SSAS. You need to launch your .Net application with a user account having Administrator rights on SSAS ( Shift - Right click-> Run as User)

here is how to do assign rights in SSAS: - 
  • Start SSMS
  • Connect Analysis services
  • Right click on the server name and click properties
  • As shown below, add the desired user

hope that helps!

No comments:

Post a Comment