- Community Home
- >
- Storage
- >
- HPE Nimble Storage
- >
- Array Setup and Networking
- >
- Re: PowerShell Module
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО05-28-2013 11:23 AM
тАО05-28-2013 11:23 AM
PowerShell Module
jrich523/NimblePowerShell ┬╖ GitHub
Built and tested in Version 3 (v2 compatibility will be validated but it should be fine)
Install
Run the following line in PowerShell
iex (new-object System.Net.WebClient).DownloadString('https://raw.github.com/jrich523/NimblePowerShell/master/Install.ps1')
Load
In powershell load the module by typing:
Import-Module Nimble
This might prompt for loading depending on what your execution policy is.
To get a list of commands type:
Get-Command -module Nimble
currently the help files are not populated but once I get basic functionality up and running I'll start to sure up the code and populate help details.
Examples
##Connect to array first, currently only handles one array
Connect-NSArray -SystemName 192.168.1.55 -Password p@ssw0rd ##currently password is just clear text, will change that soon
#List volumes
Get-NSVolume
#New volume
New-NSVolume -Name testvol -Size 1tb -Description "powershell test" -PerformancePolicy default
#a more detailed example, assume you have a "clonetest" volume:
Get-NSVolume
Get-NSSnapShot -Volume clonetest
Get-NSVolume -Name clonetest| New-NSSnapshot -Name CloneTest2 | New-NSClone -Name CloneTest2
Get-NSSnapShot -Volume clonetest
Get-NSVolume
Get-NSVolume clonetest2 | Get-NSVolumeACL
Get-NSInitiatorGroup
Add-NSInitiatorGroupToVolume -InitiatorGroup esx -Volume clonetest2 -Access Volume
Get-NSVolume clonetest2 | Get-NSVolumeACL
Get-NSVolume clonetest2 | Get-NSVolumeACL | Get-NSInitiatorGroup
Remove-NSVolume clonetest2 -Force
Get-NSVolume clonetest | Get-NSSnapShot | Remove-NSSnapShot
Requests
If you have a special need let me know i can probably easily add it in, just trying to get base functionality and work towards replication the UI functionality.
Message was edited by: Justin Rich
module version 1.1 uploaded
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-12-2014 08:57 AM
тАО01-12-2014 08:57 AM
Re: PowerShell Module
I have made some updates, mostly around docs so that cmdlets should have their help populated.
Also I added some functions around the performance policy stuff.
There will be a few more updates coming.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-16-2014 07:51 AM
тАО01-16-2014 07:51 AM
Re: PowerShell Module
Good stuff!
I have a question about the module. There is a file called GroupMgmt.dll. Are you the author of this? Is source available?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-16-2014 08:18 AM
тАО01-16-2014 08:18 AM
Re: PowerShell Module
Nimble actually works off SOAP calls so this is an automatically generated dll from visual studio.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-16-2014 08:31 AM
тАО01-16-2014 08:31 AM
Re: PowerShell Module
That's very interesting. Does Nimble publish a WSDL with the available interfaces?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-16-2014 08:47 AM
тАО01-16-2014 08:47 AM
Re: PowerShell Module
Not really, which is whats been making this so tricky, however today i should have a new version published with full examples!
The only thing (I think) that will be left will be CHAPS and creating protection plans/schedules.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-16-2014 09:35 AM
тАО01-16-2014 09:35 AM
Re: PowerShell Module
I get an error when I load the module.
Import-Module : The module manifest nimble.psd1 could not be processed because it is not a valid Windows PowerShell restricted language file. Remove the elements that are not permitted by the restricted language:
At C:\...\Modules\nimble\nimble.psd1:64 char:22
+ FormatsToProcess = @(Nimble.format.ps1xml)
+ ~~~~~~~~~~~~~~~~~~~~
The command 'Nimble.format.ps1xml' is not allowed in restricted language mode or a Data section.
At line:1 char:1
I unblocked the zip file before extracting and I've also tried using -force on the Import-Module cmdlet...
Anything I'm missing?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-16-2014 09:45 AM
тАО01-16-2014 09:45 AM
Re: PowerShell Module
hmm could have sworn i fixed that before i uploaded it, its a simple problem, just need to quote it, the line should look like
FormatsToProcess = @('Nimble.format.ps1xml')
im not so good at the whole git thing
i should actually have a newer, and much better, version in the next hour or two.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-16-2014 11:43 AM
тАО01-16-2014 11:43 AM
Re: PowerShell Module
Thanks!
That fixed it.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-16-2014 02:17 PM
тАО01-16-2014 02:17 PM
Re: PowerShell Module
There an update and an installer! not sure how well it would work with updating, but a clean install works great. I've had a chance to test most of the cmdlets pretty well.
a large portion of the help test is populated but not all of it.
let me know if you have any problems or suggestions!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-23-2014 11:15 AM
тАО01-23-2014 11:15 AM
Re: PowerShell Module
After running: Connect-NSArray -SystemName 192.168.1.55 -Password p@ssw0rd I get:
Exception calling "getControllerName" with "1" argument(s): "Method 'getControllerName' not implemented: method name or namespace not recognized"
At C:\Users\a_jesse\Documents\WindowsPowerShell\Modules\Nimble\Login.ps1:37 char:7
+ $arrname = $script:nsunit.getControllerName($sid.value)
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : NotSpecified: (:) [], MethodInvocationException
+ FullyQualifiedErrorId : SoapHeaderException
It does still connect to the array and I can add and remove volumes but I thought you might like to fix this.
Otherwise I am very eager to see future development! This is great! Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-23-2014 11:23 AM
тАО01-23-2014 11:23 AM
Re: PowerShell Module
Interesting, what version of software are you running with your unit?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-23-2014 11:32 AM
тАО01-23-2014 11:32 AM
Re: PowerShell Module
I'd love to chat with you to get familiar with Poweshell scripts and Nimble
in particular. Novice with CLI outside of Novell.
Regards,
Mark.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-23-2014 11:37 AM
тАО01-23-2014 11:37 AM
Re: PowerShell Module
I usually sit in IRC, which you can access via Live Chat | PowerShell Community Groups
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-23-2014 12:56 PM
тАО01-23-2014 12:56 PM
Re: PowerShell Module
2.0.3.0-40779-opt
It might be our version, we are in a little bit of a special situation with Nimble and our unit.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-23-2014 01:01 PM
тАО01-23-2014 01:01 PM
Re: PowerShell Module
hmm they must have changed the API.
all that does is print out the name of the unit you are connecting to, so it really has no impact on the operations of things.
will be interesting to see if you run in to any other errors.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-23-2014 01:12 PM
тАО01-23-2014 01:12 PM
Re: PowerShell Module
I will keep you posted if I do but all of the commands appear to be working so far. Just cosmetic at this point.
Thanks for this, much easier, quicker, and cleaner than plink
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-23-2014 01:15 PM
тАО01-23-2014 01:15 PM
Re: PowerShell Module
yeah i actually had to do a good chunk of vmware work (hence all the other posts) and i was real happy about how easy it all was. made it a pleasure to do!
also found some bugs, so i've had updates, as late as yesterday.
I havent tried using the installer to overwrite/update, but i cant see why it wouldnt. depending on when you installed it, you might want to grab an update.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-23-2014 01:46 PM
тАО01-23-2014 01:46 PM
Re: PowerShell Module
Just installed it a couple hours ago so it should be the latest. I have a project that was put on hold for awhile that I am circling back to. I will post the script up when I am done so folks can see a sample script.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-23-2014 02:23 PM
тАО01-23-2014 02:23 PM
Re: PowerShell Module
great, cant wait to see it!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-28-2014 08:13 PM
тАО01-28-2014 08:13 PM
Re: PowerShell Module
Hello Justin,
I am attempting to use a PS script to create multiple volumes on an array using this module. However, when attempting to set the performance policy name I receive errors. It appears that it does not like the spaces in the performance policy name. Please see the error below:
New-NSVolume : Cannot validate argument on parameter 'PerformancePolicy'. The argument "Exchange 2010 data store" does not belong to the set "default,DPM,'Exchange 2003 data store','Exchange 2007 data store','Exchange 2010 data store','Exchange log','Hyper-V CSV','Oracle OLTP',SharePoint,'SQL Server','SQL Server 2012','SQL Server Logs','VMware ESX','VMware ESX 5','VMware VDI','Windows File Server'" specified by the ValidateSet attribute. Supply an argument that is in the set and then try the command again.
At line:3 char:67 + New-NSVolume -Name $_.LunName -Size $_.LunSize -PerformancePolicy $_.Preformance ...
Is there any way around this?
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-29-2014 08:28 AM
тАО01-29-2014 08:28 AM
Re: PowerShell Module
Did you try to manually quote it? Im trying to find a good way around the space problem, its actually a bug with powershell and the dynamic validation sets.
If you did try the quotes and it still doesnt work, then you arent the only one.
Im working through this problem with someones else (here Re: Automate ESX Datastore creation with Nimble PowerShell Module) and i've suggested they reinstall the module. Im not sure when you pulled it down, but there might have been a bug in one of the posted versions. close powershell, remove the Nimble folder from your module path (my documents\windowspowershell\modules) and then run the installer again.
also what version of powershell are you using?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-29-2014 10:15 AM
тАО01-29-2014 10:15 AM
Re: PowerShell Module
Justin,
I have tried with single quotes, double quotes and both single inside double but the same result every time. I first downloaded the module on 1/28 in the afternoon.
I'm using powercli 5.5 release 1 and powershell ISE has the same result.
Thanks!
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-29-2014 11:03 AM
тАО01-29-2014 11:03 AM
Re: PowerShell Module
What version of powershell though? 2, 3 or 4?
I did all my testing in 3 and 4.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО01-29-2014 11:30 AM
тАО01-29-2014 11:30 AM
Re: PowerShell Module
I am running version 3