I created an MVC3 application and the application pointed to the model which contained a table and a view. This application worked fine when published on the server. However, I added another view to the model and modified accordingly and this application
works perfectly when launched from within the Visual Studio Environment. But, when I publish it to the server, I get get an error. Which starts a "The underlying provider failed to open..." What could be the error?
I am doing that. Copying to the local folder and then to the server. But the new version still doesn't work. I had saved the files from the previous version and when I upload those, it works just fine. All I did was change the model.
Thanks for the help. The problem arose because the connectionstring somehow got set to "Integrted Security=True". I have now put the user ID and password for the DB instead and it works fine again.
Maitreyi
Member
5 Points
10 Posts
Unable to Publish to the server
Mar 30, 2012 04:30 PM|LINK
Hi,
I created an MVC3 application and the application pointed to the model which contained a table and a view. This application worked fine when published on the server. However, I added another view to the model and modified accordingly and this application works perfectly when launched from within the Visual Studio Environment. But, when I publish it to the server, I get get an error. Which starts a "The underlying provider failed to open..." What could be the error?
Thank you.
CodeHobo
All-Star
18647 Points
2647 Posts
Re: Unable to Publish to the server
Mar 30, 2012 04:33 PM|LINK
How are you doing your data access?
Blog | Twitter : @Hattan
Maitreyi
Member
5 Points
10 Posts
Re: Unable to Publish to the server
Mar 30, 2012 04:40 PM|LINK
I am writing a Linq query in the Controller to access the db in SQL Server.
Maitreyi
Member
5 Points
10 Posts
Re: Unable to Publish to the server
Mar 30, 2012 04:41 PM|LINK
Also the error contain the following "Login failed for user 'IIS APPPOOL\[ApplicationPoolname]
ricka6
All-Star
15070 Points
2272 Posts
Microsoft
Moderator
Re: Unable to Publish to the server
Mar 30, 2012 04:56 PM|LINK
See my blog post Test your ASP.NET MVC or WebForms Application on IIS 7 in 30 seconds
protienshow
Member
688 Points
142 Posts
Re: Unable to Publish to the server
Mar 30, 2012 04:58 PM|LINK
Try to publish to local folder and then ftp the entire folder to the web server.
Create Dashboard In MVC
Maitreyi
Member
5 Points
10 Posts
Re: Unable to Publish to the server
Mar 30, 2012 06:08 PM|LINK
I am doing that. Copying to the local folder and then to the server. But the new version still doesn't work. I had saved the files from the previous version and when I upload those, it works just fine. All I did was change the model.
Maitreyi
Member
5 Points
10 Posts
Re: Unable to Publish to the server
Mar 30, 2012 06:10 PM|LINK
Thanks for that. However, I do not have access to the server to make the changes. Can I provide rights at the DB level though?
ricka6
All-Star
15070 Points
2272 Posts
Microsoft
Moderator
Re: Unable to Publish to the server
Mar 30, 2012 06:51 PM|LINK
Can you try this on your test server or at least deploy to a Win7 box?
Maitreyi
Member
5 Points
10 Posts
Re: Unable to Publish to the server
Apr 03, 2012 03:02 PM|LINK
Thanks for the help. The problem arose because the connectionstring somehow got set to "Integrted Security=True". I have now put the user ID and password for the DB instead and it works fine again.
Thanks.