SQL Server 2012 Migration ideas?

  • Hi Guys,

    I have a 2008R2 VM running SQL Server 2012. I would like to migrate hosts to a 2012 box that will also be running SQL server 2012. The original SQL box has an OS partition and a Data partition (separate VMDK's). Data partition is the root directory and contains all DB's.

    I could build an identical SQL server VM and then migrate the system db's, db's and logins over which wouldn't be too bad.

    But is there a way I could install SQL on the new VM and simply detach and re-attach the Data VMDK to the new host and get the new SQL instance to recognise everything?

    Thanks in advance.

  • You can do exactly that for the databases. However, there will be the downtime of copying them over to the new server prior to attaching them.

    However, the system stuff, logins, etc., that has to be migrated. So you'll need to export all that into scripts and then import it all into the new servers. To minimize downtime, most people use mirroring or replication to keep all transactions in sync until you're ready to make the switch. Could also be done using Availability Groups.

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning

  • 2008 R2 didn't have availability groups, so your options are log shipping, mirroring, or replication.

    How much downtime can you endure?  How big are your databases?  If they are small, backup, restore or detach and reattach may be your best option.  If downtime is minimal, or the DB's a large, then I would suggest log shipping.

    Generically, the steps would be:

    1. Configure the new server.  Set up the logins, SQL jobs, etc.
    2. Configure log shipping.  Take note of the time the restores take.  You want a baseline for the last log backup/restore.
    3. Stage any changes to DNS, connect strings, and so forth.
    4. On the cutover day, stop any connectivity to the old server.  Take the last log backup and let the restore occur.
    5. SHUT OFF the old server.
    6. Bring the DB's online on the new server
    7. Change DNS, connect strings, and so forth.
    8. Test, test, test.

    The last time I did this we had 34 databases totaling 1.8 TB in size.  The entire cutover to the new servers was completed in 40 minutes.

    I would suggest taking a look at DBATools  https://dbatools.io/   It contains have a very good set of Power Shell scripts that will make your job much easier.

    And, why SQL 2012?  That's already on extended support, which is scheduled to end in about a year.

    Michael L John
    If you assassinate a DBA, would you pull a trigger?
    To properly post on a forum:
    http://www.sqlservercentral.com/articles/61537/

  • Why upgrade to SQL2012? If possible, go for a supported version. Performance and management features have been enhanced very much!

    Also double check the current db levels for all databases!

    e.g. SQL2012 does not support dblevel 80 ( sql2000) which is currently the reason we still have some SQL2008R2 instances ( the using software uses specific SQL2000 system objects which no longer exist in more recent sql server versions. )

    SQL Server Migration Assistant can help you find such issues. It is part of the feature pack.

    Johan

    Learn to play, play to learn !

    Dont drive faster than your guardian angel can fly ...
    but keeping both feet on the ground wont get you anywhere :w00t:

    - How to post Performance Problems
    - How to post data/code to get the best help[/url]

    - How to prevent a sore throat after hours of presenting ppt

    press F1 for solution, press shift+F1 for urgent solution 😀

    Need a bit of Powershell? How about this

    Who am I ? Sometimes this is me but most of the time this is me

  • This was removed by the editor as SPAM

Viewing 5 posts - 1 through 4 (of 4 total)

You must be logged in to reply to this topic. Login to reply