متقدم
البحث فيالملخصات
طريقة البحث
  • الكلمات تجد عناوين الدروس والنص والكود. صفِّ حسب النوع (أدلة، دورات، برامج، كتب) أو ابقَ في هذا الكتاب.
  • book:rhcsa و ch:8 يضيّقان البحث؛ ‎#code يجد الكلمة داخل أوامر الدروس فقط.
  • "كلمتان" تجد العبارة بالضبط.
  • الكلمات العادية تجد الأسماء والنصوص والأمثلة.
  • ↑ ↓ للتنقل · Enter للفتح · Esc للإغلاق · / للبحث
جرّب:

الدورة 6الاسم في الدورة: AZ 104 - 5 - Deploying and Managing Compute Resources

Deploy and Manage Compute Resources

Course 6 of 7 in the AZ-104 path on Manara. Azure Virtual Machines.

ملاحظة

My result — Tasks in this course: all done (31/31); Module review quizzes: 100% (each module); Path progress: all 197 tasks of the 7 courses done; Mock exams: both passed — 92% and 98% (80% to pass).

Course page: Manara

  • 7 الدروس
  • 1 الأوامر
  • 1 المعامل

هذا الجزء لم يُترجم بعد. أنت ترى النص الإنجليزي.

$ مستخدم عادي# بصلاحية root (أو مع sudo)

6.1

Azure Virtual Machines

Azure Virtual Machines (VMs) are computers that run in the cloud.

  • Azure has VM families for different work.
  • D and B series are general purpose. B series is cheap and burstable.
  • F series has more CPU. E and M series have more memory.
  • L series is fast on disk. N series has GPUs. H series is for big science jobs.
  • Azure has four disk types: Ultra Disk, Premium SSD, Standard SSD, and Standard HDD.
  • An Availability Set spreads VMs over fault domains and update domains.
  • An Availability Zone is a separate data center inside one region.
  • Azure Backup saves data on a schedule. It saves only the changes.
  • A disk snapshot is a quick copy of one disk at one moment.

In more detail

  • Pick the VM size after you check CPU, memory, and disk needs.
  • Create the VM: choose the size, the image, the network, the disks, and the availability option.
  • To resize, open the VM, choose Size, pick the new size, and click Resize.
  • Some resizes need a deallocate step. The VM stops for a short time.
  • Scale up means a bigger VM. Scale out means more VMs.
  • A VM scale set adds or removes VMs by rules, like CPU above 75%.
  • Use a snapshot before a risky change. Use Azure Backup for daily and long-term copies.
  • With two or more VMs, use a set or a zone. One VM has no spare copy.

6.2

Azure App Services

App Service is a managed platform for web apps, APIs, and mobile backends.

  • You do not patch servers. Microsoft runs the platform.
  • It supports .NET, Java, Python, PHP, and Node.js.
  • An App Service Plan sets the region, the pricing tier, and the instance count.
  • The tiers are Basic, Standard, and Premium.
  • A deployment slot is a staging copy of the app.
  • You swap slots to go live with no downtime.
  • Scale up changes the tier. Scale out adds instances.
  • Autoscale adds or removes instances by a rule, like CPU over 70%.
  • Use HTTPS only, a custom domain, and an SSL certificate for safety.

In more detail

  • Create the plan first. Pick a region near your users.
  • Create the app. Pick the runtime stack, then deploy.
  • Deploy from Git, Azure DevOps, or a ZIP file upload.
  • Put the new version in a staging slot. Test it. Then swap the slots.
  • Watch the app with Azure Monitor and Application Insights.
  • Use the Profiler to find slow code. Cache data with Azure Cache for Redis.
  • Close the door: use a private endpoint, or allow only trusted IP ranges.
  • Add sign-in with Azure AD (now called Microsoft Entra ID).

6.3

Azure Container Solutions

Azure has three container services: AKS, ACI, and ACA.

  • AKS is managed Kubernetes, for microservices and large workloads.
  • Azure runs the AKS control plane for you, at no extra cost.
  • Control plane parts: kube-apiserver, etcd, kube-scheduler, and kube-controller-manager.
  • AKS nodes are VMs. Each node runs kubelet and a container runtime.
  • Node pools group nodes for special work, like GPU jobs.
  • ACI runs one container fast. There is no cluster to manage.
  • ACA is a serverless container platform. It runs on AKS, but you do not touch Kubernetes.
  • ACA scales to zero when idle. KEDA does event-driven scaling.
  • Dapr helps microservices talk. Envoy routes traffic.

In more detail

  • Choose AKS when you need many containers and microservices.
  • Turn on the cluster autoscaler for nodes. Use HPA for pods.
  • Watch AKS with Container Insights. Secure it with Entra ID and network policies.
  • Choose ACI for short jobs: a test run, a batch job, or a burst.
  • ACI can take a public IP or join a virtual network.
  • AKS can burst into ACI through virtual nodes.
  • Choose ACA for APIs and event-driven apps. It gives ingress, TLS, and traffic split.
  • Deploy images from Azure Container Registry (ACR) or Docker Hub.

6.4

Automation with ARM Templates

An ARM template is a JSON file. It describes the Azure resources you want.

  • This is Infrastructure as Code (IaC).
  • The template is declarative. You say what you want, not how to build it.
  • Deployments are idempotent. The same template gives the same result.
  • Main sections: parameters, variables, functions, resources, outputs, and definitions.
  • Parameters take input at deploy time. A template can have up to 256.
  • Variables store values and expressions. A template can have up to 256.
  • Resources is the core section. Each resource needs type, apiVersion, name, and location.
  • dependsOn sets the deploy order.
  • Outputs return values after deploy, like a resource ID.

In more detail

  • Write the template once. Reuse it for dev, test, and production with parameters.
  • Validate before you deploy: az deployment group validate.
  • Deploy from the portal, Azure CLI, PowerShell, or a CI/CD pipeline.
  • Linked and nested templates split a big deployment into small parts.
  • A template spec stores a template in Azure, so the team can share it.
  • Use a runbook for repeat jobs, like stopping dev VMs at night.
  • Add a schedule or a webhook to start a runbook.
  • Update Management patches VMs on a schedule.

6.5

Key terms

The words of this course in one table. Learn them before the quiz or exam.

TermMeaning
01Azure Virtual Machines
02Azure App Services
03Azure Container Solutions
04Automation with ARM Templates
ACAA serverless container platform built on AKS.
ACIA service that runs a single container fast.
AKSA managed Kubernetes service.
App Service PlanThe machines and tier that run your web app.
Application InsightsA tool for app errors, latency, and dependencies.
ARM templateA JSON file that describes Azure resources.
Availability SetA group of VMs spread over racks in one data center.
Availability ZoneOne separate data center in the same region.
Azure BackupA managed service that saves and restores data.
Azure Cache for RedisA cache service that speeds up apps.
Azure Container Apps (ACA)A serverless container platform built on AKS.
Azure Container Instances (ACI)A service that runs a single container fast.
Azure Kubernetes Service (AKS)A managed Kubernetes service.
Cluster autoscalerAdds or removes nodes when demand changes.
Container registry (ACR)A private store for container images.
Control planeThe managed part that runs the cluster.
DaprA runtime for service calls, state, and messaging.
dependsOnThe list of resources that must deploy first.
Deployment slotA staging copy of the app that you can swap.
Disk snapshotA point-in-time copy of one disk.
Fault domainA rack with its own power and network.
IdempotentA repeat deploy gives the same end result.
Incremental backupSaves only the changed data.
Infrastructure as CodeDefine resources in files, not by hand.
KEDAAn event-driven autoscaler.
Linked templateA separate template that the main template calls.
NodeA VM that runs containers in AKS.
Node poolA group of nodes with the same size and purpose.
OutputA value that the template returns after deploy.
ParameterAn input value for a template.
Premium SSDA fast disk for databases and heavy work.
Private endpointA private network path to the app, with no public internet.
Recovery Services VaultThe storage container for backup data.
RunbookA script or workflow in Azure Automation.
Runtime stackThe language and version that run your app.
Scale outAdd more app instances.
Scale upMove the app to a bigger plan tier.
Template specA saved and shareable template in Azure.
Update domainA group of VMs that restart together in maintenance.
VariableA stored value or expression inside a template.
Virtual machine scale setA group of same VMs that can autoscale.
Virtual nodesAn AKS feature that bursts work into ACI.

6.6

Check yourself

Answer each question first, then open it to check the answer.

1What is the difference between an Availability Set and an Availability Zone?

A set spreads VMs over racks in one data center. A zone spreads VMs over separate data centers in one region.

2What is the difference between scale up and scale out?

Scale up changes the VM size. Scale out adds more VMs.

3You will update a VM. Which is faster for a rollback: a snapshot or a backup?

A snapshot. It is one point-in-time copy of one disk.

4What must you create before the web app?

An App Service Plan.

5How do you release a new version with no downtime?

Put the new version in a staging slot, test it, then swap the slots.

6Which tool shows slow requests and failed dependencies?

Application Insights.

7Which service runs one container with no cluster?

Azure Container Instances (ACI).

8What does KEDA do in Azure Container Apps?

It adds or removes replicas when an event or a queue needs it.

9Name two parts of the AKS control plane.

Any two of: kube-apiserver, etcd, kube-scheduler, kube-controller-manager.

10Why is an ARM template called declarative?

You describe the end state. You do not write every step.

11Which command checks a template before deploy?
12You need the same template in five environments. What do you use for the differences?

Parameters. Store the shared template as a template spec.

الأوامر في هذا الدرس

تدرّب

كل الأوامر في هذا الفصل