Data Backup and Recovery

SnapCenter 4.5 SQL retention

MaGr
2,610 Views

Hi there,

we are running SC 4.5 to backup SQL server. 

It's installed and running well. 

Retention is set to 4 days for full and 4 day for UTM restore.

 

I noticed that in the server log volume (where the TBD files are) the snapshots are piling up.

At the moment there are 452 snapshot in the volume.

It's mentioned to set the LOG_SNAPSHOT value using the CMDLET. But it seems it's no longer supported to do so.

 

 

Set-SmPolicy -PolicyName 'test' -PolicyType 'Backup' -Description 'Full and log backup Policy' 
-scheduleType Hourly -retentionsettings @{"BackupType"="DATA";"RetentionDays"="4"}, @{"BackupType"="DATA";"ScheduleType"="HOURLY";"RetentionDays"="4"},@{"BackupType"="LOG";"RetentionDays"="4"},@{"BackupType"="LOG_SNAPSHOT";"RetentionCount"="3"} 
-pluginpolicytype 'SCSQL' -sqlbackuptype 'Fullbackupandlogbackup' -CreateLogFolderSnapshot

 

If fails with the following output:

WARNING: Providing on demand retention setting for Hourly policy is deprecated. On Demand retention setting will be ignored.
WARNING: Log_Snapshot value is non-configurable and hence value provided for LOG_SNAPSHOT retention will be ignored.

 

How can I fix that?

 

Marcus

Marcus
1 ACCEPTED SOLUTION

MaGr
2,375 Views

Its a confirmed bug.

Marcus

View solution in original post

3 REPLIES 3

CSCOTTENO
2,570 Views

Marcus,

As bad as it sounds, I'm happy I'm not the only person facing this problem since 4.5.  I also had TBD files/snapshots piling up across our SQL environment, and eventually ended up where you are, trying to configure log retention via Powershell.

 

The resolution for me, which is just a workaround, is I found old policies for DB backups that had "hourly" set for LOG_SNAPSHOT, which was the default setting before 4.5.  I have been copying those policies and applying them, replacing these LOG_SNAPSHOT "none" policies.  Sadly, one has to be careful about editing these copied policies as SC will re-write the LOG_SNAPSHOT value to "none" even if that wasn't the item in the policy being edited.

 

I'd have to dig for it, but there is even a KB article I found that states LOG_SNAPSHOT should be set to "hourly" and not "none".

MaGr
2,536 Views

Hey,

thanks for your input.

It's a new installation of SC, I'm running a poc for it. So no old policies should be there. 

The output of get-smpolicy shows a mix of everything.

 

 BackupType          : LOG_SNAPSHOT
  SchedulerType       : Daily
  RetentionCount      : 2
  RetentionDays       : 0

> BackupType          : LOG_SNAPSHOT
  SchedulerType       : Daily
  RetentionCount      : 2
  RetentionDays       : 0

> BackupType          : LOG_SNAPSHOT
  SchedulerType       : Hourly
  RetentionCount      : 2
  RetentionDays       : 0

> BackupType          : LOG_SNAPSHOT
  SchedulerType       : None
  RetentionCount      : 2
  RetentionDays       : 0

> BackupType          : LOG_SNAPSHOT
  SchedulerType       : None
  RetentionCount      : 2
  RetentionDays       : 0

> BackupType          : LOG_SNAPSHOT
  SchedulerType       : Daily
  RetentionCount      : 2
  RetentionDays       : 0

> BackupType          : LOG_SNAPSHOT
  SchedulerType       : Hourly
  RetentionCount      : 2
  RetentionDays       : 0


> BackupType          : LOG_SNAPSHOT
  SchedulerType       : Hourly
  RetentionCount      : 2
  RetentionDays       : 0

 

I open a case towards Netapp for that ...

 

Marcus

Marcus

MaGr
2,376 Views

Its a confirmed bug.

Marcus
Public