Is it possible to install startwind VSAN without HA?

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

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

Post Reply
kktwenty
Posts: 17
Joined: Fri Mar 20, 2020 8:33 am

Thu Jun 30, 2022 10:34 am

I know this sounds like a very strange request but can you create a non HA vsan? I.e. on server with local storage, create a starwind iscsi presented volume (that will only be used on that server)? No heartbeat, lose the server or storage and lose the starwind volume etc. I have looked through the powershell scripts but couldnt see a way of creating a 1 node no HA. I can see the "Add-HADevice" command but obviously this needs details of a second node. Would this be what the "createimagefile.ps1" is for? i.e. would this create a single node non HA iscsi target

Code: Select all

aram($addr="127.0.0.1", $port=3261, $user="root", $password="starwind",
	$fileName="VD01",
	$filePath="My Computer\f\Starwind_VD01",
	$size=5000000,
	$targetAlias="VD015T",
	$sectorSize=4096,
	$numaNode=0,
	$cacheMode="wb",
	$cacheSize=128)

Import-Module StarWindX

try
{
	Enable-SWXLog

	if($sectorSize -eq 4096 -and $size -lt 2)
	{
		throw "Minimal device size 2MB"
	}

	$server = New-SWServer -host $addr -port $port -user $user -password $password

	$server.Connect()

	#create image file
	New-ImageFile -server $server -path $filePath -fileName $fileName -size $size
    
	#create device
	$device = Add-ImageDevice -server $server -path $filePath -fileName $fileName -sectorSize $sectorSize -NumaNode $numaNode -CacheMode $cacheMode -CacheSize $cacheSize

	$device
    
	#create target
	$target = New-Target -server $server -alias $targetAlias -devices $device.Name

	$target
}
catch
{
	Write-Host $_ -foreground red
}
finally
{
	$server.Disconnect()
}
I have seen that there is a starwind vsan and nas but I was under the impression that this was a VM rather than a more lightweight application that can run on an existing server.
yaroslav (staff)
Staff
Posts: 2361
Joined: Mon Nov 18, 2019 11:11 am

Thu Jun 30, 2022 12:48 pm

Welcome to StarWind Forum. Yes, you can create a non-replicated (i.e., standalone) .img file. Try CreateImageFile.ps1.
NOTE: Please make sure to disable caching for that device.
kktwenty
Posts: 17
Joined: Fri Mar 20, 2020 8:33 am

Thu Jun 30, 2022 1:41 pm

perfect. thank you.
yaroslav (staff)
Staff
Posts: 2361
Joined: Mon Nov 18, 2019 11:11 am

Thu Jun 30, 2022 2:40 pm

You are welcome. Let me know if more assistance is needed.
Post Reply