Data Backup and Recovery

SC 3.4 not deleteing Snap created via sdcli

thorsten_pfeifer
6,608 Views

Hi all

I'm still playing around with SC. Till now I'm able to get DB2 snaps. That's really nice. But although I have configured Snapshots Deletion with Yes, hourly retention with 3 and policy retention age with 1 all created snaps done using sdcli are still there. I assumed that only 3 per day should be listed with the previous mention configuration.

Here the specific line from the conf file

  • NTAP_SNAPSHOT_NODELETE=Y
  • NTAP_SNAPSHOT_RETENTIONS=hourly:3
  • NTAP_SNAPSHOT_RETENTION_AGE=1

What's going wrong here?

Best regards

Thorsten

1 ACCEPTED SOLUTION

ktenzer
6,075 Views

Yeah the reason SC isnt deleting any snapshots is that the snapshots are not named sohp16gdcvi1302-hourly-20110913154000 instead they are named smvi__sohp16gdcvi1302-hourly-20110913154000_recent__20110913154037.

SC does not support any naming conventions other than it's own.

You can try updating smvi.override so that smvi doesnt change the name of the snapshots

Add in smvi.override :

snapshot.name.format.timestamp={backupName}

But other than that I cant help you further

Maybe talk to the smvi folks or snapdrive folks?

Keith

View solution in original post

20 REPLIES 20

ktenzer
6,529 Views

Hi Thorsten,

This is a small GUI bug, the tool tip and message in GUI is wrong or another way to say it doesnt update the parameter correctly it does opposite of what you think. This will be fixed in next release for sure!

Please in GUI set snapshot deletion to N this in turns sets NTAP_SNAPSHOT_NODELETE=N. Basically the parameter is a negatation, meaning you enable it to not delete snapshots.

I know a bit confusion but this is simple to deal with when you know what to look for. By default it is set correctly just people go in and change it because again GUI isnt explaining parameter correctly.

You want NTAP_SNAPSHOT_NODELETE=N then SC will delete snaps

Regards,

Keith

thorsten_pfeifer
6,529 Views

Hi Keith

Changed parameter but snaps are not being deleted

Any further ideas why?

Thanks a lot

Regards

Thorsten

ktenzer
6,529 Views

Well you have this NTAP_SNAPSHOT_RETENTION_AGE=1 that means snapshots that are less than one day old wont be deleted even if you have more than 3 snapshots. Why dont you set following, snapshots should then delete

  • NTAP_SNAPSHOT_NODELETE=N
  • NTAP_SNAPSHOT_RETENTIONS=hourly:3
  • NTAP_SNAPSHOT_RETENTION_AGE=

Keith

ktenzer
6,529 Views

Another Idea, just use GUI and click next without changing anything

Dont set NTAP_SNAPSHOT_RETENTION_AGE unless you dont want snaps to be deleted that arent older than days specified here

Keith

thorsten_pfeifer
6,529 Views

Hi Keith or anybody else

Long time ago 😉

I still have problems that snap will get deleted.

I want only 2 snaps available which are created with the houry policy. In a later step the daily policy will be used and then only 7 snaps should be available.

For the hourly I've configured the following

  • SNAP_TIMESTAMP_ONLY=Y
  • NTAP_SNAPSHOT_RETENTIONS=hourly:2
  • NTAP_SNAPSHOT_RETENTION_AGE=
  • NTAP_SNAPSHOT_NODELETE=N
  • NTAP_SNAPSHOT_DELETE_BY_AGE_ONLY=N

Can you support me to get both configurations done correctly?

Thanks a lot

Thorsten

ktenzer
6,529 Views

Just specify another policy like daily with 7. Then when you run --policy hourly there will be two snapshots and --policy daily 7.

NTAP_SNAPSHOT_RETENTIONS=hourly:2,daily:7

Regards,

Keith

thorsten_pfeifer
6,529 Views

Ok Keith, I configured now like said before but Snaps got still not deleted.

When I run job with debug I can see following in the Snapshot Rename section

  •      ########## Running NetApp Snapshot Rename on Primary gdcna0002 ##########
  •      [Tue Sep 13 11:40:06 2011] INFO: sohp16gdcvi1302-hourly_20110913114000 is the first snapshot taken for gdcna0002:N2F01V133_SOH_P16_DBLog, Skipping!

In the SnapShot delete section only this is listed. And expected that here the deleted snaps should be listed

  • ########## Running NetApp Snapshot Delete on Primary gdcna0002 ##########

Any other ideas what I can check to get it done?

Regards,

Thorsten

ktenzer
6,529 Views

Can you please send your entire config file? I bet something isnt configured correctly

Keith

thorsten_pfeifer
6,529 Views

Tried now 2 times but I get delivery failure (address unknow) when I reply to your mail.

Any other options so I can provide you the conf file savely?

Thorsten

ktenzer
6,010 Views

Just copy/paste config file? Or if it is too much just copy/paste All the required options and SNAPSHOT options

Or open an NGS support case and work with NGS

Keith

thorsten_pfeifer
6,010 Views

Keith here all the relevant information from the configuration file:

########################
### Required Options ###
########################
CONFIG_TYPE=STANDARD
SNAME=sohp16gdcvi1302
SNAP_TIMESTAMP_ONLY=Y
VOLUMES=gdcna0002:N2F01V133_SOH_P16_DBLog
NTAP_SNAPSHOT_RETENTIONS=hourly:2,daily:7
NTAP_USERS=gdcna0002:root/password
NTAP_PWD_PROTECTION=Y
TRANSPORT=HTTPS
PORT=443
LOG_NUM=10
SC_TMP_DIR=

########################
### Snapshot Options ###
########################
NTAP_SNAPSHOT_RETENTION_AGE=
SNAPDRIVE=N
SNAPDRIVE_DISCOVERY=N
NTAP_SNAPSHOT_DISABLE=N
NTAP_SNAPSHOT_NODELETE=N
NTAP_CONSISTENCY_GROUP_SNAPSHOT=N
NTAP_CONSISTENCY_GROUP_TIMEOUT=medium
NTAP_CONSISTENCY_GROUP_WAFL_SYNC=N
NTAP_SNAPSHOT_DELETE_BY_AGE_ONLY=N
NTAP_SNAPSHOT_DEPENDENCY_IGNORE=N
NTAP_SNAPSHOT_RESTORE_AUTO_DETECT=Y

###################################
### Client/Server Configuration ###
###################################
SC_AGENT=gdcvi1302:9090
SC_AGENT_TIMEOUT=
SC_AGENT_UNQUIESCE_TIMEOUT=
SC_CLONE_TARGET=
SC_AGENT_WATCHDOG_ENABLE=

#############################
### Plugin Module Options ###
#############################
APP_NAME=db2
APP_IGNORE_ERROR=N
VALIDATE_VOLUMES=
APP_DEFINED_RESTORE=N
APP_DEFINED_CLONE=N
APP_AUTO_DISCOVERY=N
APP_CONF_PERSISTENCE=Y

####################
### DB2 Settings ###
####################
#################################################################################################################
# DB2_DATABASES - List of database(s) and their username separated by a comma                                   #
#              #
#   DB2_DATABASES=db1:user1;db2:user2          #
#              #
# DB2_CMD - Path to the db2 command, for connecting to the database(s).                                         #
#           If not specified, sqllib/db2 will be used.                                                          #
#                                                                                                               #
#################################################################################################################
DB2_DATABASES=p16:p16adm
DB2_CMD=D:\Progra~1\IBM\SQLLIB\BIN\db2cmd.exe -c -w -i D:\Progra~1\IBM\SQLLIB\BIN\db2.exe

NTAP_SNAPSHOT_CREATE_CMD01="c:/Program Files/NetApp/SnapDrive/sdcli" snap create -m gdcvi1302 -s %SNAME-%SNAP_TYPE-%SNAP_TIME_recent -D E: S:

Regards

Thorsten

ktenzer
6,010 Views

Can you change SNAME to SNAME=test

Also set SC_AGENT_TIMEOUT=60 not having a timeout is bad. This could actually be causing issue. Always set an SC_AGENT_TIMEOUT if you are using the agent.

please run

./snapcreator --profile <profile> --action snap --policy hourly --verbose

Do this 3 times and send me results from:

./snapcreator --profile <profile> --action snaplist --policy hourly --verbose

Everything looks fine, see no issue with config other than really bizzare SNAME and nothing set for SC_AGENT_TIMEOUT

Keith

ktenzer
6,010 Views

I tried your settings cannot reproduce issue

NTAP_SNAPSHOT_RETENTIONS=hourly:2

Does this work?

If so well then just create a couple of different config files one for each policy you want

Keith

thorsten_pfeifer
6,010 Views

Keith here the outcome of the snaplist action

D:\Program Files\Netapp\NetApp_Snap_Creator_Framework\scServer3.4.0>snapcreator.exe -profile SAP_SOH -config sohp16gdcvi1302 -action snaplist -policy hourly -verbose

########## Parsing Environment Parameters ##########

########## Detecting Data OnTap mode for gdcna0002 ##########
[Tue Sep 13 16:09:27 2011] INFO: Data OnTap 7 mode detected

########## Gathering Information for gdcna0002:N2F01V133_SOH_P16_DBLog ##########
[Tue Sep 13 16:09:28 2011] INFO: Performing NetApp Snapshot Inventory for N2F01V133_SOH_P16_DBLog on gdcna0002
[Tue Sep 13 16:09:28 2011] INFO: NetApp Snapshot Inventory of N2F01V133_SOH_P16_DBLog on gdcna0002 completed Successfully

########## NetApp Snap Creator Framework Snapshot (Primary) List for gdcna0002:N2F01V133_SOH_P16_DBLog #########

### Snapshot Name ###                           ### Snapshot Timestamp ###

D:\Program Files\Netapp\NetApp_Snap_Creator_Framework\scServer3.4.0>

I still see 3 test snap when running the snap list command

  %/used       %/total  date          name
----------  ----------  ------------  --------
  0% ( 0%)    0% ( 0%)  Sep 13 16:08  smvi__test-hourly-20110913160742_recent_20110913160802
  0% ( 0%)    0% ( 0%)  Sep 13 16:03  smvi__test-hourly-20110913160302_recent_20110913160321
  0% ( 0%)    0% ( 0%)  Sep 13 15:58  smvi__test-hourly-20110913155809_recent_20110913155828
  0% ( 0%)    0% ( 0%)  Sep 13 15:40  smvi__sohp16gdcvi1302-hourly-20110913154000_recent_20110913154037
  0% ( 0%)    0% ( 0%)  Sep 13 14:40  smvi__sohp16gdcvi1302-hourly-20110913144000_recent_20110913144037
  0% ( 0%)    0% ( 0%)  Sep 13 13:40  smvi__sohp16gdcvi1302-hourly-20110913134000_recent_20110913134033
  0% ( 0%)    0% ( 0%)  Sep 13 13:31  gdcna0001(0151751355)_N1A01V03_SnapVault_SAP_N2F01V133_SOH_P16_DBLog_Q02_Log-src.0 (snapvault)

Regards

Thorsten

ktenzer
6,076 Views

Yeah the reason SC isnt deleting any snapshots is that the snapshots are not named sohp16gdcvi1302-hourly-20110913154000 instead they are named smvi__sohp16gdcvi1302-hourly-20110913154000_recent__20110913154037.

SC does not support any naming conventions other than it's own.

You can try updating smvi.override so that smvi doesnt change the name of the snapshots

Add in smvi.override :

snapshot.name.format.timestamp={backupName}

But other than that I cant help you further

Maybe talk to the smvi folks or snapdrive folks?

Keith

thorsten_pfeifer
4,928 Views

Hi Keith

That's exactly the problem. As SMVI is also in use all snaps run via sdcli will get named smvi__%sname.....

Tried if it's really so and used normal volume snap without sdcli. And the snapshout deletion is working as the snap name is without smvi__ in front

So now the big question how to get the sdcli sname to the correct name so snap creator is usable.

Your hint about the smvi.override isn't workable as I found this here: https://kb.netapp.com/support/index?page=content&id=3012888

Any other idea to get the snap name correctly when using sdcli on Virtual Machines?

Regards

Thorsten

ktenzer
4,928 Views

That was my only idea. I would post on the SMVI / SnapDrive communities how keep SMVI from changing the name of snapshot we pass to SnapDrive.

Like I said the smvi.override should work but I have zero exp with it and never tried it myself.

If you figure this out please post and let us know the solution.

A support case may also be an option. Just dont say "Snap Creator", tell them you are using SnapDrive and want snapshot name to be what you pass SnapDrive and SMVI is changing it to something else.

Good luck!

Keith

ktenzer
4,928 Views

Got some feedback on this

Make sure you are running VSC 2.1.1

After setting the smvi.override restart service

Regards,

Keith

thorsten_pfeifer
4,928 Views

You're the man Keith

VSC 2.1.1 and editing the smvi.override file did the naming trick.

Now all snaps performed by sdcli and smvi are named without smvi__ in front.

The SnapCreator deletion process is running fine now as the snaps can by found by SnapCreator.

Thanks a lot to get this solved. And maybe I will come back with some other issues I will have with SnapCreator

Regards

Thorsten

ktenzer
4,612 Views

Great to hear!

This is a really cool solution with SMVI, SnapDrive, and SC

As always we are here to help with anything SC (and then some) so just let us know.

Today we releases sc 3.4p1 which fixes several BURTs, check it out

Regards,

Keith

Public