<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Snapshot policy query: how to list in order by number of volumes already assigned to policy in Active IQ Unified Manager Discussions</title>
    <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Snapshot-policy-query-how-to-list-in-order-by-number-of-volumes-already-assigned/m-p/137514#M24929</link>
    <description>&lt;P&gt;I was able to found the query from wfaguy.com.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;posting here hoping someone can fidn it useful.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;in regex input you can just put a whilecard for ex .*T1&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;where T1 is first two digits of policy name.&lt;/P&gt;&lt;P&gt;and at the end I put LIMIT 100 to list all policy but you can put it as 1 and thats the least used policy.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;all creadit goes to wfaguy&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;SELECT&lt;BR /&gt;snapshot_policy.name,&lt;BR /&gt;vserver.name AS 'vserver.name',&lt;BR /&gt;cluster.primary_address AS 'vserver.cluster.primary_address',&lt;BR /&gt;count(volume.name)&lt;BR /&gt;FROM&lt;BR /&gt;cm_storage.snapshot_policy&lt;BR /&gt;LEFT JOIN&lt;BR /&gt;cm_storage.volume&lt;BR /&gt;ON volume.snapshot_policy_id=snapshot_policy.id&lt;BR /&gt;LEFT JOIN&lt;BR /&gt;cm_storage.vserver&lt;BR /&gt;ON snapshot_policy.vserver_id = vserver.id&lt;BR /&gt;LEFT JOIN&lt;BR /&gt;cm_storage.cluster&lt;BR /&gt;ON vserver.cluster_id = cluster.id&lt;BR /&gt;WHERE&lt;BR /&gt;snapshot_policy.name REGEXP '${regex}'&lt;BR /&gt;AND (&lt;BR /&gt;cluster.name = '${cluster_name}'&lt;BR /&gt;OR cluster.primary_address = '${cluster_name}'&lt;BR /&gt;)&lt;BR /&gt;AND vserver.name = '${vserver_name}'&lt;BR /&gt;GrOUp by&lt;BR /&gt;snapshot_policy.name,&lt;BR /&gt;vserver.name,&lt;BR /&gt;cluster.primary_address&lt;BR /&gt;ORDER BY&lt;BR /&gt;count(volume.name) LIMIT 100&lt;/P&gt;</description>
    <pubDate>Mon, 22 Jan 2018 22:46:24 GMT</pubDate>
    <dc:creator>CAPATEL_NET1984</dc:creator>
    <dc:date>2018-01-22T22:46:24Z</dc:date>
    <item>
      <title>Snapshot policy query: how to list in order by number of volumes already assigned to policy</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Snapshot-policy-query-how-to-list-in-order-by-number-of-volumes-already-assigned/m-p/137442#M24898</link>
      <description>&lt;P&gt;Hello All,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;just working on WFA and seems it will be very helpful if I can build intelligence around how the listing of snapshot policy works for a primary volume. is it possible to show some details info in the query for ex number of volumes or number of snapshots taken by it for that whole cluster so user know if he should use any other policy?&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jun 2025 14:07:52 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Snapshot-policy-query-how-to-list-in-order-by-number-of-volumes-already-assigned/m-p/137442#M24898</guid>
      <dc:creator>CAPATEL_NET1984</dc:creator>
      <dc:date>2025-06-04T14:07:52Z</dc:date>
    </item>
    <item>
      <title>Re: Snapshot policy query: how to list in order by number of volumes already assigned to policy</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Snapshot-policy-query-how-to-list-in-order-by-number-of-volumes-already-assigned/m-p/137514#M24929</link>
      <description>&lt;P&gt;I was able to found the query from wfaguy.com.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;posting here hoping someone can fidn it useful.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;in regex input you can just put a whilecard for ex .*T1&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;where T1 is first two digits of policy name.&lt;/P&gt;&lt;P&gt;and at the end I put LIMIT 100 to list all policy but you can put it as 1 and thats the least used policy.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;all creadit goes to wfaguy&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;SELECT&lt;BR /&gt;snapshot_policy.name,&lt;BR /&gt;vserver.name AS 'vserver.name',&lt;BR /&gt;cluster.primary_address AS 'vserver.cluster.primary_address',&lt;BR /&gt;count(volume.name)&lt;BR /&gt;FROM&lt;BR /&gt;cm_storage.snapshot_policy&lt;BR /&gt;LEFT JOIN&lt;BR /&gt;cm_storage.volume&lt;BR /&gt;ON volume.snapshot_policy_id=snapshot_policy.id&lt;BR /&gt;LEFT JOIN&lt;BR /&gt;cm_storage.vserver&lt;BR /&gt;ON snapshot_policy.vserver_id = vserver.id&lt;BR /&gt;LEFT JOIN&lt;BR /&gt;cm_storage.cluster&lt;BR /&gt;ON vserver.cluster_id = cluster.id&lt;BR /&gt;WHERE&lt;BR /&gt;snapshot_policy.name REGEXP '${regex}'&lt;BR /&gt;AND (&lt;BR /&gt;cluster.name = '${cluster_name}'&lt;BR /&gt;OR cluster.primary_address = '${cluster_name}'&lt;BR /&gt;)&lt;BR /&gt;AND vserver.name = '${vserver_name}'&lt;BR /&gt;GrOUp by&lt;BR /&gt;snapshot_policy.name,&lt;BR /&gt;vserver.name,&lt;BR /&gt;cluster.primary_address&lt;BR /&gt;ORDER BY&lt;BR /&gt;count(volume.name) LIMIT 100&lt;/P&gt;</description>
      <pubDate>Mon, 22 Jan 2018 22:46:24 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Snapshot-policy-query-how-to-list-in-order-by-number-of-volumes-already-assigned/m-p/137514#M24929</guid>
      <dc:creator>CAPATEL_NET1984</dc:creator>
      <dc:date>2018-01-22T22:46:24Z</dc:date>
    </item>
    <item>
      <title>Re: Snapshot policy query: how to list in order by number of volumes already assigned to policy</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Snapshot-policy-query-how-to-list-in-order-by-number-of-volumes-already-assigned/m-p/137515#M24930</link>
      <description>&lt;P&gt;also if the policy is created at cluster level then in the vserevr use admin vserver name. you can find admin vserver name by using vserver show command&lt;/P&gt;</description>
      <pubDate>Mon, 22 Jan 2018 22:47:51 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/Snapshot-policy-query-how-to-list-in-order-by-number-of-volumes-already-assigned/m-p/137515#M24930</guid>
      <dc:creator>CAPATEL_NET1984</dc:creator>
      <dc:date>2018-01-22T22:47:51Z</dc:date>
    </item>
  </channel>
</rss>

