StarWind vSAN Free..

Software-based VM-centric and flash-friendly VM storage + free version
tanjum
Posts: 34
Joined: Mon Jul 21, 2025 12:02 pm

Thu Jul 31, 2025 3:50 pm

yaroslav (staff) wrote:
Thu Jul 31, 2025 2:49 pm
You are right, yet the device will be misconfigured.
It means that the HA device was created. Please review the HA device header and remove the replication partner. Once removed, log to the destination node (i.e., where you intend replicating the drvices to) remove the swdsk files from /headers and underlying storage and img devices from the underlying of the destination node. Please make sure to do it only on the destination node.
Once done, run addHA partner.
Hi yaroslav,

I ran the CreateHA_2.ps1 script, and got this result from enumDevice for both Node 2 and Node 1.

I can see HAImage1 and imagefile1, it seems the LUN in Node 1 reassigns the device to HAImage1, and imagefile1 shows NoheaderFile for its state.

Node 2

Code: Select all

PS C:\Users\Administrator\Desktop> .\enumDevicesTargets.ps1
Target:
Name                     : iqn.2008-08.com.starwindsoftware:192.168.30.201-vlab
Id                       : 0x0000000001201B80
Alias                    : vlab
IsClustered              : True
Devices                  :
Node 1

Code: Select all

PS C:\Users\Administrator\Desktop> .\enumDevicesTargets.ps1
Target:
Name                     : iqn.2008-08.com.starwindsoftware:192.168.30.101-vlab
Id                       : 0x00000000011761C0
Alias                    : vlab
IsClustered              : True
Devices                  : HAImage1

Device:
Name                     : imagefile1
Id                       : 0x0000000001175A40
TargetName               : empty
TargetId                 : empty
State                    : NoHeaderFile
Size                     : 0

Device:
Name                     : HAImage1
Id                       : 0x00000000011D2A40
TargetName               : iqn.2008-08.com.starwindsoftware:192.168.30.101-vlab
TargetId                 : 0x00000000011761C0
DeviceType               : HA Image
State                    : NonActive
Size                     : 0
NodeType                 : 0
IsSnapshotsSupported     : 0
SectorSize               : -1
Priority                 : 0
SyncStatus               : 4294967295
SyncTrafficShare         : 0
DeviceLUN                :
Header                   : Headers\vlab\vlab_HA.swdsk
IsWaitingAutosync        : False
FailoverStrategy         : 0
MaintenanceMode          : 0
BitmapStrategy           : 0
After doing what was instructed, removing Node 2 from Node 1 and removing headers only from Node 2, and running addhapartner script it still shows the below error..

Code: Select all

PS C:\Users\Administrator\Desktop> .\AddHaPartner.ps1
Method invocation failed because [System.__ComObject] does not contain a method named 'AddPartner'.
Added IP address to the script..

Code: Select all

param($addr="192.168.30.101", $port=3261, $user="root", $password="starwind", $deviceName="imagefile1",
	$addr2="192.168.30.201", $port2=$port, $user2=$user, $password2=$password,
#secondary node
	$imagePath2="/mnt/md0/vol1",
	$imageName2="vlab",
	$createImage2=$true,
	$targetAlias2="vlab",
	$autoSynch2=$true,
	$poolName2="pool1",
	$syncSessionCount2=1,
	$aluaOptimized2=$true,
	$syncInterface2="#p2=192.168.35.201:3260,192.168.40.201:3260",
    $hbInterface2="#p2=192.168.45.201:3260,192.168.30.201:3260",
	$bmpType=1,
	$bmpStrategy=0,
	$bmpFolderPath="",
    $selfSyncInterface="#p1=192.168.35.101:3260,192.168.40.101:3260",
    $selfHbInterface="#p1=192.168.45.101:3260,192.168.30.101:3260"
	)
	
Import-Module StarWindX

try
{
    Enable-SWXLog
    
    $server = New-SWServer $addr $port $user $password
    $server.Connect()

	$device = Get-Device $server -name $deviceName
	if( !$device )
	{
		Write-Host "Device not found" -foreground red
		return
	}

    $node = new-Object Node
    $node.HostName = $addr2
    $node.HostPort = $port2
    $node.Login = $user2
    $node.Password = $password2
    $node.ImagePath = $imagePath2
    $node.ImageName = $imageName2
    $node.CreateImage = $createImage2
    $node.TargetAlias = $targetAlias2
    $node.SyncInterface = $syncInterface2
    $node.HBInterface = $hbInterface2
	$node.AutoSynch = $autoSynch2
	$node.SyncSessionCount = $syncSessionCount2
	$node.ALUAOptimized = $aluaOptimized2
	$node.PoolName = $poolName2
	$node.BitmapStoreType = $bmpType
	$node.BitmapStrategy = $bmpStrategy
	$node.BitmapFolderPath = $bmpFolderPath

    Add-HAPartner $device $node $selfSyncInterface $selfHbInterface $selfBmpFolderPath
}
catch
{
	Write-Host $_ -foreground red 
}
finally
{
	$server.Disconnect()
}
yaroslav (staff)
Staff
Posts: 4309
Joined: Mon Nov 18, 2019 11:11 am

Thu Jul 31, 2025 3:59 pm

I think the easiest will be arming the trial key and completing the work with the trial key.
Please log the call on MON with support to convert back to free (use this thread as your reference).
tanjum
Posts: 34
Joined: Mon Jul 21, 2025 12:02 pm

Thu Jul 31, 2025 4:46 pm

Thanks yaroslav,

I have requested the Trial Key, and will check and then revert back..

Appreciate all the help..
tanjum
Posts: 34
Joined: Mon Jul 21, 2025 12:02 pm

Thu Jul 31, 2025 5:40 pm

yaroslav (staff) wrote:
Thu Jul 31, 2025 3:59 pm
I think the easiest will be arming the trial key and completing the work with the trial key.
Please log the call on MON with support to convert back to free (use this thread as your reference).
Sorry, for clarity I'm not sure what you mean by completing the work, the 2nd server is not here yet so I can only use this in my test environment to see if it works as expected..
yaroslav (staff)
Staff
Posts: 4309
Joined: Mon Nov 18, 2019 11:11 am

Thu Jul 31, 2025 6:06 pm

I guess there is some misunderstanding here.
You are replicating the device to somewhere? That starWind VSAN VM needs to be up.
Once the 2nd host is there, please log a call with us using this thread as the reference > we will arm the trial key > do the job > roll back to free (one time exclusion I am happy to make :) )
tanjum
Posts: 34
Joined: Mon Jul 21, 2025 12:02 pm

Fri Aug 01, 2025 7:59 am

yaroslav (staff) wrote:
Thu Jul 31, 2025 6:06 pm
I guess there is some misunderstanding here.
You are replicating the device to somewhere? That starWind VSAN VM needs to be up.
Once the 2nd host is there, please log a call with us using this thread as the reference > we will arm the trial key > do the job > roll back to free (one time exclusion I am happy to make :) )
Appreciate that yaroslav,

I had asked for a quote for the license and had a word with my manager, as anticipated he said the quote was high.

I'm also thinking to get started with the free license once I have both servers so its easier to setup as that has been tested.

Thanks again yaroslav, very much appreciate all the help I got from you on this..
yaroslav (staff)
Staff
Posts: 4309
Joined: Mon Nov 18, 2019 11:11 am

Fri Aug 01, 2025 8:28 am

Tanjum,

Thanks for your time and effort!
yaroslav (staff)
Staff
Posts: 4309
Joined: Mon Nov 18, 2019 11:11 am

Sun Aug 03, 2025 4:56 am

Hi,

I came up with a workaround :)
-create 1 GB HA device
-remove its partner
-clean up the counterpart headers
-run AddHA script.
If the test is successful, remove the HA partner again and expand the HA device.

This should give you a so-called "standalone HA", the device that allows for easy restoration HA partner elsewhere in the future, supposedly without downtime.
tanjum
Posts: 34
Joined: Mon Jul 21, 2025 12:02 pm

Tue Aug 05, 2025 8:10 am

yaroslav (staff) wrote:
Sun Aug 03, 2025 4:56 am
Hi,

I came up with a workaround :)
-create 1 GB HA device
-remove its partner
-clean up the counterpart headers
-run AddHA script.
If the test is successful, remove the HA partner again and expand the HA device.

This should give you a so-called "standalone HA", the device that allows for easy restoration HA partner elsewhere in the future, supposedly without downtime.
Thanks yaroslav..

I'll test this and see how this goes..
yaroslav (staff)
Staff
Posts: 4309
Joined: Mon Nov 18, 2019 11:11 am

Tue Aug 05, 2025 8:43 am

Hi,

Thanks for your cooperation. Let us stay in touch.
Post Reply