<?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: Powershell create profile from template in HPE OneView</title>
    <link>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/6973845#M2041</link>
    <description>&lt;P&gt;As I am the developer and maintainer of the PowerShell library, I wanted to make 1 slight correction:&lt;/P&gt;&lt;P&gt;You can use a lower Major.Minor versioned library with a newer appliance.&amp;nbsp; So, using the 3.00 PowerShell library will work with a 3.10 appliance.&amp;nbsp; Please know that I will only support N-2 HPE OneView appliance to PowerShell library versions, which will follows the appliance supported API versions.&lt;/P&gt;</description>
    <pubDate>Mon, 14 Aug 2017 19:05:28 GMT</pubDate>
    <dc:creator>ChrisLynch</dc:creator>
    <dc:date>2017-08-14T19:05:28Z</dc:date>
    <item>
      <title>Powershell create profile from template</title>
      <link>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/6973822#M2039</link>
      <description>&lt;P&gt;So not quite following the logic on the powershell wiki. &amp;nbsp;Is there actually a way to create a profile from a server template? &amp;nbsp;Assumed it was copy profile but that didn't work, or I did it wrong. &amp;nbsp;Google fu is failing me when attempting to find a script. &amp;nbsp;Any suggestions? &amp;nbsp;I am on Oneview 3.1 and using PS module 300.&lt;/P&gt;</description>
      <pubDate>Mon, 14 Aug 2017 17:37:36 GMT</pubDate>
      <guid>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/6973822#M2039</guid>
      <dc:creator>Rick Drake</dc:creator>
      <dc:date>2017-08-14T17:37:36Z</dc:date>
    </item>
    <item>
      <title>Re: Powershell create profile from template</title>
      <link>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/6973836#M2040</link>
      <description>&lt;P&gt;First, if you are using OneView 3.1 then you should be using the 3.1 version of the PowerShell library found here:&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/HewlettPackard/POSH-HPOneView/releases/tag/v3.10.1377.2109" target="_blank"&gt;https://github.com/HewlettPackard/POSH-HPOneView/releases/tag/v3.10.1377.2109&lt;/A&gt;&lt;/P&gt;&lt;P&gt;Secondly, if you look at the WIKI for the 3.1 version of the New-HPOVServerProfile cmdlet found here:&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/HewlettPackard/POSH-HPOneView/wiki/New-HPOVServerProfile#3.10" target="_blank"&gt;https://github.com/HewlettPackard/POSH-HPOneView/wiki/New-HPOVServerProfile#3.10&lt;/A&gt;&lt;/P&gt;&lt;P&gt;you will see several examples of how to use this call. &amp;nbsp;Example #2 on that page shows how to create a Server Profile by providing an existing template:&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;PRE&gt; -------------------------- EXAMPLE 2 --------------------------&lt;/PRE&gt;&lt;P&gt;PS C:\&amp;gt; $spt = Get-HPOVServerProfileTemplate -Name 'Hypervisor Cluster Node Template v1'&lt;/P&gt;&lt;P&gt;PS C:\&amp;gt; Get-HPOVServer -Name "Encl1, Bay 1" | New-HPOVServerProfile -name "Hyp-Clus-01" -ServerProfileTemplate $spt | Wait-HPOVTaskComplete&lt;/P&gt;&lt;P&gt;Hope this helps,&lt;/P&gt;&lt;P&gt;Dave&lt;/P&gt;</description>
      <pubDate>Mon, 14 Aug 2017 18:07:07 GMT</pubDate>
      <guid>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/6973836#M2040</guid>
      <dc:creator>Dave Olker</dc:creator>
      <dc:date>2017-08-14T18:07:07Z</dc:date>
    </item>
    <item>
      <title>Re: Powershell create profile from template</title>
      <link>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/6973845#M2041</link>
      <description>&lt;P&gt;As I am the developer and maintainer of the PowerShell library, I wanted to make 1 slight correction:&lt;/P&gt;&lt;P&gt;You can use a lower Major.Minor versioned library with a newer appliance.&amp;nbsp; So, using the 3.00 PowerShell library will work with a 3.10 appliance.&amp;nbsp; Please know that I will only support N-2 HPE OneView appliance to PowerShell library versions, which will follows the appliance supported API versions.&lt;/P&gt;</description>
      <pubDate>Mon, 14 Aug 2017 19:05:28 GMT</pubDate>
      <guid>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/6973845#M2041</guid>
      <dc:creator>ChrisLynch</dc:creator>
      <dc:date>2017-08-14T19:05:28Z</dc:date>
    </item>
    <item>
      <title>Re: Powershell create profile from template</title>
      <link>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/7022351#M3444</link>
      <description>&lt;P&gt;&amp;nbsp;Dave/Chris - I'm in a similar boat, hoping someone can help... This is a brand new&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;OneView&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;install (and I'm new to&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;OV&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;as well). I'm using&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;OneView&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;4.10.01 and the 4.10&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;PowerShell&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;LIbrary. Two functions don't seem to be working as expected. I've created a Server Profile Template "ACDC&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;DL-360&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;Gen10", and I've added a Server Hardware with Name&amp;nbsp;"ILOMXQ8340076". But when I try to create a new Server Profile for it, using the Example info in the original document and in Dave's comment above, I use this modified&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;commandline:&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;$spt = Get-HPOVServerProfileTemplate -Name 'ACDC DL-360 Gen10'
Get-HPOVServer -Name "ILOMXQ8340076" | New-HPOVServerProfile -name "DL360-.136" -ServerProfileTemplate $spt | Wait-HPOVTaskComplete&lt;/PRE&gt;&lt;P&gt;But&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;I get&amp;nbsp;prompted to input an&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;AssignmentType. From what I read, the correct response here is "server", however as soon as I do that, I get the following error message:&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;PS C:\Users\Michael&amp;gt; $spt = Get-HPOVServerProfileTemplate -Name 'ACDC DL-360 Gen10'
PS C:\Users\Michael&amp;gt; Get-HPOVServer -Name "ILOMXQ8340076" | New-HPOVServerProfile -name "DL360-.136" -ServerProfileTemplate $spt | Wait-HPOVTaskComplete

cmdlet New-HPOVServerProfile at command pipeline position 2
Supply values for the following parameters:
AssignmentType: server
New-HPOVServerProfile : A Server resource object or name must be provided when using the "Server" AssignmentType parameter.
At line:1 char:40
+ ... Q8340076" | New-HPOVServerProfile -name "DL360-.136" -ServerProfileTe ...
+                 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidArgument: (Server:String) [New-HPOVServerProfile], ServerProfileTemplateResourceException
    + FullyQualifiedErrorId : NullServerNotAllowed,New-HPOVServerProfile&lt;/PRE&gt;&lt;P&gt;I'm not sure what's missing, as I'm following the example fairly closely.&amp;nbsp;&lt;/P&gt;&lt;P&gt;I tried a second route, imported a second server, and created a Server Profile manually through the&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;HPOV&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;GUI. I then tried to use the Copy-HPOVServer&lt;SPAN&gt;&amp;nbsp;&lt;/SPAN&gt;Profile function as follows:&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;PS C:\Users\Michael&amp;gt; Copy-HPOVServerProfile -SourceName "DL360-.134" -DestinationName "DL360-.136" -assign "ILOMXQ8340076"
Copy-HPOVServerProfile : The Target Server Hardware Type does not match the source Profile Server Hardware Type. Please specify a different Server Hardware Device to
assign.
At line:1 char:1
+ Copy-HPOVServerProfile -SourceName "DL360-.134" -DestinationName "DL3 ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
    + CategoryInfo          : InvalidOperation: (Copy-HPOVProfile:String) [Copy-HPOVServerProfile], ServerProfileResourceException
    + FullyQualifiedErrorId : ServerHardwareTypeMismatch,Copy-HPOVServerProfile&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;As you can see, it's pretty simple logic, but for some reason it tells me the Hardware Type is different. This isn't the case, all the servers are identical, and are showing up in OneView that way:&amp;nbsp;&lt;/P&gt;&lt;PRE&gt;PS C:\Users\Michael&amp;gt; get-hpovserver

Name          ServerName Status Power Serial Number Model       ROM                    iLO       Server Profile License
----          ---------- ------ ----- ------------- -----       ---                    ---       -------------- -------
ILOMXQ8340076            OK     Off   MXQ8340076    DL360 Gen10 U32 v1.36 (02/14/2018) iLO5 1.35 No Profile     OneViewNoiLO
ILOMXQ834007B            OK     Off   MXQ834007B    DL360 Gen10 U32 v1.42 (06/20/2018) iLO5 1.35 DL360-.134     OneViewNoiLO
ILOMXQ834007F            OK     Off   MXQ834007F    DL360 Gen10 U32 v1.36 (02/14/2018) iLO5 1.35 No Profile     OneViewNoiLO&lt;/PRE&gt;&lt;P&gt;Any ideas?&amp;nbsp;Are these bugs? Documentation errors? Any alternative ideas for me?&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Michael&lt;/P&gt;</description>
      <pubDate>Thu, 18 Oct 2018 22:12:32 GMT</pubDate>
      <guid>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/7022351#M3444</guid>
      <dc:creator>ArubaGuy</dc:creator>
      <dc:date>2018-10-18T22:12:32Z</dc:date>
    </item>
    <item>
      <title>Re: Powershell create profile from template</title>
      <link>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/7022353#M3445</link>
      <description>&lt;P&gt;The first issue you reported is a bug, where logic checking for &lt;FONT face="courier new,courier"&gt;-Serve&lt;/FONT&gt;r parameter, is flawed.&amp;nbsp; To get past it, you should omit Pipeline operation at this time, and supply &lt;FONT face="courier new,courier"&gt;-Server&lt;/FONT&gt; and &lt;FONT face="courier new,courier"&gt;-AssignmentType&lt;/FONT&gt; during execution of &lt;FONT face="courier new,courier"&gt;New-HPOVServerProfile&lt;/FONT&gt;.&lt;/P&gt;</description>
      <pubDate>Thu, 18 Oct 2018 22:34:11 GMT</pubDate>
      <guid>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/7022353#M3445</guid>
      <dc:creator>ChrisLynch</dc:creator>
      <dc:date>2018-10-18T22:34:11Z</dc:date>
    </item>
    <item>
      <title>Re: Powershell create profile from template</title>
      <link>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/7022356#M3446</link>
      <description>&lt;P&gt;Thanks Chris! I was able to make it all work on one line as you suggested:&lt;/P&gt;&lt;PRE&gt;New-HPOVServerProfile -name "DL360-.133" -ServerProfileTemplate "ACDC DL-360 Gen10" -Server "ILOMXQ834007J" -AssignmentType "server"&lt;/PRE&gt;&lt;P&gt;I created a .PS1 batch file and it is adding the servers now.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Any idea why the Copy-HPOVServerProfile command didn't work?&lt;/P&gt;&lt;P&gt;Thanks again,&lt;BR /&gt;Michael&lt;/P&gt;</description>
      <pubDate>Fri, 19 Oct 2018 00:47:08 GMT</pubDate>
      <guid>https://community.hpe.com/t5/hpe-oneview/powershell-create-profile-from-template/m-p/7022356#M3446</guid>
      <dc:creator>ArubaGuy</dc:creator>
      <dc:date>2018-10-19T00:47:08Z</dc:date>
    </item>
  </channel>
</rss>

