none
DPM 2012 R2 Hyper-V backup of SQL server VM

    Question

  • Hello!

    I have a question about using DPM 2012 R2 in Hyper-V 2012 R2 cluster and backing up Windows 2003 VM, that has SQL 2008 installed.

    When i use VM, host level backup with DPM2012 R2, would it trigger a full DB backup on SQL server or not?

    Problem is, that we are using SQL (maintanance plans) for backing up databases and doing transaction logs backup. 

    I want to back up the whole VM, but i want to be sure, that this would not mess up SQL backup inside the VM?

    Is it possible, that i wont install DPM agent inside the SQL server VM? But can i then still restore files from the VHD/X or only entire VM?

    Wednesday, January 21, 2015 6:46 PM

Answers

  • Hi,

    yes, you can add it since it is not there by default.   You can try not adding and see if the SQL logs get truncated after every DPM recover point - if so, then yes you still need to add it.     There is no need to install DPM agent inside the guest if you are only doing host level VM backups.


    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. Regards, Mike J. [MSFT] This posting is provided "AS IS" with no warranties, and confers no rights.

    • Marked as answer by Joosep Monday, January 26, 2015 6:55 AM
    Thursday, January 22, 2015 5:10 PM
    Moderator

All replies

  • Hi,

    Apply the following registry entry in the GUEST virtual machine so application logs are not truncated by host level backups.

    Location: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Virtualization\VssRequestor
    Name: BackupType
    Type: REG_DWORD
    Value: 1

    If this registry entry is created and its value is set to 1 , application backup will not be affected by the virtual machine backup operation on the server that is running Hyper-V. If this registry entry does not exist, or if its value is 0 , then host level backups will truncate logs in the guest.

    Yes - you can perform item level recovery for files inside the .vhd by double-clicking the .vhd while browsing to restore the VM.  That will mound the .vhd and allow you to copy files out without having to restore the entire .vhd file.


    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. Regards, Mike J. [MSFT] This posting is provided "AS IS" with no warranties, and confers no rights.

    Thursday, January 22, 2015 3:32 AM
    Moderator
  • Thank You for the response!

    The 2003/R2 server does not have the full path of the registry entry, that You wrote.

    Is safe to create it and also does it apply for 2012/R2 OS also?

    Also another question is, do i need to install a DPM agent on a GUEST vm, if i only want to back it up at Hyper-V level?



    • Edited by Joosep Thursday, January 22, 2015 4:47 PM
    Thursday, January 22, 2015 4:39 PM
  • Hi,

    yes, you can add it since it is not there by default.   You can try not adding and see if the SQL logs get truncated after every DPM recover point - if so, then yes you still need to add it.     There is no need to install DPM agent inside the guest if you are only doing host level VM backups.


    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. Regards, Mike J. [MSFT] This posting is provided "AS IS" with no warranties, and confers no rights.

    • Marked as answer by Joosep Monday, January 26, 2015 6:55 AM
    Thursday, January 22, 2015 5:10 PM
    Moderator
  • Thank You again!

    I will try to test this registry entry solution first on a non production server.

    Monday, January 26, 2015 6:56 AM
  • Hi Mike

    Does this still apply to my setup - it have been working before with HYPER-V Hosts with Windows Server 2012 - and same VMs as before.

    Current setup:
    Hyper-V Hosts OS: Windows Server 2012 R2 - with DPM-agent on each node
    VM/Guest OS: Windows Server 2012 (6.2.9200) & SQL Server 2012 SP1 (11.0.3000) - with NO DPM-agent on this
    DPM Version: 4.2.1273.0

    We have set the registry key on the Guest VM:
    "
    Location: HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Virtualization\VssRequestor 
    Name: BackupType 
    Type: REG_DWORD 
    Value: 1
    "

    A VM-backup of the VM/Guest break the normal SQL-backup "chain".
    Our normal SQL-backup is just made using built-in "maintenance plans".

    Details in JPG, can be seen here:
    http://downloads.ndias.com/3b29dfd8-0ade-4703-bdc5-ab116b1ed29c/DPM_and_SQL_details.jpg

    PS. I have the same problem on other VMs, also Windows Server 2012 R2 VMs.


    Best regards,
    Lars K. Søgaard


    Friday, March 06, 2015 8:09 AM
  • Hi,

    That setting is a Windows Hyper-V setting, if it is not working, please open a thread with the Windows Hyper-V forum for further investigation. 

    FYI - Windows fix in question.

    975925 A hotfix is available that addresses the issues that occur when you perform a host-level backup of a Hyper-V VM on a computer that is running Windows Server 2008
    http://support.microsoft.com/kb/975925/en-us


    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread. Regards, Mike J. [MSFT] This posting is provided "AS IS" with no warranties, and confers no rights.

    Friday, March 06, 2015 4:43 PM
    Moderator