In order to upgrade a database with no client disconnects, I clone an existing database and put it in a readonly mode. Now, I want all user traffic to be redirected from the original database to the cloned one (both are on the same server). I want to do it with SQL aliases. However, I see that aliasing is possible for server instances and protocols. Is there another way to go about database redirects on the same server?
Tell me more
×
Database Administrators Stack Exchange is a question and answer site for
database professionals who wish to improve their database skills and learn from others in the community. It's 100% free, no registration required.
|
migrated from stackoverflow.com Oct 25 '11 at 12:54
|
Aliases are only for server/instances of SQL Server, not for databases. In your case I'd create a database snapshot of the current database (so there's no need for a new read-only copy of your db), redirect all user connections there, do you update, then drop the snapshot. Please take into consideration that a snapshot can take a lot of space if forgotten there, not dropped on time. |
|||
|
|
Not sure if thats something easily achieved in this way. Youll probably want something similar to transactional replication / failover. Not sure how your structure has altered though. If the structure isnt changing, I would run with this solution so that you can take down the original and everything will simply divert. |
|||
|
|