Module 13 Exercises: Mastering the Clouds

Module 13 Exercises: Mastering the Clouds

Take the flight. Practice designing cloud-native architectures, comparing managed services, and implementing disaster recovery.

Module 13 Exercises: Mastering the Clouds

In Module 13, we explored how Kubernetes behaves in the "Real World" of Amazon, Google, and Microsoft. These exercises will help you think like a Cloud Architect, making the right trade-offs between cost, performance, and reliability.


Exercise 1: The EKS IP Audit

  1. Scenario: You are deploying a large AI agent on AWS EKS using the VPC CNI.
    • Your subnet has 200 free IP addresses.
    • You want to run 5 nodes, and each node can hold 40 pods.
  2. Calculation: How many IP addresses will your pods consume in total?
  3. The Problem: If you suddenly need to scale to 10 nodes, what will happen to your cluster?
  4. Solution: Name two ways (from Lesson 1) to solve the IP exhaustion problem in EKS.

Exercise 2: GKE Price Comparison

  1. Scenario: You have an AI model that needs 8 vCPUs and 32GB of RAM. It runs for exactly 1 hour a day to process a batch.
  2. Standard Mode: You have a pre-provisioned node group with an e2-standard-8 instance ($0.26/hour). You pay for the whole hour even if the pod takes 10 minutes.
  3. Autopilot Mode: GKE Autopilot charges $0.0445 per vCPU/hour and $0.0049 per GB/hour.
  4. Task: Calculate the cost of running your 1-hour job on both.
  5. Thinking Task: If your workload is "Spiky" and unpredictable, which mode is safer for your cloud budget?

Exercise 3: Azure Arc Visualization

  1. Scenario: Your company has an on-premises data center with a physical Kubernetes cluster and an EKS cluster in AWS.
  2. Task: Design an Azure Arc architecture in text.
    • Where does the "Azure Arc Agent" get installed?
    • If you apply an "Azure Policy" to block root users, which clusters are affected?
  3. Benefit: What is the "Single Pane of Glass" advantage of this setup?

Exercise 4: The Velero Rescue

  1. Preparation: Your ai-production namespace contains 50 Secrets and 10 Persistent Volumes (PVs).
  2. The Command: Write the velero command to back up ONLY the ai-production namespace and name it pre-migration-backup.
  3. The Drill: You want to restore this into a different cluster. Write the restore command.
  4. Analysis: If the new cluster has different storage (e.g. gp3 on AWS vs standard on GCP), how does Velero handle the conversion? (Hint: See Lesson 5).

Solutions (Self-Check)

Exercise 1 Answer:

  • Calculation: 5 nodes * 40 pods = 200 IPs. You have exactly zero IPs left for your nodes to communicate or for other AWS services.
  • Solution:
    1. Use Custom Networking (mapping pods to a larger subnet).
    2. Use Prefix Delegation (assigning multiple IPs to each Network Interface).

Exercise 2 Solution:

  • Standard: $0.26 per day.
  • Autopilot: (8 * 0.0445) + (32 * 0.0049) = $0.356 + $0.1568 = $0.512.
  • Insight: Standard is cheaper for a constant load, but Autopilot is cheaper if the pod only runs for a few minutes because you don't pay for the "Idle" time of the VM.

Exercise 3 Hint:

The agent gets installed on both the on-prem and the EKS cluster. The Azure Policy affects all connected clusters. The advantage is that you manage security from one single dashboard.

Exercise 4 Logic:

  • Backup: velero backup create pre-migration-backup --include-namespaces ai-production.
  • Restore: velero restore create --from-backup pre-migration-backup.
  • Conversion: You use StorageClass Mapping or a ConfigMap to tell Velero: "When you see storage type A, replace it with storage type B."

Summary of Module 13

Congratulations! You have crossed the "Cloud Divide."

  • You mastered EKS, GKE, and AKS.
  • You know how to manage global, hybrid fleets with Anthos and Arc.
  • You have built a reliable disaster recovery plan with Velero.

In Module 14: Real-World Projects, you will take the "Ultimate Test." You will put all these skills together to build a complete, production-grade AI platform.

Subscribe to our newsletter

Get the latest posts delivered right to your inbox.

Subscribe on LinkedIn