<?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: Creating new host with powershell in EF &amp; E-Series, SANtricity, and Related Plug-ins</title>
    <link>https://community.netapp.com/t5/EF-E-Series-SANtricity-and-Related-Plug-ins/Creating-new-host-with-powershell/m-p/142761#M662</link>
    <description>&lt;P&gt;After checking with some folks, you would need to create the correct object type and pass that in as the argument for the -Ports parameter. Here's an example:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;$hostport = New-object -TypeName NetApp.Powershell.TO.HostPortCreateRequest # Use this as the argument

$hostport | Get-Member # to see the list of members that you can set

$hostport.Port = “WWPN” # 20000025B50B003C&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN style="caret-color: #000000; color: #000000; font-family: Arial, sans-serif; font-size: 13.333333015441895px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; text-decoration: none; display: inline !important; float: none;"&gt;Do the same for the host type if the it is looking for the same object type.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Mon, 17 Sep 2018 13:07:30 GMT</pubDate>
    <dc:creator>eseries_trailblazer</dc:creator>
    <dc:date>2018-09-17T13:07:30Z</dc:date>
    <item>
      <title>Creating new host with powershell</title>
      <link>https://community.netapp.com/t5/EF-E-Series-SANtricity-and-Related-Plug-ins/Creating-new-host-with-powershell/m-p/142647#M660</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I am trying to copy the hosts I have in an E2860 to a new E5760.&lt;/P&gt;
&lt;P&gt;I have extracted the information using get-nehost but am struggling with the format for the&lt;/P&gt;
&lt;P&gt;new-nehost command&lt;/P&gt;
&lt;P&gt;I get this error whether I use a variable or manually specify the value&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Lucida Console" size="1" color="#0000ff"&gt;new-nehost&lt;/FONT&gt; &lt;FONT face="Lucida Console" size="1" color="#000080"&gt;-Credential&lt;/FONT&gt; &lt;FONT face="Lucida Console" size="1" color="#ff4500"&gt;$NECred4&lt;/FONT&gt; &lt;FONT face="Lucida Console" size="1" color="#000080"&gt;-SystemId&lt;/FONT&gt; &lt;FONT face="Lucida Console" size="1" color="#800080"&gt;1&lt;/FONT&gt; &lt;FONT face="Lucida Console" size="1" color="#000080"&gt;-name&lt;/FONT&gt; &lt;FONT face="Lucida Console" size="1" color="#ff4500"&gt;$name&lt;/FONT&gt;&lt;FONT face="Lucida Console" size="1" color="#a9a9a9"&gt;.&lt;/FONT&gt;&lt;FONT face="Lucida Console" size="1"&gt;name &lt;/FONT&gt;&lt;FONT face="Lucida Console" size="1" color="#000080"&gt;-Ports&lt;/FONT&gt; &lt;FONT face="Lucida Console" size="1" color="#8b0000"&gt;"20000025B50B003C"&lt;/FONT&gt; &lt;FONT face="Lucida Console" size="1" color="#000080"&gt;-HostType&lt;/FONT&gt; &lt;FONT face="Lucida Console" size="1" color="#8a2be2"&gt;VmwTPGSALUA &lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Lucida Console" size="1" color="#ff0000"&gt;New-NeHost : Cannot bind parameter 'Ports'. Cannot convert the "20000025B50B003C" value of type "System.String" to type "NetApp.PowerShell.TO.HostPortCreateRequest" &lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Lucida Console" size="1"&gt;I get the same issue with hosttype.&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Lucida Console" size="1"&gt;The help page refers to the option as&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Lucida Console" size="1"&gt;-Ports [&amp;lt;List&amp;lt;HostPortCreateRequest&amp;gt;&amp;gt;]&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Lucida Console" size="1"&gt;&amp;nbsp;&lt;/FONT&gt;&lt;/P&gt;
&lt;P&gt;But I have not found a way of doing this.&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;FONT face="Lucida Console" size="1"&gt;Has anyone done this and could give me an example of the correct syntax.&lt;/FONT&gt;&lt;/P&gt;</description>
      <pubDate>Wed, 04 Jun 2025 13:19:53 GMT</pubDate>
      <guid>https://community.netapp.com/t5/EF-E-Series-SANtricity-and-Related-Plug-ins/Creating-new-host-with-powershell/m-p/142647#M660</guid>
      <dc:creator>TrevorParfitt</dc:creator>
      <dc:date>2025-06-04T13:19:53Z</dc:date>
    </item>
    <item>
      <title>Re: Creating new host with powershell</title>
      <link>https://community.netapp.com/t5/EF-E-Series-SANtricity-and-Related-Plug-ins/Creating-new-host-with-powershell/m-p/142761#M662</link>
      <description>&lt;P&gt;After checking with some folks, you would need to create the correct object type and pass that in as the argument for the -Ports parameter. Here's an example:&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;PRE&gt;$hostport = New-object -TypeName NetApp.Powershell.TO.HostPortCreateRequest # Use this as the argument

$hostport | Get-Member # to see the list of members that you can set

$hostport.Port = “WWPN” # 20000025B50B003C&lt;/PRE&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&lt;SPAN style="caret-color: #000000; color: #000000; font-family: Arial, sans-serif; font-size: 13.333333015441895px; font-style: normal; font-variant-caps: normal; font-weight: normal; letter-spacing: normal; orphans: auto; text-align: start; text-indent: 0px; text-transform: none; white-space: normal; widows: auto; word-spacing: 0px; -webkit-text-size-adjust: auto; -webkit-text-stroke-width: 0px; text-decoration: none; display: inline !important; float: none;"&gt;Do the same for the host type if the it is looking for the same object type.&lt;/SPAN&gt;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Mon, 17 Sep 2018 13:07:30 GMT</pubDate>
      <guid>https://community.netapp.com/t5/EF-E-Series-SANtricity-and-Related-Plug-ins/Creating-new-host-with-powershell/m-p/142761#M662</guid>
      <dc:creator>eseries_trailblazer</dc:creator>
      <dc:date>2018-09-17T13:07:30Z</dc:date>
    </item>
  </channel>
</rss>

