locked
Moving a LS Database RRS feed

  • Question

  • This might be a question with an obvious answer, but I am a LS newbie so bear with me :P

    I am going to be deploying a LightSwitch application to our current server (we REALLY needed the application to be made asap). I plan to deploy it on the server and either run it as a desktop client or a browser client.

    The issue is that I will need to move the database to a new server in a couple months.

    What will the transfer entail? Will a browser-based client be easier to move (instead of having to potentially update all networked computers, etc)? Any links, advice, or past experience would be extremely helpful. I have worked with some basic programming for several years but I've never had to deal with SQL server or anything like that.

    Our server is running Microsoft Small Business Server (with SQL express) and IIS6. New server will be running SBS, SQL express, and IIS7.

    Wednesday, May 23, 2012 4:53 PM

Answers

All replies

  • Hi,

    I think that the browser based solution is easierst to change. (But both isn't hard!)

    The database connections are inside the web.config file. You can just change that (but maybe that is not required. If the database is on the same server, the connection string can point to (local) or . so you can just move the dataabse and install the LS app without any required change at all.

    With kind regards,

    Konrad

    Wednesday, May 23, 2012 5:08 PM
  • You can just copy if you want.  Copy the IIS app dir to new IIS dir and make the app dir an asp virtual dir in IIS manager.  Can use ftp or what ever.  Can also copy the db and mount it on sql express.  verify the web.config.  You could also deploy fresh to new server and new db.  Verify empty LS project works as expected.  Then copy current db over to sql express.  Should stop sql express on both servers first.  Or make backup on 1 and restore on other.  Few ways to go.  
    Wednesday, May 23, 2012 10:46 PM
  • One thing you can do is in the initial deployment configure the system to use SQL Server aliases or DNS Aliases, then you can move the database as needed and change the alias reference, this would mean that the change is done in one point and the application wouldn't need to be touched.

    http://blogs.msdn.com/b/dbrowne/archive/2012/05/21/how-to-add-a-hostname-alias-for-a-sql-server-instance.aspx

    • Marked as answer by sj-- Thursday, May 24, 2012 12:38 PM
    Thursday, May 24, 2012 4:00 AM