Powershell reference

Software-based VM-centric and flash-friendly VM storage + free version

Moderators: anton (staff), art (staff), Max (staff), Anatoly (staff)

Post Reply
rrbnc
Posts: 26
Joined: Mon Nov 24, 2014 3:06 am

Wed Apr 26, 2017 11:54 pm

Is there a powershell reference guide for managing StarWind from the command line?
Ivan (staff)
Staff
Posts: 172
Joined: Thu Mar 09, 2017 6:30 pm

Thu Apr 27, 2017 3:50 pm

Hello rrbnc,
Thanks for interesting in StarWind solution
You can find all documentation about StarWindX in this folder - X:\Program Files\StarWind Software\StarWind\StarWindX\Help
NetWise
Posts: 7
Joined: Sat Feb 18, 2012 6:00 am

Thu May 11, 2017 4:52 pm

Ivan (staff) wrote:Hello rrbnc,
Thanks for interesting in StarWind solution
You can find all documentation about StarWindX in this folder - X:\Program Files\StarWind Software\StarWind\StarWindX\Help
Am I not finding the PowerShell command reference in there? That location is particularly weak on PowerShell documentation of any sort.

Additionally this:

PS C:\Program Files\StarWind Software\StarWind\StarWindX\Samples\powershell> get-help starwindx | ft -autosize

Name Category Module Synopsis
---- -------- ------ --------
Add-HADevice Function StarWindX Creating New High Availability Device
Add-IBVDevice Function StarWindX Creating new thin-provisioned virtual device
Add-ImageDevice Function StarWindX Creating a new virtual device (ImageFile device).
Add-RamDevice Function StarWindX Creating a RAM disk
Add-VirtualTape Function StarWindX Add a new Virtual Tape to the existing Virtual Tape Library
Add-VirtualTapeLibrary Function StarWindX Creates a Virtual Tape Library
New-VTLFile Function StarWindX Creating an header file for a Virtual Tape Library

Is rather disappointing. Where are all the Get- and Remove- type of commands? Nothing there is configuring NIC's or IQN's or target groups or....?

Is the PowerShell module functionally complete at this time?
Ivan (staff)
Staff
Posts: 172
Joined: Thu Mar 09, 2017 6:30 pm

Mon May 15, 2017 5:43 pm

Hello NetWise,
Thanks for interesting in StarWind solution.
We will work on Help for StarWindX and in the next builds will be more samples and information about commands.
rlaber
Posts: 1
Joined: Mon May 29, 2017 2:12 pm

Mon May 29, 2017 2:33 pm

Hello,

I tried to do a simple task:

1. create a snapshot
2. copy some files out of it
3. remove that snapshot

Step 1 and 3 are easy with the well documented cmdlets new-snapshot and remove-snapshot. That works as expected.

But how can the snapshot be accessed with a powershell script? With the interactive GUI, I use the snapshot manager and press the Mount button. That creates a new device and a target. But I didn't find any documentation about how to perform this from within a powershell script. I guess, there is a special snapshot device to be created, assigned to a target that I can connect to and then access the files.

Is there any doc or example on how to do that. Can anybody help me?

Thanks in advance

Rudolf
Michael (staff)
Staff
Posts: 317
Joined: Thu Jul 21, 2016 10:16 am

Fri Jun 02, 2017 9:10 pm

Hello Rudolf,

Unfortunately, the PowerShell script for mounting devices is still under development and will be available in the next builds.
We will keep the community posted once it will be available.
Chill0309
Posts: 3
Joined: Sat Jun 09, 2018 10:51 am

Sat Jun 09, 2018 11:06 am

Michael (staff) wrote:Hello Rudolf,

Unfortunately, the PowerShell script for mounting devices is still under development and will be available in the next builds.
We will keep the community posted once it will be available.
Is this functionality now available in the latest build?
Oleg(staff)
Staff
Posts: 568
Joined: Fri Nov 24, 2017 7:52 am

Tue Jun 12, 2018 3:18 pm

No, this functionality is not available yet.
Sekkmer
Posts: 29
Joined: Thu Mar 08, 2018 12:11 pm

Wed Jun 13, 2018 6:57 am

A few days ago I posted a library that can do this for LSFS devices here is the code in C# on line 53:

https://github.com/Sekkmer/StarWindXExt ... ensions.cs

Although it is in C# you can translate it to PowerShell only some syntax need to be changed.

As for HA snapshots, they work a bit differently and unfortunately, the parameters are shorted in the current StarWindX so the ("Async", "yes") is before the "MountSnaphot" parameter however for the server "MountSnaphot" must be the first.

This might actually work without the Async parameter, I haven't tested it yet.
Boris (staff)
Staff
Posts: 805
Joined: Fri Jul 28, 2017 8:18 am

Wed Jun 13, 2018 5:59 pm

I believe what Oleg meant was that there is no official sample scripts for doing this. Sure, using your custom library may do the trick.
ayaanleo
Posts: 1
Joined: Sun Aug 19, 2018 6:48 am
Contact:

Sun Aug 19, 2018 6:54 am

Ken,

For this purpose you can use the two scripts from StarWindX. Their default path is "C:\Program Files\StarWind Software\StarWind\StarWindX\Samples\powershell\" and particular scripts that you need are GetHASyncState.ps1 to check the synchronization status and syncHaDevice.ps1 to synchronize it.

----------------------------
Top Rated Best Toys and Gifts for 5 Year Old Girls (Review) in 2020. Get the list of best toys Ideas for Five years old girls.
Last edited by ayaanleo on Mon Sep 28, 2020 6:35 am, edited 1 time in total.
Boris (staff)
Staff
Posts: 805
Joined: Fri Jul 28, 2017 8:18 am

Mon Aug 20, 2018 3:39 pm

It looks like that was posted to a wrong thread.
Post Reply