You have an Azure Kubernetes Service (AKS) cluster named AKS1. You need to configure cluster autoscaler for AKS1. Which two tools should you use? Each correct answer presents a complete solution. NOTE: Each correct selection is worth one point.
Suggested Answer:AB🗳️
A: The following example uses the kubectl autoscale command to autoscale the number of pods in the azure-vote-front deployment. If average CPU utilization across all pods exceeds 50% of their requested usage, the autoscaler increases the pods up to a maximum of 10 instances. A minimum of 3 instances is then defined for the deployment: kubectl autoscale deployment azure-vote-front --cpu-percent=50 --min=3 --max=10 B: Use the az aks update command to enable and configure the cluster autoscaler on the node pool for the existing cluster. Reference: https://docs.microsoft.com/en-us/azure/aks/tutorial-kubernetes-scale https://docs.microsoft.com/en-us/azure/aks/cluster-autoscaler
The Answer is not correct. The right is B & D.
B is for az aks command , check https://docs.microsoft.com/en-us/azure/aks/cluster-autoscaler
D is for Azure portal. Under node pools, press scale, then choose auto scale.
The Answer A is not correct as it is confusing with Horizontal pod autoscale which is not asked here. The pod autoscale use kubectl.
The article does a good job explaining the difference of "cluster autoscaler" and "horizontal pod autoscaler"...
https://docs.microsoft.com/en-us/azure/aks/cluster-autoscaler
FYI also - the PowerShell command that can do this same task is "Set-AzAksCluster" (not Set-AzAks). B and D it is!
There are 2 things to understand:
a) Are we talking about pods?
b) Are we talking about nodes?
The question is regarding how to autoscale the AKS, so it means that we are talking about the nodes. As we are talking how to scale the nodes:
a) az aks is neccesary
b) Then you scale the nodes in the portal.
The correct answers are B & D.
If we want to scale the pods, the options would be kubelet, but it is not the case. We are not talking about the containers, we are talking about the infrastructure behind this.
To corroborate with your answer, kubectl autoscale "creates an autoscaler that automatically chooses and sets the number of pods that run in a kubernetes cluster":
https://kubernetes.io/docs/reference/generated/kubectl/kubectl-commands#autoscale
According to Microsoft, this is a Horizontal pod autoscale, not a Cluster autoscale:
https://docs.microsoft.com/en-us/azure/aks/cluster-autoscaler#about-the-cluster-autoscaler
But we are not talking about the pods, we are talinkg about the nodes, so is B and D. Think that this service is managed by Azure, and they will not allow to do this by yourself, and this is the reason why you must choose the portal.
Correct Answer: B and D
We need to configure autoscaler for the AKS cluster. We do not want to scale Kubernetes pods, so kubectl command is not needed.
A: kubectl command is used for configuring Kubernetes and not AKS cluster.
B: The az aks command is used for the AKS cluster configuration.
C: Set-AzVm cmdlet is used for VMs.
D: Azure portal, under node pools, press scale, then choose auto scale.
E: Set-AzAks, creates or updates an AKS cluster, the correct cmdlet is Set-AzAksCluster.
AKS clusters can scale in one of two ways:
- The cluster autoscaler watches for pods that can't be scheduled on nodes because of resource constraints. The cluster then automatically increases the number of nodes.
- The horizontal pod autoscaler uses the Metrics Server in a Kubernetes cluster to monitor the resource demand of pods. If an application needs more resources, the number of pods is automatically increased to meet the demand.
Reference:
https://docs.microsoft.com/en-us/azure/aks/cluster-autoscaler
I agreed already but then you pointed out the two ways:
- The cluster autoscaler
- The horizontal pod autoscaler
The 2nd uses kubectl so the answer is A and B.
ChatGPT response:
The two tools you should use to configure cluster autoscaler for AKS1 are:
B. the az aks command, which provides a command-line interface for managing AKS clusters, including the ability to enable and configure cluster autoscaler.
E. the Set-AzAks cmdlet, which is a PowerShell cmdlet for managing AKS clusters. It can be used to enable and configure cluster autoscaler.
Therefore, options B and E are correct. Options A, C, and D are not required for this task.
"follow up question"
Will the answer be the same if I need to configure autoscaler for the AKS cluster. I do not want to scale Kubernetes pods
Yes, the answer would still be the same.
Configuring cluster autoscaler for an AKS cluster is independent of scaling Kubernetes pods. The purpose of cluster autoscaler is to automatically adjust the size of the AKS cluster based on the resource demands of the workloads running on it, while scaling Kubernetes pods involves adjusting the number of replicas for a specific deployment or replica set.
Therefore, to configure cluster autoscaler for an AKS cluster, you would still need to use the az aks command and the Set-AzAks cmdlet.
We need to configure autoscaler for the AKS cluster. We do not want to scale Kubernetes pods, so kubectl command is not needed.
Use Portal under Node Pools
If you need to create an AKS cluster, use the az aks create command.
link :If you need to create an AKS cluster, use the az aks create command.
Deploy an AKS cluster using the Azure portal.
Run a sample multi-container application with a web front-end and a Redis instance in the cluster.
linkhttps://learn.microsoft.com/en-us/azure/aks/learn/quick-kubernetes-deploy-portal?tabs=azure-cli
I have prepared myself from Microsoft partners SPEKTRA SYSTEMS and there I found this same question which was as below:
You have an Azure Kubernetes Service Cluster named AKS1. For configuring an Autoscaler in AKS1 what are the COMMANDS you need to execute?
So with only one word has changed which is commands and solution would also be change which is
1) the az aks command
2) Set-AzAks cmdlet
SO, be attentive in the exam. MICROSOFT is clever!
B and D are the right answers to this question. But in the exam, if the question comes with COMMANDS instead of TOOLS?
then answers are:
1) the az aks command
2) Set-AzAks cmdlet
The cluster autoscaler watches for pods that can't be scheduled on nodes because of resource constraints. The cluster then automatically increases the number of nodes. - The horizontal pod autoscaler uses the Metrics Server in a Kubernetes cluster to monitor the resource demand of pods. If an application needs more resources, the number of pods is automatically increased to meet the demand.
The 2nd way uses kubectl.
A voting comment increases the vote count for the chosen answer by one.
Upvoting a comment with a selected answer will also increase the vote count towards that answer by one.
So if you see a comment that you already agree with, you can upvote it instead of posting a new comment.
fedztedz
Highly Voted 2 years, 6 months agodiligent176
2 years, 5 months agojantoniocesargatica
2 years agomythjava
3 months, 1 week agojuniorccs
1 year, 4 months agomarcellov
2 years agojantoniocesargatica
2 years agoHibs2016
2 years, 6 months agomlantonis
Highly Voted 2 years agoklexams
7 months, 1 week agoMozbius_
1 year, 3 months agoJunetGoyal
Most Recent 1 month agozzreflexzz
1 month agoExilic
1 month, 2 weeks agogarmatey
4 days, 18 hours agomythjava
3 months, 1 week agoUmbongoDrink
3 months, 3 weeks agotypales2005
4 months, 3 weeks agoBigc0ck
4 months, 4 weeks agoMoradiya
5 months agotypales2005
5 months agoprem007
5 months, 2 weeks agoanushak
5 months, 3 weeks agoJamal786
6 months, 2 weeks agoJamal786
6 months, 2 weeks agoBYNeo
6 months, 3 weeks agoklexams
7 months, 1 week agosimonseztech
7 months, 3 weeks ago