Free Programming learning guide
Microsoft Azure Fundamentals for Beginners
Microsoft Azure Fundamentals for Beginners — a free beginner-level guide covering learn microsoft azure fundamentals for beginners. Learn with clear...
What you will learn
- Cloud Computing Concepts and Azure Basics
- Core Azure Architectural Components
- Navigating the Azure Portal and CLI
- Azure Compute Services
- Azure Storage Solutions
- Azure Networking Fundamentals
- Identity, Access, and Security in Azure
- Cost Management and Pricing in Azure
- Governance, Compliance, and Privacy
- Monitoring, Diagnostics, and Management Tools
1. Cloud Computing Concepts and Azure Basics
Imagine you are opening a new coffee shop. You need an espresso machine, refrigerators, seating, and a point-of-sale system. You have two choices: you can buy all the equipment outright, paying tens of thousands of dollars up front before you sell a single cup of coffee. Or, you can rent a fully equipped kiosk by the day. If a sudden cold snap hits and nobody wants iced coffee, you can swap your rented fridge for a pastry oven overnight. If a massive festival comes to town, you can instantly rent three more espresso machines for the weekend, returning them on Monday. This second option is the essence of cloud computing. It is the shift from buying and maintaining your own physical computer hardware to renting computing power and storage from someone else on an as-needed basis. Microsoft Azure is one of the largest providers of these rented services in the world. Before we learn how to navigate Azure, we first need to understand what the cloud actually is, how it works, and the economic and technical models that make it so powerful. What is Cloud Computing? At its simplest, cloud computing is the delivery of computing services—including servers, storage, databases, networking, software, and analytics—over the internet. Historically, if a company wanted to run a website or an application, they had to buy physical servers, put them in a dedicated room with specialized cooling and power systems, and hire a team of IT professionals to maintain them. If the website suddenly went viral and the servers couldn't handle the traffic, the company had to order more physical servers, wait weeks for them to be delivered, and install them. Cloud computing flips this model. Instead of owning the physical hardware, you "rent" it from a cloud provider—a company that owns massive data centers filled with thousands of servers. You access these resources over the internet, and you typically pay only for what you use, much like you pay your electricity or water bill. Key Characteristics of the Cloud To understand why the cloud revolutionized technology, we need to look at a few of its defining characteristics: On-demand self-service: You can provision computing resources (like a new server) almost instantly with a few clicks, without needing to interact with a human representative from the cloud provider. Elasticity and Scalability: The cloud can automatically adjust to your workload. If your website gets a sudden spike in traffic, the cloud can automatically add more server power to handle it (scaling out), and just as easily remove that power when traffic dies down (scaling in). Resource pooling: The cloud provider serves multiple customers from the same physical hardware. Your data is isolated and secure, but you …
2. Core Azure Architectural Components
The Physical Foundation: Datacenters, Regions, and Availability Zones Imagine you are building a house. Before you can frame the walls, run the plumbing, or paint the rooms, you need a solid foundation. In traditional on-premises computing, this foundation was literally a room in your office building with specialized power, cooling, and physical security. When you move to the cloud using a provider like Microsoft Azure, you no longer own that physical room. However, the physical infrastructure still exists—it just belongs to Microsoft, and you rent access to it. To understand how Azure keeps your applications running securely and reliably, we first need to look at the physical building blocks of the cloud. Azure Datacenters At the absolute lowest level of Azure is the datacenter. A datacenter is a physical facility—essentially a massive, highly secure warehouse—filled with thousands of servers. These are the physical computers that actually do the computing, store the data, and route the network traffic for your cloud applications. An Azure datacenter is not a standard office building. It is engineered with redundant power grids, massive cooling systems to prevent the servers from overheating, and strict physical security measures (like biometric scanners and mantraps) to ensure only authorized personnel can access the hardware. However, a single datacenter is a single point of failure. If a fire, flood, or massive power outage were to hit that specific building, every application running inside it would go offline. To prevent this, Azure does not rely on individual datacenters; it groups them together. Regions To protect against localized disasters, Azure uses Regions. A region is a geographical area on the planet that contains at least one, but usually multiple, Azure datacenters. These datacenters within a single region are connected through a massive, high-speed, private fiber-optic network. Because they are connected by private, low-latency links, datacenters in the same region can communicate with each other almost instantly. This allows you to build applications that span multiple datacenters within the same region, providing redundancy if one datacenter goes down, while still offering fast performance to your users. When you deploy a resource in Azure—like a virtual machine or a database—you must choose which region it will live in. Azure has over 60 regions globally, spanning more countries than any other public cloud provider. Real-World Example: The E-Commerce Latency Problem Imagine you are building an e-commerce platform for a retail company based in New York. If you deploy your application in an Azure region located in Western Europe, every time a customer in New York clicks a button, that request has to travel across the Atlantic Ocean and back. This physical distance introduces latency (delay), making your website feel sluggish. By deploying your application in …
3. Navigating the Azure Portal and CLI
The Two Faces of Azure Management Imagine you have just been hired as the IT lead for a growing marketing agency. The company has decided to migrate their on-premises web applications to the cloud to take advantage of the elasticity and OpEx model we discussed in earlier chapters. Your first task: provision a new environment for the development team to test their code. You have the architectural components in mind—you know you need a resource group to hold everything together—but how do you actually log in and build it? Microsoft Azure provides two primary interfaces for interacting with your cloud environment: the Azure portal and the Azure Command-Line Interface (CLI). The Azure portal is a web-based, graphical user interface (GUI). If you have ever changed the settings on your home Wi-Fi router by typing an IP address into a web browser, you have used a web-based GUI. The portal is visual, intuitive, and excellent for exploring new services or performing complex, one-off configurations. The Azure CLI, on the other hand, is a text-based interface. Instead of clicking buttons, you type explicit commands to create, update, and delete Azure resources. Neither tool is inherently "better" than the other. They are two doors leading to the exact same underlying Azure infrastructure. Most cloud professionals use both daily—relying on the portal to visualize their environment and the CLI to automate repetitive tasks. Navigating and Customizing the Azure Portal When you first log into the Azure portal (portal.azure.com), you are greeted by a dense, information-rich screen. Because Azure offers hundreds of services, Microsoft designed the portal to be highly customizable so you don't get overwhelmed by tools you don't use. The Anatomy of the Portal The portal interface is divided into a few key areas: - The global search bar: Located at the top center, this is your fastest way to find anything. If you want to create a virtual network, you simply type "virtual network" and hit Enter. - The left-hand sidebar: This is the main navigation menu. It contains links to core management areas like Home, Dashboards, Marketplace, and All resources. - The top navigation bar: This area holds your account settings, notifications (the bell icon), and Cloud Shell (a terminal icon we will use later). - The Azure Marketplace: Think of this as an app store for cloud resources. You can find pre-configured virtual machines, databases, and third-party software. Customizing Your Dashboard By default, the Azure portal Home page shows a generic layout with quick links and service health. However, you can build custom dashboards to tailor the portal to your specific needs. A dashboard is a customizable workspace that gives you a focused view of the resources you care about …
4. Azure Compute Services
The Heart of the Cloud: Running Your Code Imagine you have written a groundbreaking new web application. It works perfectly on your laptop. But now, you need the entire world to access it. You could buy a server, plug it into your internet router, and configure it to handle web traffic—but as we learned when discussing Capital Expenditure (CapEx), buying hardware is expensive, requires maintenance, and doesn't easily scale. This is where Compute comes in. In cloud computing, "compute" refers to the processing power, memory, and storage needed to run your applications. When you use Azure, you are essentially renting compute resources from Microsoft's massive global datacenters on an Operational Expenditure (OpEx) basis. You pay for exactly what you use, when you use it. Azure offers several different ways to run your code, ranging from fully managed servers to code that runs without you ever thinking about a server at all. Choosing the right compute service depends entirely on what your application needs to do, how much control you want, and how much maintenance you are willing to handle. Azure Virtual Machines: Total Control in the Cloud At the most fundamental level of cloud computing is the Virtual Machine (VM). A VM is a software-based emulation of a physical computer. When you create a VM in Azure, you are renting a slice of a physical server in a Microsoft datacenter. However, you interact with it exactly as if it were a physical box sitting under your desk. Because Azure operates on the Infrastructure as a Service (IaaS) model, the cloud provider handles the physical building, the networking cables, and the physical server hardware. You are responsible for everything above that: the operating system, the software you install, your data, and your applications. Anatomy of a Virtual Machine When you create a VM through the Azure Portal or the Azure CLI, you make a few key choices: Operating System: You can choose Windows Server, or various distributions of Linux like Ubuntu or Red Hat. VM Size: Azure offers dozens of pre-configured sizes. Some sizes are optimized for heavy math (compute-optimized), some for holding lots of data in memory (memory-optimized), and some for basic web hosting (general-purpose). Storage: You attach virtual hard drives to your VM to hold your operating system and files. When to Use a Virtual Machine Virtual machines are the ultimate "lift and shift" tool. If you have an application that already runs on a server in your own building, you can create a VM in Azure, install the exact same software, and move your application to the cloud with very little code changes. Real-World Example: The Legacy Accounting Software Imagine a mid-sized law firm running a proprietary accounting …
5. Azure Storage Solutions
The Foundation of Every Cloud Application Imagine you are launching a new mobile app that lets users upload and share short video clips. Your application needs somewhere to store those video files, a place to keep the application code, and a database to track user profiles and video metadata. If you were building this in a traditional on-premises data center, you would need to buy physical hard drives, rack them in servers, configure redundant arrays, and manage backups. In the cloud, you don't buy hard drives—you rent storage services. As we discussed in the chapters on cloud computing concepts and Azure's architectural components, moving to the cloud shifts your spending from Capital Expenditure (CapEx) to Operational Expenditure (OpEx). Nowhere is this shift more obvious than in how you store data. In Azure, data storage is handled by Azure Storage, a set of massively scalable, highly available cloud services designed to handle virtually any type of data. But not all data is created equal. A database file behaves differently than a streaming video, and a virtual machine’s operating system has different requirements than a backup archive. Because of this, Azure offers several distinct types of storage. To decide which one fits your needs, you first need to understand the difference between structured and unstructured data. Structured vs. Unstructured Data Before you can choose a storage solution, you must know what kind of data you are storing. Structured data is highly organized. It fits neatly into rows and columns, like a spreadsheet or a relational database. Examples include customer names, order quantities, and product prices. Unstructured data (sometimes called object data) is everything else. It doesn't follow a strict format. Examples include photographs, video files, text documents, log files, and application binaries. Most of the storage services we will cover in this chapter are designed for unstructured data, with one notable exception (Disk storage, which behaves a bit differently). Differentiating Between Blob, Disk, and File Storage When you create a storage resource in Azure, you are creating a Storage Account. Think of the storage account as the secure container that holds all your data. Inside that container, Azure offers three primary ways to store data: Blob storage, Disk storage, and File storage. Blob Storage Blob storage (Binary Large Object) is Azure’s solution for storing massive amounts of unstructured data. If you have a file—whether it’s a 2-kilobyte text file or a 50-gigabyte high-definition video—Blob storage can hold it. When you create a Blob, you place it inside a container, which is similar to a folder on your local computer. Containers help you organize your blobs and manage who can access them. When to use Blob storage: Serving images or documents directly to …
6. Azure Networking Fundamentals
The Digital Nervous System Imagine walking into a massive, highly secure corporate campus. You have a keycard that lets you through the front door, but once inside, you can't just wander into any room. The accounting department is behind a locked door, the server room requires a special biometric scan, and the public lobby is completely separated from the employee workspaces. In the previous chapters, we built the "rooms" of our Azure environment. We explored Azure Compute Services (the virtual machines and applications doing the work) and Azure Storage Solutions (the filing cabinets holding the data). But how do these resources talk to each other? How does a web server securely reach a database server without exposing it to the public internet? And how does an external user on the other side of the world securely reach that web server? This is where networking comes in. Azure Networking acts as the digital nervous system of your cloud environment. It connects your resources to each other, to the internet, and to your on-premises data centers. Just like physical networks require cables, routers, and firewalls, Azure requires virtual networks, IP addresses, and security rules to keep data flowing safely. Azure Virtual Networks (VNets) and Subnets In the physical world, computers are plugged into switches and routers using Ethernet cables. In Azure, resources are connected using an Azure Virtual Network (VNet). A VNet is a logical isolation of the Azure cloud dedicated to your subscription. Think of it as your own private, customizable data center floor inside one of the Azure regions we discussed in earlier chapters. When you create a virtual machine or a database in Azure, you typically place it inside a VNet so it can communicate with your other resources securely. Chopping Up the Network: Subnets Within a physical building, you don't usually run one massive open floor plan for everything; you build walls to create separate rooms. In Azure, you divide a VNet into subnets. A subnet is a range of IP addresses within the VNet. Subnets allow you to organize your resources based on their function and security requirements. For example, a standard three-tier web application might be organized like this: 1. Front-end subnet: Holds your web servers that interact directly with internet users. 2. Application subnet: Holds the business logic servers that process data. 3. Data subnet: Holds your databases. By placing these components in separate subnets, you create natural boundaries. You can dictate exactly which subnet is allowed to talk to which. Even though they live in the same VNet, the front-end web servers don't necessarily need direct access to the databases—that traffic can be forced to go through the application servers first. Real-World Example: E-Commerce …
7. Identity, Access, and Security in Azure
The Perimeter Shifts: Why Identity Is Your New Firewall Imagine for a moment that you are managing the IT infrastructure for a mid-sized retail company. Five years ago, your security strategy was largely physical. You had a secure office building. Employees walked through a front door, showed a badge to a security guard, sat down at a company-owned desktop computer, and logged into a local network. Your firewall was the physical wall of the building, backed up by a network firewall that kept the outside world out. Today, that retail company looks very different. Employees work from home, connecting from personal laptops and mobile phones. Your inventory system runs on Azure Virtual Machines, your product images are stored in Azure Storage Accounts, and your customer-facing application is hosted in the cloud. There is no physical building protecting your servers, and your network perimeter is porous. In the cloud, the traditional network boundary dissolves. Your organization's data and applications are accessible from anywhere in the world. This shift fundamentally changes the nature of security. In the cloud, identity is your primary security perimeter. It doesn’t matter if a user is sitting in your corporate headquarters or connecting from a coffee shop on the other side of the planet; if they can prove who they are, they can access your resources. If they cannot, the door remains locked. To manage this new perimeter, Azure relies on a robust system of identity management, access control, and security tooling. Microsoft Entra ID: The Gatekeeper of the Cloud At the center of Azure’s identity management is Microsoft Entra ID. If you have been exploring Azure, you might have previously heard this referred to as Azure Active Directory (or Azure AD). Microsoft officially renamed it to Microsoft Entra ID to unify its identity and access portfolio, but the core functionality remains the same. To understand Entra ID, it helps to contrast it with traditional, on-premises Active Directory. Traditional Active Directory (AD) was designed for internal, office-bound networks. It used protocols like Kerberos and LDAP to authenticate users who were physically connected to the corporate network. Microsoft Entra ID, on the other hand, is a cloud-based identity service designed for the modern, decentralized internet. It is the system that authenticates users for Microsoft 365, the Azure portal, and thousands of other Software-as-a-Service (SaaS) applications. How Entra ID Works Think of Microsoft Entra ID as a highly secure, digital phonebook combined with an ID-checking service. It is organized into tenants. A tenant is a dedicated and trusted instance of Entra ID that represents your organization. When your organization signs up for an Azure subscription, a tenant is automatically created for you. Inside this tenant, you create objects. The …
8. Cost Management and Pricing in Azure
The Cloud Bill Shock: A Cautionary Tale Imagine a small startup that just launched a new mobile app. To handle their backend, they create a virtual machine in Azure to host their database and application programming interface (API). Excited to test their app, they configure the virtual machine with powerful specifications. They test it for a few days, get the results they wanted, and move on to writing code for the next feature. They leave the virtual machine running. A month later, the CEO opens the company credit card statement and finds a bill for thousands of dollars. What happened? They fell victim to "cloud bill shock." In traditional IT, you buy a physical server (a Capital Expenditure, or CapEx). Whether you use the server or let it sit idle, you have already paid for it. In Azure, you are using Operational Expenditure (OpEx). You pay for what you use, metered by the minute or second. If you leave a powerful resource running 24/7, you are billed for 24/7 usage, even if no actual users are accessing your application. Understanding how Azure calculates costs—and knowing how to monitor and control them—is arguably the most critical practical skill for anyone working with the cloud. Factors That Affect Azure Pricing Azure uses metered pricing, meaning you pay for resources much like you pay for water or electricity at home. However, the "meter" runs at different rates depending on three primary factors: the type of resource, its size, and the region it lives in. Compute Costs In Chapter 4, we explored Azure Compute Services like Virtual Machines and Azure App Service. Compute is usually the most significant driver of your cloud bill. Azure prices compute based on several variables: Resource Type: An Azure Virtual Machine (IaaS) is billed differently than an Azure App Service (PaaS). With a VM, you pay for the underlying compute power and must manage the operating system. With a PaaS offering, Azure manages the operating system, which might cost slightly more per hour but saves you money in maintenance time and licensing. Instance Size: The more CPU, RAM, and specialized hardware (like GPUs) you request, the higher the hourly rate. Operating System: Windows-based virtual machines typically cost slightly more per hour than Linux-based virtual machines because Microsoft includes the licensing fee for the Windows OS in the compute cost. Execution Time: Serverless compute options like Azure Functions are billed based on execution time and memory used, down to the millisecond. If your code doesn't run, you don't pay. Storage Costs As discussed in Chapter 5, Azure offers various Storage Solutions. Storage costs are generally calculated based on: Storage Type and Tier: Storing data in a Standard General Purpose v2 …
9. Governance, Compliance, and Privacy
The Guardrails of the Cloud Imagine a fast-growing retail company that recently migrated its infrastructure to Microsoft Azure. During a busy holiday sale, a junior developer logs into the Azure portal to update a virtual machine. Instead of modifying the VM, they accidentally select a critical customer database, click "Delete," and wipe it from existence. In the on-premises world, physical servers don't disappear with a single mouse click. But in the cloud, on-demand self-service means resources can be created, modified, and destroyed in seconds. While this elasticity is a massive advantage, it also introduces new risks: accidental deletions, inconsistent configurations, and unauthorized data access. To prevent these disasters, organizations use cloud governance. Governance is the set of rules, policies, and processes that ensure your cloud resources are used safely, securely, and legally. It acts as the guardrails on a highway—keeping your cloud environment on track and preventing costly accidents. In this chapter, we will explore the Azure tools that enforce these guardrails, from preventing accidental deletions to automatically enforcing corporate standards and meeting global legal requirements. Preventing Disaster with Azure Resource Locks When we discussed Operational Expenditure (OpEx) and cloud cost management, we noted how easy it is to spin up new resources. But what happens when you need to ensure a resource isn't deleted or changed? Enter Azure Resource Locks. A resource lock is a setting applied to a resource, resource group, or subscription that overrides user permissions to protect against accidental deletion or modification. It is crucial to understand that Resource Locks are independent of Identity, Access, and Security in Azure. Even if you are the Global Administrator of the entire Azure environment, a Resource Lock will stop you from deleting a resource until you explicitly remove the lock. This separation ensures that a simple human error doesn't cause a catastrophic outage. Types of Resource Locks Azure provides two levels of locking: 1. Delete (CanNotDelete): Authorized users can still read and modify a resource, but they cannot delete it. For example, a database administrator could change the performance tier of a database, but they could not drop the database entirely. 2. ReadOnly: Authorized users can read a resource, but they cannot modify or delete it. This is useful for preventing changes to a stable, production environment. If a user tries to alter a ReadOnly resource, Azure blocks the action entirely. How Locks Inherit Locks are applied at a specific scope—either an individual resource, a resource group, or a subscription. When you apply a lock at a higher scope, like a subscription, it inherits down to all resources within that subscription. If you lock a resource group, every virtual machine, storage account, and virtual network inside that group inherits …
10. Monitoring, Diagnostics, and Management Tools
The Pulse of Your Cloud Environment Imagine you are the IT administrator for a rapidly growing e-commerce company. Black Friday is approaching, and your team has migrated the company's web application to Microsoft Azure to handle the expected surge in traffic. The application runs on Azure Virtual Machines, utilizes Azure Storage for product images, and relies on Azure Virtual Networks to route traffic. On the morning of the big sale, everything looks green. But by noon, customers are complaining that the website is slow, and some are receiving timeout errors when trying to check out. You log into the Azure portal, but all your virtual machines show a "Running" status. So, what is going wrong? A virtual machine showing a "Running" status simply means the operating system is powered on. It does not tell you if the CPU is maxed out, if the memory is exhausted, or if a specific background service has crashed. To find that out, you need visibility into the inner workings of your resources. This is where monitoring, diagnostics, and management tools come into play. In your on-premises data center, you might have walked up to a server to check the blinking lights or plugged in a dedicated monitor. In the cloud, you rely on telemetry—automated data collected from your resources—to act as your eyes and ears. Azure Monitor vs. Azure Service Health When discussing the health of your cloud environment, there are two distinct perspectives: the health of your specific resources and the health of the Azure platform itself. Azure addresses these two perspectives with two different services: Azure Monitor and Azure Service Health. Azure Monitor Azure Monitor is a comprehensive platform for collecting, analyzing, and acting on telemetry data from your Azure and on-premises environments. It is the primary tool you will use to understand how your applications and resources are performing. Azure Monitor works by ingesting two fundamental types of data: Metrics: These are numerical values collected at regular intervals. Metrics describe some aspect of a resource at a particular time. For example, a metric might tell you that a virtual machine is currently using 85% of its CPU, or that a database has 150 active connections. Because metrics are lightweight and numerical, they are excellent for generating real-time charts and triggering fast alerts (e.g., "Send an email if CPU goes above 90%"). Logs: These are events or records of activity. Logs contain different kinds of data organized into records, each with different sets of properties. A log might tell you that a specific user logged in at 10:04 AM, or that a web server returned a "404 Not Found" error when a user tried to access a missing image. Logs are highly …
Continue learning
- Pass the AWS Solutions Architect Associate ExamPass the AWS Solutions Architect Associate Exam — a free intermediate-level guide covering how to pass the aws solutions architect exam. Learn with...
- Pass the AWS Solutions Architect Exam: Advanced GuidePass the AWS Solutions Architect Exam: Advanced Guide — a free advanced-level guide covering how to pass the aws certified solutions architect exam....
- Intermediate Python Automation Scripts for BeginnersIntermediate Python Automation Scripts for Beginners — a free intermediate-level guide covering intermediate python automation scripts for beginners....
- Intermediate Python Projects for Portfolio BuildingIntermediate Python Projects for Portfolio Building — a free intermediate-level guide covering intermediate python projects for portfolio building....