KK engineer Azure Level 4 Task 1 VM Setup and Configuration for Azure API Gateway

Hi!

I have problem with validation of task 1 on Azure level 4 VM Setup and Configuration for Azure API Gateway.

When I validate the task, I receive the following error message:
“Round-robin behavior is not working as expected.”

However, when I test the Application Gateway either through a web browser or using the curl command, the load balancing works correctly across both VMs.

I have attached the JSON export of the Application Gateway configuration.
AZ4-1.pdf (126.9 KB)

Could you please confirm if the issue is related to the Application Gateway configuration or if this is a platform-level problem?

The first issue above is more important to solve.


The secound issue I encountered is that I cannot create an Application Gateway through the CLI. It returns an error stating that the SKU is not valid. I tried with the following SKUs:

  • Standard_Medium
  • Standard_Small
  • Standard_v2
  • WAF_Large
  • WAF_Medium
  • WAF_v2
  • Basic

Each of these attempts resulted in the same error.

I can create all resources below through CLI:

Virtual network (VNet)

  • Subnets
  • Network Security Groups (NSGs)
  • Virtual Machines (VMs)

All of these resources are created using the Azure CLI.


The first issue is more important to solve.

Kind regards,
Tomislav

Has anyone completed Task 1 in Level 4 of Azure? No matter what I try, I keep getting the error:
“Round-robin behavior is not working as expected.”

My backend settings

Has anyone already completed Task 1 Azure Level4? If so, I would appreciate it if you could share the method or approach you used to complete it.

Hi @tzeko

I’m trying to verify it, but I’m stuck on the VM creation step. What command did you use to create these VMs?

Yes I have completed today only just let me know if you need any assistance.

Can you show the steps how did you completed the task.

Here is mine:

I created networks, NSG, VMs with script:

Variables

#variable V is for naming resources. In my case prefix for resources was datacenter, so Variable V is datacenter
V=“datacenter”
#variable RG is for resource group
RG=$(az group list --query ‘[].name’ --output table | grep ‘kml’)
LOC=“EastUS”
VNET=“${V}-vnet”
SUBNET_VMS=“${V}-subnet”
SUBNET_APGW=“${V}-apgw-subnet”
APGW=“${V}-apgw”
APGW_PIP=“${V}-apgw-ip”
NSG=“${V}-nsg”
VM1=“${V}-vm1”
VM2=“${V}-vm2”
ADMIN=azureuser
PASSWORD=“ChangeMe1234!” # for quick demo only

1) Creating Network

az network vnet create -g $RG -n $VNET -l $LOC --address-prefixes 10.10.0.0/16
–subnet-name $SUBNET_VMS --subnet-prefix 10.10.1.0/24
az network vnet subnet create -g $RG --vnet-name $VNET -n $SUBNET_APGW --address-prefix 10.10.2.0/24

NSG to allow HTTP/SSH (demo)

az network nsg create -g $RG -n $NSG -l $LOC
az network nsg rule create -g $RG --nsg-name $NSG -n Allow-HTTP --priority 100
–access Allow --protocol Tcp --direction Inbound --destination-port-ranges 80
az network nsg rule create -g $RG --nsg-name $NSG -n Allow-SSH --priority 110
–access Allow --protocol Tcp --direction Inbound --destination-port-ranges 22
az network vnet subnet update -g $RG --vnet-name $VNET -n $SUBNET_VMS --network-security-group $NSG

2) VMs + Nginx (cloud-init files)

cat > vm1-cloudinit.yml <<‘EOF’
#cloud-config
package_update: true
packages: [ nginx ]
write_files:

  • path: /var/www/html/index.html
    permissions: ‘0644’
    content: |
    <!doctype html>

    Welcome to KKE Labs:Version 1


    runcmd:
  • systemctl enable nginx
  • systemctl restart nginx
    EOF

cat > vm2-cloudinit.yml <<‘EOF’
#cloud-config
package_update: true
packages: [ nginx ]
write_files:

  • path: /var/www/html/index.html
    permissions: ‘0644’
    content: |
    <!doctype html>

    Welcome to KKE Labs:Version 2


    runcmd:
  • systemctl enable nginx
  • systemctl restart nginx
    EOF

az vm create -g $RG -n $VM1 -l $LOC --image Ubuntu2204 --size Standard_B1s
–admin-username $ADMIN --generate-ssh-keys
–vnet-name $VNET --subnet $SUBNET_VMS --custom-data vm1-cloudinit.yml --public-ip-sku Standard
–storage-sku Standard_LRS

az vm create -g $RG -n $VM2 -l $LOC --image Ubuntu2204 --size Standard_B1s
–admin-username $ADMIN --generate-ssh-keys
–vnet-name $VNET --subnet $SUBNET_VMS --custom-data vm2-cloudinit.yml --public-ip-sku Standard
–storage-sku Standard_LRS

All other resoruces I created on portal because policy doesn’t allow to create AG with basic SKU with script. Steps for AG:

When I validate the task, I receive the following error message:
“Round-robin behavior is not working as expected.”

@sethnaman5 can you check what am I doing wrong.

Hi @raymond.baoly

in my last replay to sethnaman5 I pasted scrypt for creating VMs

We can connect on google meet [email protected]