SlideShare a Scribd company logo
1 of 2
How to determine snapshots based on
the age without using any script, just
command line on NetApp cDOT/ONTAP
Note: Following two mathematical symbols would enable us to sort the snapshots based on their
age. However, the way they operate in ONTAP is confusing atleast for me. Hence, I have interpreted
them slightly differently in order to remove any confusion.
Symbols and what it does from ONTAP context:
 '<' = Include everything i.e. ‘NOT less than x days’
 '>' = Include everything i.e. ‘less than x days’
For example:
1) To find out snapshots older than 30days, use the symbol '<'
cdot:: volume snapshot show -create-time <30d
This will yield: all snapshots that are NOT less than 30 days old
2) To find out snapshots in last 30days, use the symbol '>'
cdot:: volume snapshot show -create-time >30d
This will yield: all snapshots that are less than 30 days old
It's confusing, but it works!
Another quick exercise using '>' symbol:
To find out snapshots that is less than a day old
cdot: volume snapshot show -create-time >1d
This will yield: all snapshots that are less than a day old
What is the Objective?
The whole objective of determining the snapshots is to find out if we can recover some space,
however if the size of the snapshots are minimal then it doesn’t really help the administrator. In
other words, there is no urgency to remove them even though they have to go.
For example : If I have 100 snapshots with less than 50gb space locked in total, then I wouldn't
be bothered to remove them rather I will try to add disks to the existing aggregate or look for other
alternatives.
To determine the snapshot size: We can use the switch '-size' along with the previous
command to find out the size of the snapshots older than x days and of 'y' amount of size.
cdot:: volume snapshot show -create-time <30d -size >50g
This will yield: all snapshots that are NOT less than 30 days old with size > 50g
You can also use wildcard to sort the same:
For example:
 You can use *2018 : To sort snapshots created in 2018.
 You can use *vol* : To sort snapshots that contains specific name.
Cdot::volume snapshot show -create-time *2018 -volume *sql_prod*
ashwinwriter@gmail.com
July, 2019

More Related Content

More from Ashwin Pawar

More from Ashwin Pawar (20)

How to connect to NetApp FILER micro-USB console port
How to connect to NetApp FILER micro-USB console portHow to connect to NetApp FILER micro-USB console port
How to connect to NetApp FILER micro-USB console port
 
NDMP backup models
NDMP backup modelsNDMP backup models
NDMP backup models
 
How to use Active IQ tool to access filer information
How to use Active IQ tool to access filer informationHow to use Active IQ tool to access filer information
How to use Active IQ tool to access filer information
 
San vs Nas fun series
San vs Nas fun seriesSan vs Nas fun series
San vs Nas fun series
 
Steps to identify ONTAP latency related issues
Steps to identify ONTAP latency related issuesSteps to identify ONTAP latency related issues
Steps to identify ONTAP latency related issues
 
SnapDiff
SnapDiffSnapDiff
SnapDiff
 
SnapDiff process flow chart
SnapDiff process flow chartSnapDiff process flow chart
SnapDiff process flow chart
 
SnapDiff performance issue
SnapDiff performance issueSnapDiff performance issue
SnapDiff performance issue
 
Volume level restore fails with error transient snapshot copy is not supported
Volume level restore fails with error transient snapshot copy is not supportedVolume level restore fails with error transient snapshot copy is not supported
Volume level restore fails with error transient snapshot copy is not supported
 
Disk reports predicted failure event
Disk reports predicted failure eventDisk reports predicted failure event
Disk reports predicted failure event
 
OCUM shows ONTAP cluster health degraded
OCUM shows ONTAP cluster health degradedOCUM shows ONTAP cluster health degraded
OCUM shows ONTAP cluster health degraded
 
NDMPCOPY lun from 7-mode NetApp to cDOT
NDMPCOPY lun from 7-mode NetApp to cDOTNDMPCOPY lun from 7-mode NetApp to cDOT
NDMPCOPY lun from 7-mode NetApp to cDOT
 
Latency in storage
Latency in storageLatency in storage
Latency in storage
 
NVRAM vs NVMEM
NVRAM vs NVMEMNVRAM vs NVMEM
NVRAM vs NVMEM
 
NAS vs SAN
NAS vs SANNAS vs SAN
NAS vs SAN
 
NetApp storage layering
NetApp storage layeringNetApp storage layering
NetApp storage layering
 
What is storage from client's perspective
What is storage from client's perspectiveWhat is storage from client's perspective
What is storage from client's perspective
 
Difference between cluster image package show-repository and system image get
Difference between cluster image package show-repository and system image getDifference between cluster image package show-repository and system image get
Difference between cluster image package show-repository and system image get
 
Cannot access NetApp 7-mode admin shares etc$
Cannot access NetApp 7-mode admin shares etc$Cannot access NetApp 7-mode admin shares etc$
Cannot access NetApp 7-mode admin shares etc$
 
How to generate,collect and upload ocum logs
How to generate,collect and upload ocum logsHow to generate,collect and upload ocum logs
How to generate,collect and upload ocum logs
 

Recently uploaded

Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
vu2urc
 

Recently uploaded (20)

Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)Powerful Google developer tools for immediate impact! (2023-24 C)
Powerful Google developer tools for immediate impact! (2023-24 C)
 
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
Bajaj Allianz Life Insurance Company - Insurer Innovation Award 2024
 
🐬 The future of MySQL is Postgres 🐘
🐬  The future of MySQL is Postgres   🐘🐬  The future of MySQL is Postgres   🐘
🐬 The future of MySQL is Postgres 🐘
 
Strategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a FresherStrategies for Landing an Oracle DBA Job as a Fresher
Strategies for Landing an Oracle DBA Job as a Fresher
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
GenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day PresentationGenCyber Cyber Security Day Presentation
GenCyber Cyber Security Day Presentation
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Histor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slideHistor y of HAM Radio presentation slide
Histor y of HAM Radio presentation slide
 
Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024Axa Assurance Maroc - Insurer Innovation Award 2024
Axa Assurance Maroc - Insurer Innovation Award 2024
 
Handwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed textsHandwritten Text Recognition for manuscripts and early printed texts
Handwritten Text Recognition for manuscripts and early printed texts
 
A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)A Domino Admins Adventures (Engage 2024)
A Domino Admins Adventures (Engage 2024)
 
[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf[2024]Digital Global Overview Report 2024 Meltwater.pdf
[2024]Digital Global Overview Report 2024 Meltwater.pdf
 
Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024Tata AIG General Insurance Company - Insurer Innovation Award 2024
Tata AIG General Insurance Company - Insurer Innovation Award 2024
 
Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024Partners Life - Insurer Innovation Award 2024
Partners Life - Insurer Innovation Award 2024
 
Developing An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of BrazilDeveloping An App To Navigate The Roads of Brazil
Developing An App To Navigate The Roads of Brazil
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?A Year of the Servo Reboot: Where Are We Now?
A Year of the Servo Reboot: Where Are We Now?
 
Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024Finology Group – Insurtech Innovation Award 2024
Finology Group – Insurtech Innovation Award 2024
 

How to sort netapp snapshots based on age using command line on cdot

  • 1. How to determine snapshots based on the age without using any script, just command line on NetApp cDOT/ONTAP Note: Following two mathematical symbols would enable us to sort the snapshots based on their age. However, the way they operate in ONTAP is confusing atleast for me. Hence, I have interpreted them slightly differently in order to remove any confusion. Symbols and what it does from ONTAP context:  '<' = Include everything i.e. ‘NOT less than x days’  '>' = Include everything i.e. ‘less than x days’ For example: 1) To find out snapshots older than 30days, use the symbol '<' cdot:: volume snapshot show -create-time <30d This will yield: all snapshots that are NOT less than 30 days old 2) To find out snapshots in last 30days, use the symbol '>' cdot:: volume snapshot show -create-time >30d This will yield: all snapshots that are less than 30 days old It's confusing, but it works! Another quick exercise using '>' symbol: To find out snapshots that is less than a day old cdot: volume snapshot show -create-time >1d This will yield: all snapshots that are less than a day old
  • 2. What is the Objective? The whole objective of determining the snapshots is to find out if we can recover some space, however if the size of the snapshots are minimal then it doesn’t really help the administrator. In other words, there is no urgency to remove them even though they have to go. For example : If I have 100 snapshots with less than 50gb space locked in total, then I wouldn't be bothered to remove them rather I will try to add disks to the existing aggregate or look for other alternatives. To determine the snapshot size: We can use the switch '-size' along with the previous command to find out the size of the snapshots older than x days and of 'y' amount of size. cdot:: volume snapshot show -create-time <30d -size >50g This will yield: all snapshots that are NOT less than 30 days old with size > 50g You can also use wildcard to sort the same: For example:  You can use *2018 : To sort snapshots created in 2018.  You can use *vol* : To sort snapshots that contains specific name. Cdot::volume snapshot show -create-time *2018 -volume *sql_prod* ashwinwriter@gmail.com July, 2019