Manage Virtual Node Groups (AKS)
Cloud service provider relevance: AKS
Virtual Node Groups (VNGs) provide a single layer of abstraction that enables you to manage different types of workloads on the same cluster. This topic describes how to create, view, edit, and delete virtual node groups in Ocean. See also Default Virtual Node Group.
Before starting, make sure you have an up-and-running Ocean cluster.
Access the Virtual Node Group Tab
- Click Ocean > Cloud Clusters in the left main menu.
- Select a cluster from the list of clusters.
- Click the Virtual Node Groups tab to display the virtual node groups list.
Click for image
This list lets you track live data per virtual node group and contains the following information:
- ID: The identification code of the virtual node group.
- Name: The user-defined name of the virtual node group. (If a virtual node group was defined without a name, it would appear as Unnamed).
- Resource Allocation: Percent of defined CPU, Memory, and GPU currently used by the virtual node group.
- Running Pods: Number of pods used by the virtual node group.
- Max Nodes: Maximum number of nodes defined for the virtual node group.
- Node Count: Number of nodes used by the virtual node group.
- Node Labels: Number of node labels the virtual node group uses.
- Node Taints: Number of taints used by the virtual node group.
- Tags: Number of tags used by the virtual node group.
Create/Edit a virtual node group
To create/edit a virtual node group:
-
In the Virtual Node Groups tab, click Create VNG above the list on the right of the screen (or to edit an existing virtual node group, click the link on the virtual node group's name in the list).
-
If you are creating a virtual node group, select one of these options.
- Configure Manually: All virtual node group fields will be taken from the virtual node group Template.
- Import configurations from Node Pools: Values are copied from the cloud service provider node group entity to the Ocean configuration. Later, there will be no active connection between these two entities. Ocean will provision new VMs, not as part of a managed Kubernetes service of node group entities.
-
Click Continue.
-
Edit the parameters in the New virtual node group screen. Parameters left blank take values from the virtual node group template.
Click for image
General Parameters
- Name: The name you assign to the new virtual node group.
- Availability Zones.
Node Pool Properties
- OS Type and OS SKU.
- OS Disk Type.
- OS Disk Size (up to 2048 GiB). Minimum requirement. Ocean selects a node with at least this size.
- Maximum # pods per node. (from 10 to 250).
- Node Public IP.
- Kubernetes Version.
Ocean Autoscaler Strategy
- Minimum and maximum nodes for autoscaling.
- Spot %: Percentage of spot nodes you want in the virtual node group.
- Fallback to Regular: Turn on to allow Ocean to launch regular (on-demand) nodes when spot markets are unavailable.
- Scaling orientation: While Ocean is designed to optimize your environment for both availability and cost, you can control and manage optimization priorities by configuring the scaling orientation at the virtual node group level.
- Cost (Default): Prioritizes cost savings by selecting the cheapest VM types across all availability zones, which may lead to frequent VM replacements.
- Availability: This approach maximizes VM longevity and distribution across availability zones, ensuring reliability but potentially reducing overall cost savings.
You may have configured virtual node groups with either Spot % to 100 or turned off Fallback to Regular but still have regular nodes running on them. This occurs for regular nodes from the kube-system namespaces. kube-system pods are mission-critical AKS pods that allow the cluster to function correctly.
VM Selection
Here, you can select VM sizes in your cluster per virtual node group (custom or template) that fit your application needs. An advanced attributes filter lets you search for the optimal VMs for the task from any of the VM families available on the Azure cloud. Once you have sized your VMs, Ocean uses your customization for its scaling processes.
To select the VMs for your Cluster:
-
Scroll down to the VM Selection panel, which provides these options:
- Automatic: Let Spot select your VM sizes according to the needs of your applications.
- Advanced VM Size Selection: Use attribute filters to select VMs with customized sizes from which Ocean can scale.
-
If you selected Automatic, click Save to complete the procedure.
-
If you selected Advanced VM Size Selection: View each VM type's currently selected size, vCPU, Memory (GiB), and GPU units in the VM Selection list (click the down arrow for the VM type).
note- The VM types shown in the virtual node group template are only those supported in the cluster's region.
- Click Restore to template values (to the right and above the VM types list) to restore the VM types to the virtual node group template values.
The Advanced VM Size Filtering controls to the right of the VM Selection list let you filter these attributes for the VMs:
- Upper and lower limits for number of vCPUs (up to 256).
- Upper and lower limits for the memory (up to 1024 GiB).
- Upper and lower limits for the number of GPUs (up to 8).
- GPU type.
- Exclude Series: You can exclude any series by clicking Exclude in the VM Selection List row for that series or by typing in the Exclude Series field. The series then appears in the Exclude Series filter under the filtering controls.
- Include Series: You can include VMs in the Include Series field. For example, to select a GPU type, include the series and VM types.
- VM Types.
- Architectures (values taken from your virtual node group template).
- Disk performance (standard or premium).
- Minimum number of data disks (up to 64).
- Minimum number of NICs (up to 16).
- Turn Accelerated networking on or off.
-
Click Apply to apply the filters. A color-coded bar appears above the list to provide a rating for the applied filter.
noteAn error is displayed if you define an incorrect VM type.
-
Repeat the previous steps until you are satisfied with the results.
-
Save the changes for the virtual node group.
Node Labels and Taints
Configure the Node Selection parameters. When the nodes' labels and taints are set, Ocean uses them to select the right virtual node group for a pending pod.
- Node Labels: Key/Value pairs defined on the Kubernetes nodes.
- Node Taints: Triplets of Key, Value, and Effect defined on the Kubernetes nodes.
Advanced Properties
- Tags: Key-value pairs that apply metadata tags to VMs. You can assign specific tags to organize and manage virtual node groups.
- Headroom: Maintains pre-allocated spare capacity to enable immediate pod placement without waiting for new resources to launch.
- Reserve: Number of headroom units to maintain, each with dedicated CPU and memory allocation.
- CPU (millicpu): CPU allocation per headroom unit in millicpu (1000 millicpu = 1 vCPU).
- Memory (MiB): Memory allocation per headroom unit in mebibytes.
- GPUs: Number of GPUs to allocate per headroom unit.
Example: GPU Instance
To enable Ocean to provision GPU nodes for pods that require them, add the appropriate GPU image to a virtual node group. No specific labels are needed for this configuration.
resources:
limits:
nvidia.com/gpu: 1
You can use node selectors or node affinity to direct GPU-based pods to the appropriate virtual node group. Configure custom node labels on the GPU virtual node group to enable this pod-to-VNG targeting.
Editing a Virtual Node Group in JSON View
In the console, you can optionally review and edit the VNG configuration in JSON format. This provides more flexibility and lets you use VNG features that are supported in the Spot API without leaving the Ocean console. (These are often new features available in the Spot API but are not yet available in the console).
-
Click the Virtual Node Groups tab.
-
Click the link on the name of the virtual node group in the list.
-
Click JSON on the upper right.
{
"name": "vngname",
"oceanId": "o-66963661",
"availabilityZones": [
"1"
],
"nodePoolProperties": {
"kubernetesVersion": null,
"maxPodsPerNode": 110,
"enableNodePublicIP": false,
"osDiskSizeGB": 128,
"osDiskType": "Ephemeral",
"osType": "Linux",
"osSKU": "Ubuntu"
},
"nodeCountLimits": {
"minCount": 0,
"maxCount": 1000
},
"strategy": {
"spotPercentage": 100,
"fallbackToOd": true
},
"autoScale": {
"headrooms": []
},
"labels": {},
"taints": [],
"tags": {},
"vmSizes": {
"filters": {
"architectures": [
"X86_64"
]
}
}
} -
Edit the JSON and save your changes.
You can switch between Form (console) and JSON views multiple times, make changes separately in each view, and then click Save All.
Delete a VNG
In the virtual node groups list, check the groups you want to delete and click Delete.
If you are already configuring a virtual node group, click Delete VNG at the bottom of the screen.