Jump to content
Updated Privacy Statement
  • 0

Removing Custom Property: Allow Standard_SSD_LRS to be used for Storage Type At Shutdown on Azure


Nitin lal1709163109

Question

Hi,

 

Please guide me, once this feature is implemented on Catalog, how this feature (on shutdown, storage Tier changes to lower SKU) can be removed?

<Property xsi:type="StringProperty" Name="StorageTypeAtShutdown" Value="Standard_LRS" />

 

Also, I am noticing that if we enable this Custom property, the machine power On time to registering in Citrix DaaS & launching ICA session taking more than 4 mins. VMs without this feature enabled taking not more than 2mins 30 seconds to launch.

 

Regards

SG

Link to comment

3 answers to this question

Recommended Posts

  • 0

I feel we are experiencing the same too!..

 

with regards to "removal" of the option, as we too were unable to delete.:

<Property xsi:type="StringProperty" Name="StorageTypeAtShutdown" Value="" />

*note the empty string "".

 

another note, we found on Microsoft learn documentation, they are only supporting two changes of disk type per day (I wonder how this affects this feature from a Citrix point of view?)

could this explain the delays in startup?

 

ChrisP

 

Link to comment
  • 0
On 9/12/2023 at 5:48 PM, chris perry1709160257 said:

I feel we are experiencing the same too!..

 

with regards to "removal" of the option, as we too were unable to delete.:

<Property xsi:type="StringProperty" Name="StorageTypeAtShutdown" Value="" />

*note the empty string "".

 

another note, we found on Microsoft learn documentation, they are only supporting two changes of disk type per day (I wonder how this affects this feature from a Citrix point of view?)

could this explain the delays in startup?

 

ChrisP

 

Yes same issue and slowing down the VDIs to power on in combination with Autoscale 

 

Once enabled this Custom property, the machine power On time /registering in Citrix DaaS & launching session taking more than 5 mins.

On other side we have Autoscale enabled to shutdown unused VDI's at 12. If user try to connect after 12 powering on is taking time an losing registration and the VDI powering off. We found on Microsoft learn documentation, they are only supporting two changes of disk type per day.

With Autoscale enabled first change is at 7am when VDI is started, 2nd one at 12pm if not used.

Problem will come if user try to connect after 12 (that would be 3rd change)  , either converting from Standard HDD to Premium is not happening or taking so long time to be changed

 

Non working either with adding Premium_LRS nor with empty string if executed against ProvisioningSchemeName

$customProperties = '<CustomProperties xmlns=http://schemas.citrix.com/2014/xd/machinecreation xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance>

<Property xsi:type="StringProperty" Name="StorageTypeAtShutdown" Value="Premium_LRS" />

</CustomProperties>'

 

Set-ProvScheme -ProvisioningSchemeName "Win11" -CustomProperties $customProperties

Set-ProvScheme : The operation returned an unexpected result code Citrix.XDPowerShell.MachineCreationStatus.ValidateSetProvisioningSchemeFailed : Error: Invalid storage type for StorageTypeAtShutdown.

At line:1 char:1

 

Working if executed against  ProvisioningSchemeUid <uid>

The only way to work is to get ProvisioningSchemeUid <uid>

Get-Provscheme -ProvisioningSchemeName "Win11"

 

note the  ProvisioningSchemeUid <uid>

ProvisioningSchemeName       : Win11

ProvisioningSchemeType       : MCS

ProvisioningSchemeUid        : b7f820a8-b105-45b6-a0be-22b86cc56b44

 

and set with empty string against 

Set-ProvScheme -ProvisioningSchemeUid <uid> -CustomProperties "<CustomProperties xmlns=`"http://schemas.citrix.com/2014/xd/machinecreation`" xmlns:xsi=`"http://www.w3.org/2001/XMLSchema-instance`"><Property xsi:type=`"StringProperty`" Name=`"StorageTypeAtShutdown`" Value=`"`"/></CustomProperties>"
Additionally, to disable on existing machines, you'd need to run:
Set-ProvVMUpdateTimeWindow -StartsNow -ProvisioningSchemeUid <uid>

 

example 

Set-ProvScheme -ProvisioningSchemeUid b7f820a8-b105-45b6-a0be-22b86cc56b44 -CustomProperties "<CustomProperties xmlns=`http://schemas.citrix.com/2014/xd/machinecreation` xmlns:xsi=`http://www.w3.org/2001/XMLSchema-instance`><Property xsi:type=`"StringProperty`" Name=`"StorageTypeAtShutdown`" Value=`"`"/></CustomProperties>"
Set-ProvVMUpdateTimeWindow -StartsNow -ProvisioningSchemeUid b7f820a8-b105-45b6-a0be-22b86cc56b44

Please note that post executing the commands all affected VDI's must be rebooted in timeframe of 2 hours 

Update.thumb.png.00dd77296a3938dec56d2600d48b087d.png

https://developer-docs.citrix.com/en-us/citrix-daas-sdk/MachineCreation/Set-ProvVMUpdateTimeWindow.html This cmdlet defines a time window where a property update will take place against either specific machines in a catalog or an entire catalog. The update will take place when the machine is next booted within the time window. Note that running this command does not make the machine automatically reboot or turn on sometime within the time window to apply the update. The power action to initiate the update must either be performed as a part of an autoscale schedule or manually through Studio or the New-BrokerHostingPowerAction cmdlet within the time window. If the time window passes before the machine is booted successfully, the update will not apply and will have to be set again with this cmdlet.

On each VM an update window is set, ProvisioningSchemeUpdateRequested defines the start of the time window and ProvisioningSchemeUpdateUntil defines the end of the time window.

After the update, ProvisioningSchemeVersion on the VM will be updated to match the current version of the ProvScheme, and the ProvVMConfigurationVersion will match the latest configuration on the VM.


Post that checking CustomProperties for 1catalog in example Get-Provscheme -ProvisioningSchemeName "Win11"

or to check on all Catalogs Get-ProvScheme | select ProvisioningSchemeName, CustomProperties | ogv
 

 

CustomProperties             : <CustomProperties xmlns=http://schemas.citrix.com/2014/xd/machinecreation xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance>

                                 <Property xsi:type="StringProperty" Name="StorageTypeAtShutdown" Value="" />

                                 <Property xsi:type="StringProperty" Name="SchemaVersion" Value="2" />

                                 <Property xsi:type="StringProperty" Name="UseManagedDisks" Value="true" />

                                 <Property xsi:type="StringProperty" Name="OsType" Value="Windows" />

                                 <Property xsi:type="StringProperty" Name="StorageType" Value="Premium_LRS" />

                                 <Property xsi:type="StringProperty" Name="LicenseType" Value="Windows_Client" />

                                 <Property xsi:type="StringProperty" Name="Zones" Value="" />

                                 <Property xsi:type="StringProperty" Name="ResourceGroups" Value="xxxxxxx1" />

                               </CustomProperties>

 

 

Tested with powering off the VDI's and storage type was not changed on shutdown 

Link to comment
  • 0
On 2/21/2024 at 12:21 PM, Kostadin Dimitriev1709162070 said:

Yes same issue and slowing down the VDIs to power on in combination with Autoscale 

 

Once enabled this Custom property, the machine power On time /registering in Citrix DaaS & launching session taking more than 5 mins.

On other side we have Autoscale enabled to shutdown unused VDI's at 12. If user try to connect after 12 powering on is taking time an losing registration and the VDI powering off. We found on Microsoft learn documentation, they are only supporting two changes of disk type per day.

With Autoscale enabled first change is at 7am when VDI is started, 2nd one at 12pm if not used.

Problem will come if user try to connect after 12 (that would be 3rd change)  , either converting from Standard HDD to Premium is not happening or taking so long time to be changed

 

Non working either with adding Premium_LRS nor with empty string if executed against ProvisioningSchemeName

$customProperties = '<CustomProperties xmlns=http://schemas.citrix.com/2014/xd/machinecreation xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance>

<Property xsi:type="StringProperty" Name="StorageTypeAtShutdown" Value="Premium_LRS" />

</CustomProperties>'

 

Set-ProvScheme -ProvisioningSchemeName "Win11" -CustomProperties $customProperties

Set-ProvScheme : The operation returned an unexpected result code Citrix.XDPowerShell.MachineCreationStatus.ValidateSetProvisioningSchemeFailed : Error: Invalid storage type for StorageTypeAtShutdown.

At line:1 char:1

 

Working if executed against  ProvisioningSchemeUid <uid>

The only way to work is to get ProvisioningSchemeUid <uid>

Get-Provscheme -ProvisioningSchemeName "Win11"

 

note the  ProvisioningSchemeUid <uid>

ProvisioningSchemeName       : Win11

ProvisioningSchemeType       : MCS

ProvisioningSchemeUid        : b7f820a8-b105-45b6-a0be-22b86cc56b44

 

and set with empty string against 

Set-ProvScheme -ProvisioningSchemeUid <uid> -CustomProperties "<CustomProperties xmlns=`"http://schemas.citrix.com/2014/xd/machinecreation`" xmlns:xsi=`"http://www.w3.org/2001/XMLSchema-instance`"><Property xsi:type=`"StringProperty`" Name=`"StorageTypeAtShutdown`" Value=`"`"/></CustomProperties>"
Additionally, to disable on existing machines, you'd need to run:
Set-ProvVMUpdateTimeWindow -StartsNow -ProvisioningSchemeUid <uid>

 

example 

Set-ProvScheme -ProvisioningSchemeUid b7f820a8-b105-45b6-a0be-22b86cc56b44 -CustomProperties "<CustomProperties xmlns=`http://schemas.citrix.com/2014/xd/machinecreation` xmlns:xsi=`http://www.w3.org/2001/XMLSchema-instance`><Property xsi:type=`"StringProperty`" Name=`"StorageTypeAtShutdown`" Value=`"`"/></CustomProperties>"
Set-ProvVMUpdateTimeWindow -StartsNow -ProvisioningSchemeUid b7f820a8-b105-45b6-a0be-22b86cc56b44

Please note that post executing the commands all affected VDI's must be rebooted in timeframe of 2 hours 

Update.thumb.png.00dd77296a3938dec56d2600d48b087d.png

https://developer-docs.citrix.com/en-us/citrix-daas-sdk/MachineCreation/Set-ProvVMUpdateTimeWindow.html This cmdlet defines a time window where a property update will take place against either specific machines in a catalog or an entire catalog. The update will take place when the machine is next booted within the time window. Note that running this command does not make the machine automatically reboot or turn on sometime within the time window to apply the update. The power action to initiate the update must either be performed as a part of an autoscale schedule or manually through Studio or the New-BrokerHostingPowerAction cmdlet within the time window. If the time window passes before the machine is booted successfully, the update will not apply and will have to be set again with this cmdlet.

On each VM an update window is set, ProvisioningSchemeUpdateRequested defines the start of the time window and ProvisioningSchemeUpdateUntil defines the end of the time window.

After the update, ProvisioningSchemeVersion on the VM will be updated to match the current version of the ProvScheme, and the ProvVMConfigurationVersion will match the latest configuration on the VM.


Post that checking CustomProperties for 1catalog in example Get-Provscheme -ProvisioningSchemeName "Win11"

or to check on all Catalogs Get-ProvScheme | select ProvisioningSchemeName, CustomProperties | ogv
 

 

CustomProperties             : <CustomProperties xmlns=http://schemas.citrix.com/2014/xd/machinecreation xmlns:xsi=http://www.w3.org/2001/XMLSchema-instance>

                                 <Property xsi:type="StringProperty" Name="StorageTypeAtShutdown" Value="" />

                                 <Property xsi:type="StringProperty" Name="SchemaVersion" Value="2" />

                                 <Property xsi:type="StringProperty" Name="UseManagedDisks" Value="true" />

                                 <Property xsi:type="StringProperty" Name="OsType" Value="Windows" />

                                 <Property xsi:type="StringProperty" Name="StorageType" Value="Premium_LRS" />

                                 <Property xsi:type="StringProperty" Name="LicenseType" Value="Windows_Client" />

                                 <Property xsi:type="StringProperty" Name="Zones" Value="" />

                                 <Property xsi:type="StringProperty" Name="ResourceGroups" Value="xxxxxxx1" />

                               </CustomProperties>

 

 

Tested with powering off the VDI's and storage type was not changed on shutdown 

With latest Cloud updates there is option to remove custom property by unchecking the box "enable storage cost saving". Unfortunately Changes you make will apply only to machines you add to the catalog later. Existing machines remain unchanged. Therefore for existing one still need to stick to PowerShell above 

Disk.png

Link to comment

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...