Forum Discussion

Dav1234's avatar
Dav1234
Level 5
4 years ago

VMware backup with SQL database

Hello Team,

we have one VM machine where SQL database is installed. If we configure VMware backup (through VIP) with option "enable SQL server recovery". 

If our VM gets corrupted will the database be recovered automatically after complete VM restore?

  • Hi Dav1234 

    I was going to write the following, but pats_729 has real world experience of this, so I defer to his greater knowledge.

    "The database would be in a crash consistent mode only from the full VM recovery. It may work but no guarantees.

    To properly recover the database, you will need to perform an SQL recovery. This process is reasonably well described in the NetBackup MS-SQL Admin Guide."

    David

    • Dav1234's avatar
      Dav1234
      Level 5

      Hello David,

      we are taking backups of VM where SQL database is housed. i was wondering, if we perform complete VM recover will SQL database recovers in that or we need to take seperate SQL backup(agent based backup through SQL policy type) to recover the DB?

      i was thinking to just stop SQL DB backup to save FETB and blackened capacity, only if SQL DB recovery is feasible with complete VMware recovery

       

      • davidmoline's avatar
        davidmoline
        Level 6

        Hi Dav1234 

        As pats_729 has indicated, you can recover the SQL DB when the MSQL application state catpure for that VM is enabled. 

        What this is though is a point in time snapshot of the database. It is not possible to use this backup with transaction logs to roll forwards or backwards to recover to a particular point in time. If this is not required then using the VM backup with appliaction capture will be sufficient.

        If you need the granularity of recovery that comes with transaction logs and rollback / roll forwards, then you should use the NetBackup agent in the VM. As for FETB - although you are running two backups it is the same data, so an adjustment can be made when reviewing the nbdeplyutil. Or it is possible to exclude the database VDMK files from the VM backup, which would avoid the backend capacity being used. This later will depend on how the VM is setup (separate VMDK files for the database areas).

        David

  • Dav1234

    Thats what Application Consistency we talk about. I have restored VM's for many customers with MSSQL consistency.

  • First of all, you have to install netbackup client inside the VM.

    As dimension earlier,  when you restore the VM. you have 99% chance that the SQL will be operational.
    But the supported method is to restore the VM and then restore the SQL from the Backup (This is NOT an extra backup, netbackup index and catalog the SQL at the same time.)

    AS mentioned earlier with VM/SQL backup you can only truncate the logs. You can not do a point in time restore. If you need a point in time restore, you have to do regular SQL Full backup and log backups.