dbTalk Databases Forums  

import .cab Analysis Services DB on website

microsoft.public.sqlserver.olap microsoft.public.sqlserver.olap


Discuss import .cab Analysis Services DB on website in the microsoft.public.sqlserver.olap forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
wekrato
 
Posts: n/a

Default import .cab Analysis Services DB on website - 02-03-2006 , 06:01 AM






Hi!

I want to offer a web site/web service where one can import .cab Files
from Analysis Services databases to process them further.

I tried to run the msmdarch tool within an batch file from an execution
site (as described in
http://www.aspheute.com/artikel/20010220.htm), but I get an error when
it comes to the msmdarch command. (although the same command works in a
windows shell).
Are there some security settings one needs to get this running?

Are there other ways to approach this?
Could the OLAP Manager Add-In Kit help with this?

If anybody has any idea on this, please let me know.

Thanks
Werner


Reply With Quote
  #2  
Old   
Jéjé
 
Posts: n/a

Default Re: import .cab Analysis Services DB on website - 02-03-2006 , 08:58 AM






what is the error?
how do you execute the command line? (from an ASP.NET application?)
which user account is used to execute the batch file?

"wekrato" <register (AT) sosgmbh (DOT) at> wrote

Quote:
Hi!

I want to offer a web site/web service where one can import .cab Files
from Analysis Services databases to process them further.

I tried to run the msmdarch tool within an batch file from an execution
site (as described in
http://www.aspheute.com/artikel/20010220.htm), but I get an error when
it comes to the msmdarch command. (although the same command works in a
windows shell).
Are there some security settings one needs to get this running?

Are there other ways to approach this?
Could the OLAP Manager Add-In Kit help with this?

If anybody has any idea on this, please let me know.

Thanks
Werner




Reply With Quote
  #3  
Old   
 
Posts: n/a

Default Re: import .cab Analysis Services DB on website - 02-05-2006 , 04:12 AM



The user that is executing msmdarch needs to be a member of the Olap
Administrators group. If you are executing the batch command from an
ASP.NET application the user will either be ASPNET or NETWORK SERVICE by
default depending on whether you are running IIS 5 or 6.

--
Regards
Darren Gosbell [MCSD]
Blog: http://www.geekswithblogs.net/darrengosbell

In article <enL3EJNKGHA.2064 (AT) TK2MSFTNGP09 (DOT) phx.gbl>,
willgart_A_ (AT) hotmail_A_ (DOT) com says...
Quote:
what is the error?
how do you execute the command line? (from an ASP.NET application?)
which user account is used to execute the batch file?

"wekrato" <register (AT) sosgmbh (DOT) at> wrote in message
news:1138966199.002989.108430 (AT) g49g2000cwa (DOT) googlegroups.com...
Hi!

I want to offer a web site/web service where one can import .cab Files
from Analysis Services databases to process them further.

I tried to run the msmdarch tool within an batch file from an execution
site (as described in
http://www.aspheute.com/artikel/20010220.htm), but I get an error when
it comes to the msmdarch command. (although the same command works in a
windows shell).
Are there some security settings one needs to get this running?

Are there other ways to approach this?
Could the OLAP Manager Add-In Kit help with this?

If anybody has any idea on this, please let me know.

Thanks
Werner





Reply With Quote
  #4  
Old   
wekrato
 
Posts: n/a

Default Re: import .cab Analysis Services DB on website - 02-06-2006 , 03:25 AM



Hi folks!

Thanks for your answers.
I am using this function to execute the command:
Executor.ExecWaitWithCapture(strCmd, tf, ref output, ref error);

My batch command goes like this:
F:\PROGRA~1\MIA538~1\Bin\msmdarch /r KRA F:\PROGRA~1\MIA538~1\DATA
%1.CAB
if errorlevel 1 goto Fehler

This way I notice there is an error, but have no idea how to check
which error it is.

I turned Anonymous access off and used impersonate inside the code, so
the user must be the same as my local user, am I right?
And if I put the command in a "DOS-Window" it works. Strange, huh?
I am using II6 and I put both ASPNET User and NETWORK SERVICE user in
the Olap Administrators group, but it did not change anything. (I use
II6)

I have a very short response time, could it be that it checks for the
errorlevel too soon?

Nice regards
Werner


Reply With Quote
  #5  
Old   
 
Posts: n/a

Default Re: import .cab Analysis Services DB on website - 02-06-2006 , 05:07 AM



In article <1139217952.001405.168190 (AT) g44g2000cwa (DOT) googlegroups.com>,
register (AT) sosgmbh (DOT) at says...
Quote:
I turned Anonymous access off and used impersonate inside the code, so
the user must be the same as my local user, am I right?

Sorry, but this is not right.

If you have not set up Kerberos authentication and are only using NTLM,
the user authentication will not pass from Client to Web Server to
Analysis Server. NTLM authentication has a security feature that will
only allow it to do one "hop" (from Client to Web Server). The users
credentials will not be passed during the second (or subsequent) "hops"
(ie. from Web Server to AS Server). I think from Web Server to Analysis
Server it will fall back to using Guest access.

If you are using IIS 6 in the above scenario I would turn off
impersonation and set up the account in the application pool that is
running your ASP.NET site in the Olap Administrators group. This should
allow it to have permission to restore a database.

--
Regards
Darren Gosbell [MCSD]
Blog: http://www.geekswithblogs.net/darrengosbell


Reply With Quote
  #6  
Old   
wekrato
 
Posts: n/a

Default Re: import .cab Analysis Services DB on website - 02-06-2006 , 09:10 AM



Thanks Darren for your answer.

Now I got rid of the error, but the database still won't restore.
Here is what I did:
- Set up the thing with the application pool and turned to Network
Service.
- Assigned Network Service into the OLAP Administrator Group

The imported database just does not show up in the list of databases in
the Analysis-Manager.
I could not find an entry in the system logs either. Where could I find
the error messages of msmdarch?

Is there a way to get it running under IIS 5.1 as well? Would be nice,
because the delevepment platform is Win XP.

Nice regards
Werner


Reply With Quote
  #7  
Old   
 
Posts: n/a

Default Re: import .cab Analysis Services DB on website - 02-07-2006 , 03:57 AM



I cannot remember if you were already doing this or not, but you might
want to try redirecting the output from msmdarch to a file using the
command line redirection (">")

In the example below (which I pinched from Books OnLine) I added the
parameter to get msmdarch to log it's actions and also added a command
line redirection to capture any error messages that msmdarch might be
throwing.

eg.

"\Program Files\Microsoft Analysis Services\Bin\msmdarch" /r myserver
"\Program Files\Microsoft Analysis Services\Data\"
"\My archives\server myserver\FoodMart 2000.cab"
"\My archives\server myserver\FoodMart 2000 restore.log" > "\My archives
\server myserver\restore_output.log"


You should be able to get your solution running under IIS 5.1 without
any problems. The main different is that the default account that it
uses for ASP.Net applications is different. IIS 5.1 uses the local
ASPNET user on your workstation instead of using NETWORK SERVICE. If
your AS server is on a different machine, the best thing to do would be
to set up the impersonation tag in the web.config to use a fixed user
account.

--
Regards
Darren Gosbell [MCSD]
Blog: http://www.geekswithblogs.net/darrengosbell

In article <1139238616.078006.229670 (AT) o13g2000cwo (DOT) googlegroups.com>,
register (AT) sosgmbh (DOT) at says...
Quote:
Thanks Darren for your answer.

Now I got rid of the error, but the database still won't restore.
Here is what I did:
- Set up the thing with the application pool and turned to Network
Service.
- Assigned Network Service into the OLAP Administrator Group

The imported database just does not show up in the list of databases in
the Analysis-Manager.
I could not find an entry in the system logs either. Where could I find
the error messages of msmdarch?

Is there a way to get it running under IIS 5.1 as well? Would be nice,
because the delevepment platform is Win XP.

Nice regards
Werner



Reply With Quote
  #8  
Old   
wekrato
 
Posts: n/a

Default Re: import .cab Analysis Services DB on website - 02-07-2006 , 07:08 AM



Hi Darren!

Thanks again for your answer.
I tried with the .log file, but it is not generated. The _output.log is
generated but empty.

Sorry to say that we are back to the error, even on the IIS 6 machine.
I found out that I have been using the wrong path for a while which
only worked on the development machine. It is rather strange If I use
the wrong path, the errorlevel is zero. and - of course - nothing is
imported.

I checked the access date of the .cab but it looks like it is never
accessed.

Does the NETWORK SERVICE account need more rights than being in the
OLAP Admin group?

Which user could I impersonate to? What specialties would that user
need?
I tried on the IIS 6 with a newly generated user and then the website
could not be loaded anymore, that's why I switched back to NETWORK
SERVICE.

Do you think it is possible to get this running?

Thanks.
Nice regards
Werner


Reply With Quote
  #9  
Old   
wekrato
 
Posts: n/a

Default Re: import .cab Analysis Services DB on website - 02-07-2006 , 10:05 AM



Hi all!

I thought about a different approach.
Now I have found out that the .cab-File is a Zip-File.
Would it be possible to import the database by manually copying the
files from the .cab-File into the Analysis Services Data directory?

Which extra commands are necessary to get this running?

Does anybody have comments on this or some new hints for the trials
with msmdarch?

Regards
Werner


Reply With Quote
  #10  
Old   
 
Posts: n/a

Default Re: import .cab Analysis Services DB on website - 02-08-2006 , 04:51 AM



I don't think NETWORK SERVICE needs anything more from an AS perspective
than being in the Olap Admin group.

The NETWORK SERVICE account is just the default account that IIS 6 uses.
There is no reason you could not set up a domain account and use that.
The account would need to be in the olap administrators group on the AS
server and would need to be setup as either the identity in the app pool
or in the <identity ... /> tag in the web.config of the application. I'm
not sure if you would need any special permissions on the web server to
be able to run executables from the command line.

Quote:
Do you think it is possible to get this running?
This is not really the type of thing I have ever tried to do and I don't
know if a web app would have been my first choice for doing AS database
restores, but then I don't know what other factors are involved at your
end.

Have you seen the AS Operations Guide? It lists a number of ways of
moving databases around. It might give you some hints for a different
way of doing this.
http://www.microsoft.com/technet/pro...ntain/anservog.
mspx

--
Regards
Darren Gosbell [MCSD]
Blog: http://www.geekswithblogs.net/darrengosbell

In article <1139317739.406788.160410 (AT) o13g2000cwo (DOT) googlegroups.com>,
register (AT) sosgmbh (DOT) at says...
Quote:
Hi Darren!

Thanks again for your answer.
I tried with the .log file, but it is not generated. The _output.log is
generated but empty.

Sorry to say that we are back to the error, even on the IIS 6 machine.
I found out that I have been using the wrong path for a while which
only worked on the development machine. It is rather strange If I use
the wrong path, the errorlevel is zero. and - of course - nothing is
imported.

I checked the access date of the .cab but it looks like it is never
accessed.

Does the NETWORK SERVICE account need more rights than being in the
OLAP Admin group?

Which user could I impersonate to? What specialties would that user
need?
I tried on the IIS 6 with a newly generated user and then the website
could not be loaded anymore, that's why I switched back to NETWORK
SERVICE.

Do you think it is possible to get this running?

Thanks.
Nice regards
Werner




Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.3
Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.