<?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: storage_disk_get_iter not able to iterate over each attribute in Software Development Kit (SDK) and API Discussions</title>
    <link>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/storage-disk-get-iter-not-able-to-iterate-over-each-attribute/m-p/114302#M1709</link>
    <description>&lt;P&gt;The NMSDK documentation has some sample code which might&amp;nbsp;have what you need, or something very close. &amp;nbsp;In particular, look for the sample script named "vollist.pl".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What is the output you are wanting?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Andrew&lt;/P&gt;</description>
    <pubDate>Tue, 05 Jan 2016 21:24:45 GMT</pubDate>
    <dc:creator>asulliva</dc:creator>
    <dc:date>2016-01-05T21:24:45Z</dc:date>
    <item>
      <title>storage_disk_get_iter not able to iterate over each attribute</title>
      <link>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/storage-disk-get-iter-not-able-to-iterate-over-each-attribute/m-p/114294#M1708</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I am using perl api storage_disk_get_iter for 7-mode to get the disk details my code looks like below but i am not able to get desired output.&lt;/P&gt;&lt;P&gt;can someone please guide me how to iterate over each attribute list&lt;/P&gt;&lt;P&gt;$out = $s-&amp;gt;invoke("storage-disk-get-iter");&lt;BR /&gt;if($out-&amp;gt;results_status() eq "failed")&lt;BR /&gt;{&lt;BR /&gt;print($out-&amp;gt;results_reason() ."\n");&lt;BR /&gt;exit(-2);&lt;BR /&gt;}&lt;BR /&gt;my $aggrs = $out-&amp;gt;child_get("attributes-list");&lt;BR /&gt;my @aresult = $aggrs-&amp;gt;children_get();&lt;/P&gt;&lt;P&gt;foreach $aggr (@aresult){&lt;BR /&gt;my $storage = $aggr-&amp;gt;child_get("storage-disk-info");&lt;BR /&gt;my &lt;a href="https://community.netapp.com/t5/user/viewprofilepage/user-id/45599"&gt;@get&lt;/a&gt;_info = $storage-&amp;gt;children_get();&lt;BR /&gt;foreach $pat(@get_info){&lt;BR /&gt;my $get = $storage-&amp;gt;child_get("disk-inventory-info");&lt;BR /&gt;my &lt;a href="https://community.netapp.com/t5/user/viewprofilepage/user-id/120793"&gt;@Good&lt;/a&gt; = $get-&amp;gt;children_get();&lt;BR /&gt;foreach $met(@good){&lt;BR /&gt;my $raid_type = $pat-&amp;gt;child_get_string("disk-type");&lt;BR /&gt;print "$raid_type";&lt;BR /&gt;}&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jun 2025 22:23:46 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/storage-disk-get-iter-not-able-to-iterate-over-each-attribute/m-p/114294#M1708</guid>
      <dc:creator>rdx_in</dc:creator>
      <dc:date>2025-06-04T22:23:46Z</dc:date>
    </item>
    <item>
      <title>Re: storage_disk_get_iter not able to iterate over each attribute</title>
      <link>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/storage-disk-get-iter-not-able-to-iterate-over-each-attribute/m-p/114302#M1709</link>
      <description>&lt;P&gt;The NMSDK documentation has some sample code which might&amp;nbsp;have what you need, or something very close. &amp;nbsp;In particular, look for the sample script named "vollist.pl".&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;What is the output you are wanting?&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Andrew&lt;/P&gt;</description>
      <pubDate>Tue, 05 Jan 2016 21:24:45 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/storage-disk-get-iter-not-able-to-iterate-over-each-attribute/m-p/114302#M1709</guid>
      <dc:creator>asulliva</dc:creator>
      <dc:date>2016-01-05T21:24:45Z</dc:date>
    </item>
    <item>
      <title>Re: storage_disk_get_iter not able to iterate over each attribute</title>
      <link>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/storage-disk-get-iter-not-able-to-iterate-over-each-attribute/m-p/114307#M1711</link>
      <description>&lt;P&gt;my want number of disk which are unowned + type of disk + reason of failed disk + rpm&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;i checked disk-list-info + sanown info...both of them dosen't have the all information&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Wed, 06 Jan 2016 01:18:56 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/storage-disk-get-iter-not-able-to-iterate-over-each-attribute/m-p/114307#M1711</guid>
      <dc:creator>rdx_in</dc:creator>
      <dc:date>2016-01-06T01:18:56Z</dc:date>
    </item>
    <item>
      <title>Re: storage_disk_get_iter not able to iterate over each attribute</title>
      <link>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/storage-disk-get-iter-not-able-to-iterate-over-each-attribute/m-p/114572#M1726</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;The api parameters can vary depending of ontapi version.&lt;/P&gt;&lt;P&gt;You can use ZExplore Development Interface to see what is available with which version.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here an example wirh Python in 1.21, where diskname, ownership, isfailed are retrieved. A lot of other information exist&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;import sys&lt;BR /&gt;from NaServer import *&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;PASSWORD= "xxxxx"&lt;/P&gt;&lt;P&gt;filer = NaServer("xxxxxx", 1 , 21)&lt;BR /&gt;filer.set_transport_type("HTTPS")&lt;BR /&gt;filer.set_port(443)&lt;BR /&gt;filer.set_server_type("FILER")&lt;/P&gt;&lt;P&gt;filer.set_style("LOGIN")&lt;BR /&gt;filer.set_admin_user("root", PASSWORD)&lt;/P&gt;&lt;P&gt;api = NaElement("storage-disk-get-iter")&lt;BR /&gt;api.child_add_string("max-records",500)&lt;/P&gt;&lt;P&gt;xo = filer.invoke_elem(api)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;if (xo.results_status() == "failed") :&lt;BR /&gt;&amp;nbsp; &amp;nbsp;print ("Error:\n")&lt;BR /&gt;&amp;nbsp; &amp;nbsp;print (xo.sprintf())&lt;BR /&gt;&amp;nbsp; &amp;nbsp;sys.exit (1)&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;attrib = xo.child_get("attributes-list")&lt;BR /&gt;disks = attrib.children_get()&lt;BR /&gt;for disk in disks:&lt;BR /&gt;&amp;nbsp; &amp;nbsp;diskname = disk.child_get_string("disk-name")&lt;BR /&gt;&amp;nbsp; &amp;nbsp;diskownership = disk.child_get("disk-ownership-info")&lt;BR /&gt;&amp;nbsp; &amp;nbsp;diskfailed = diskownership.child_get_string("is-failed")&lt;BR /&gt;&amp;nbsp; &amp;nbsp;print(diskname)&lt;BR /&gt;&amp;nbsp; &amp;nbsp;print(diskfailed)&lt;BR /&gt;&amp;nbsp; &amp;nbsp;print(diskownership.child_get_string("owner-node-id"))&lt;BR /&gt;&amp;nbsp; &amp;nbsp;print("-------------------")&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Tue, 12 Jan 2016 16:11:41 GMT</pubDate>
      <guid>https://community.netapp.com/t5/Software-Development-Kit-SDK-and-API-Discussions/storage-disk-get-iter-not-able-to-iterate-over-each-attribute/m-p/114572#M1726</guid>
      <dc:creator>francoisbnc</dc:creator>
      <dc:date>2016-01-12T16:11:41Z</dc:date>
    </item>
  </channel>
</rss>

