Solved

Deploying ASP.net roles to Production

Posted on 2009-07-08
2
502 Views
Last Modified: 2013-12-12
Hi, I'm having an issue with my .net role provider when I try to move my code to the production server. Everything works fine in my local, but once it is copied over to our production server it just doesn't work anymore. It seems like it does not recognize the location of the roles databases. Membership along copies over and works just fine, as I tried this before enabling the roles.

After googling for a solution I found an article that suggested to overwrite a hidden connection string for my role provider and make sure that it pointed to my database, it also required that I took my aspnetdb.mdf database from my app_data folder and attach it to my sql server.. one problem I'm having with this particular process is that my aspnetdb.mdf seems to be in a 2008 version of sql express, where our production servers runs a 2005 version, therefore when I try to attach it.. it just gives me an error and stops.

Is this the right approach at all? or is there anything else I could try in order to fix this???
0
Comment
Question by:LostInCode
2 Comments
 
LVL 18

Accepted Solution

by:
David Robitaille earned 500 total points
Comment Utility
Did you see that one ? did you  set an applicationName for the Role provider in the Web.config?
http://weblogs.asp.net/scottgu/archive/2006/04/22/Always-set-the-_2200_applicationName_2200_-property-when-configuring-ASP.NET-2.0-Membership-and-other-Providers.aspx
also, if you use another databes in your app, you could merge the aspnetdb.mdf with it

http://www.4guysfromrolla.com/articles/040506-1.aspx
you could also use this techinque on a new datebase on your SQL 2005 server and then recreate your roles (or copy your data on the new tables...)
0
 

Author Closing Comment

by:LostInCode
Comment Utility
Thanks this worked!
0

Featured Post

6 Surprising Benefits of Threat Intelligence

All sorts of threat intelligence is available on the web. Intelligence you can learn from, and use to anticipate and prepare for future attacks.

Join & Write a Comment

I use more than 1 computer in my office for various reasons. Multiple keyboards and mice take up more than just extra space, they make working a little more complicated. Using one mouse and keyboard for all of my computers makes life easier. This co…
Today, still in the boom of Apple, PC's and products, nearly 50% of the computer users use Windows as graphical operating systems. If you are among those users who love windows, but are grappling to keep the system's hard drive optimized, then you s…
This video will demonstrate how to find the puppet warp tool from the edit menu and where to put the points to edit.
XMind Plus helps organize all details/aspects of any project from large to small in an orderly and concise manner. If you are working on a complex project, use this micro tutorial to show you how to make a basic flow chart. The software is free when…

743 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

16 Experts available now in Live!

Get 1:1 Help Now