2
votes

I deployed a Service Fabric Cluster running with a single application and 3 Node Types of 5 machines, each with its own placement constraint.

I need to add other 2 Node types (Virtual Machine Scale sets), how can I do that from the azure portal?

2
I don't think there's an option for that. Can you use ARM templates? Basically replicate the config for VM Scale Sets in the template. You can download the template from the portal.Mikkel Mørk Hegnhøj
You can't add node types to an existing cluster through the portal. You can use the Add-​Azure​Rm​Service​Fabric​Node​Type PowerShell cmdlet to add new node types however.Ryan Wike

2 Answers

4
votes

The Add-AzureRmServiceFabricNodeType command can add a new node type to an existing Service Fabric cluster.

Note that the process can take roughly an hour to complete, since it creates one resource at a time starting with the cluster. It will create a new load balancer, public IP address, storage accounts, and virtual machine scale set.

$password = ConvertTo-SecureString -String 'Password$123456' -AsPlainText -Force

Add-AzureRmServiceFabricNodeType `
    -ResourceGroupName "resource-group" `
    -Name "cluster-name" `
    -NodeType "nodetype2" `
    -Capacity 2 `
    -VmUserName "user" `
    -VmPassword $password

Things to consider:

  • Check your quotas beforehand to ensure you can create the new virtual machine scale set instances or you will get an error and the whole process will roll back
  • Node type names have a limit of nine characters when creating a cluster via portal blade; this same restriction may apply using the PowerShell command
  • The command was introduced as part of v4.2.0 of the AzureRM PowerShell module, so you may need to update your module

You can also add a new node type by creating a new cluster using the Azure portal wizard and updating your DNS records, or by modifying the ARM template, but the PowerShell command is obviously the best option.

0
votes

Another option is to use New-AzureRmResourceGroupDeployment with an updated ARM template that includes all the resources for your new node types, as well as the new node types.

What's nice about using the PS command is that it takes care of any manual work that you may need to do for creating and associating resources to the new node types.