This is a migrated thread and some comments may be shown as answers.

(Solution) Installer fails on AdventureWorks

4 Answers 472 Views
General Discussions
This is a migrated thread and some comments may be shown as answers.
TonyG
Top achievements
Rank 1
TonyG asked on 24 Sep 2010, 10:39 PM
I'm guessing this is not a new problem but it's the first time I'm seeing it. I'm fully documenting this for anyone else who has a similar situation. When I install the current (Q2 2010 SP1) release of Reporting with Examples I get:

Error -2147217900: failed to execute SQL string, error detail: Database 'AdventureWorks' cannot be opened due to inaccessible files or insufficient memory or disk space. See the SQL Server errorlog for details., SQL key: PrepareTempTable SQL String ... USE Adventureworks;

I am running a local instance of SQL Server Express 2005. I realized that I had deleted the AdventureWorks_Data.mdf, so "inaccessible files" made sense. I reinstalled the database using the Microsoft msi.

Even though I'm running with a user with administrator privileges, I wasn't able to connect using the VS2008 Server Explorer until I set "User Instance=True". So now my ConfigurationString is:
Data Source=NINJA\SQLEXPRESS;AttachDbFilename="C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\Data\AdventureWorks_Data.mdf";Integrated Security=True;User Instance=True
So now VS connects and I can see the whole database.

But I still get the same error installing Telerik Reporting. See the attached image.

The installer does a rollback on failure so we can't get by this issue after it occurs. Restarting the installer I disabled the install of the Examples and the install completed successfully.  So that's how to get around the issue.

I opened Services. My "SQL Server (SQLEXPRESS)" service is running under account "NT AUTHORITY\NetworkService".  I stopped the server and changed the logon to "Local System account", then restarted the service. Then I went to Add/Remove Programs, opened Telerik Reporting, and selected Change. I re-enabled Examples, and it installed to completion.  Simply running SQL Server as Local System Account would have solved the problem before it happened, and I'm sure that's how many people already have it setup. For those who don't... I hope this helps.  Unfortunately people who don't want to change the login like that may need another solution.

Is there any way that we can change the configuration string for the installer for the Examples, so that it will install?  More importantly, I don't think a software installer should fail with a database connection like this. Let the product install and then let the runtime fail. We can fix that problem when it happens.

Does Telerik have any other recommendations in this area?

Thanks!

4 Answers, 1 is accepted

Sort by
0
Hrisi
Telerik team
answered on 30 Sep 2010, 08:25 AM
Hi TonyG,

The Telerik Reporting installation does not attach the AdventureWorks database. If the database is not installed on the local instance of the SQL Server the installer is trying to create it with the instawdb.sql script you can find in the <InstallDir>\Telerik\Reporting Q2 2010\Examples\Data\AdventureWorks OLTP.
The connection string is constructed dynamically from the selected instance of the SQL Server and the Authentication you choose - for example "Data Source=(local)\SQLEXPRESS;Initial Catalog=master;Integrated Security=SSPI".

Please note that the successful installation of the examples depends from your proper administration of the SQL Server instance. You can read more in this article"SQL Server 2005 Security Best Practices - Microsoft Corporation".

Sincerely yours,
Hrisi
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
TonyG
Top achievements
Rank 1
answered on 30 Sep 2010, 05:48 PM
Hrisi, I'm sorry, but there are issues with your conclusion.
1) If the install fails I believe the files are uninstalled, so there is nothing that we can do with the instawdb.sql script to fix the problem, which was exactly my point. I might be wrong about this, now that I have a successful installation I have all files and I can't test this anymore. But I would hope that your installer completely uninstalls files on failure and that it over-writes files in install directories as well. If it's documented that instawdb.sql can be modified and used after a failed install then that may solve the problem.
2) When installing reporting tools to a local PC or even a networked server which is hosting a database just for testing, we are not usually concerned with security best practices. The database is a file on disk like any other and anything that impedes our ability to start working with the tools is an annoyance.

My ability to use your tools should not be hindered like this. "Examples" should be separated into two components: Database and Software. If I already have the database, just install solutions and projects. And don't abort the installation of the components because the examples fail. This is an unnecessary obstruction that keeps us away from code, which is ultimately where we need to be.

Thanks.
0
Hrisi
Telerik team
answered on 06 Oct 2010, 02:34 PM
Hi TonyG,

Thank you for the suggestions. We want to assure you that we're improving the installation and making it smoother with each version.

Our examples require AdventureWorks installed on the local instance of the SQL Server. If you install it from Codeplex for example, the installer will skip the AdventureWorks database creation. Note that "security flaws" are imposed from the SQL Server, not from us and the installer cannot circumvent them.

Hrisi
the Telerik team
Do you want to have your say when we set our development plans? Do you want to know when a feature you care about is added or when a bug fixed? Explore the Telerik Public Issue Tracking system and vote to affect the priority of the items
0
TonyG
Top achievements
Rank 1
answered on 08 Nov 2011, 07:14 PM
OK, over a year later, I was determined to get my 2011Q2 Reporting tools installed properly.  Here is a summary of what I did to get a successful install.

To start, note that nothing has changed in the Telerik installer, but based on what Hrisi said I sort of understand.  I still don't like the idea of a product installer failing because of an optional database but let's move on.

The database seemed to get installed but the connection kept failing.  I was using Windows Authentication using my current login and figured I needed to finally address that issue, and maybe try to login under a different user.  The information found in this forum posting was extremely helpful (see the whole thread here).  That solution desribes how to use the Microsoft SQL Server Management Studio to enable the "sa" user to operate on databases.  Get the MSSMS Express edition here.  The forum post is incorrect about allowing the user sa to have an empty password, assign one.

Once I got into my databases with the Object Explorer in MSSMS I saw there was an Adventureworks database there.  Apparently it was corrupted.  This is a key factor.  The Telerik installer apparently saw there was already a database, didn't execute the instawdb.sql script, and then failed to connect to the bad database that was there.  I deleted that database, now that I had the ability to do it cleanly.

After that 2011Q2 installed all the way through to completion.  YAY!
Tags
General Discussions
Asked by
TonyG
Top achievements
Rank 1
Answers by
Hrisi
Telerik team
TonyG
Top achievements
Rank 1
Share this question
or