<?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: SQL Query for &amp;quot;inactive&amp;quot; volumes in Active IQ Unified Manager Discussions</title>
    <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/SQL-Query-for-quot-inactive-quot-volumes/m-p/112246#M19861</link>
    <description>&lt;P&gt;You've may have resolved by now, but if I remember correctly in 7-mode there is a setting (option?) called auto export or something similar. So even if a volume is created and never intended for nfs use it may still be exported. Have you peeked in the /etc/exports file for any remnents of a line that references said volume(s)?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The better debug technique would be to use a SQL query tool (MySql workbench, Heidi, etc) to look at the contents of the storage.nfs_exports table&lt;/P&gt;</description>
    <pubDate>Thu, 05 Nov 2015 17:55:32 GMT</pubDate>
    <dc:creator>korns</dc:creator>
    <dc:date>2015-11-05T17:55:32Z</dc:date>
    <item>
      <title>SQL Query for "inactive" volumes</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/SQL-Query-for-quot-inactive-quot-volumes/m-p/110485#M19495</link>
      <description>&lt;P&gt;I'm stumped, and am hoping someone can help me find my flaw in the sql query I'm trying to write. &amp;nbsp; I'm writing a query that will be used in a multi-select user input. I am attempting to find 'inactive' volumes to offline. This means that I'm looking for volumes that have no associated shares, nfs exports, and active luns. &amp;nbsp;Below is my query. When it runs, it returns no results. (Which I know is completely wrong) &amp;nbsp;I did some troubleshooting and have narrowed it down with it not liking the nfs export line. If I comment out that line, I get a result. As soon as I add in the nfs export line the result becomes zero. I would appreciate any input anyone has.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;select array.name as Array, volume.name as Volume, volume.discovery_timestamp&lt;BR /&gt;FROM storage.volume join storage.array on volume.array_id = array.id&lt;BR /&gt;where&lt;BR /&gt;##Make sure the Volume does not contain an active LUN.&lt;BR /&gt;volume.id NOT IN (select lun.volume_id from storage.lun where lun.is_online = '1' AND lun.mapped = '1')&lt;BR /&gt;##Make sure the volume doesn't have an active share associated with it.&lt;BR /&gt;AND volume.id NOT IN (select storage.cifs_share.volume_id FROM storage.cifs_share)&lt;BR /&gt;##Make sure the volume doesn't have an active share associated with it.&lt;BR /&gt;AND volume.id NOT IN (select nfs_export.volume_id FROM storage.nfs_export)&lt;BR /&gt;order by Array,Volume,discovery_timestamp&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jun 2025 23:08:52 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/SQL-Query-for-quot-inactive-quot-volumes/m-p/110485#M19495</guid>
      <dc:creator>coreywanless</dc:creator>
      <dc:date>2025-06-04T23:08:52Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Query for "inactive" volumes</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/SQL-Query-for-quot-inactive-quot-volumes/m-p/110729#M19542</link>
      <description>&lt;P&gt;*Bump* - I know this is not good etiquette, but I'm stumped on this seemingly simple issue.&lt;/P&gt;</description>
      <pubDate>Wed, 07 Oct 2015 12:43:36 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/SQL-Query-for-quot-inactive-quot-volumes/m-p/110729#M19542</guid>
      <dc:creator>coreywanless</dc:creator>
      <dc:date>2015-10-07T12:43:36Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Query for "inactive" volumes</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/SQL-Query-for-quot-inactive-quot-volumes/m-p/112246#M19861</link>
      <description>&lt;P&gt;You've may have resolved by now, but if I remember correctly in 7-mode there is a setting (option?) called auto export or something similar. So even if a volume is created and never intended for nfs use it may still be exported. Have you peeked in the /etc/exports file for any remnents of a line that references said volume(s)?&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;The better debug technique would be to use a SQL query tool (MySql workbench, Heidi, etc) to look at the contents of the storage.nfs_exports table&lt;/P&gt;</description>
      <pubDate>Thu, 05 Nov 2015 17:55:32 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/SQL-Query-for-quot-inactive-quot-volumes/m-p/112246#M19861</guid>
      <dc:creator>korns</dc:creator>
      <dc:date>2015-11-05T17:55:32Z</dc:date>
    </item>
    <item>
      <title>Re: SQL Query for "inactive" volumes</title>
      <link>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/SQL-Query-for-quot-inactive-quot-volumes/m-p/112697#M19943</link>
      <description>&lt;P&gt;I just wanted to give an update. I was able to devote some time to this, and redesign the query. Along the way I had to make some corrections within WFA and DFM.&amp;nbsp;&lt;/P&gt;&lt;P&gt;1. WFA by default doesn't pull the cifs shares on the 7 mode data sources. &amp;nbsp;- You have to enable the acquisition under Designer -&amp;gt;&amp;nbsp;Dictionaries&lt;/P&gt;&lt;P&gt;2. DFM wasn't pulling the export data properly from the 7-Mode filers. &amp;nbsp;I had to fix configurations on some of the filers within DFM. (Without doing that some of the volumes would show up as not being used)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Finally, &amp;nbsp;Attached&amp;nbsp;was the query&amp;nbsp;that I have re-writen since my original post.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;DISCLAIMER: This query is provided at NO guarantee. You should manually check your volumes outside of WFA before making any action based on the query I provide. This query is only to assist you in not shooting yourself in the foot by accidently offlining/destroying a volume that has something currently active.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 18 Nov 2015 15:35:56 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Active-IQ-Unified-Manager-Discussions/SQL-Query-for-quot-inactive-quot-volumes/m-p/112697#M19943</guid>
      <dc:creator>coreywanless</dc:creator>
      <dc:date>2015-11-18T15:35:56Z</dc:date>
    </item>
  </channel>
</rss>

