Skip to content

Commit af1f0c2

Browse files
committed
Tech review of Azure Linux Learning Path
1 parent 12dd6e1 commit af1f0c2

File tree

6 files changed

+65
-40
lines changed

6 files changed

+65
-40
lines changed

content/install-guides/azure-cli.md

Lines changed: 5 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -22,11 +22,7 @@ It is available for a variety of operating systems and Linux distributions and h
2222

2323
## How do I prepare to install the Azure CLI on Ubuntu?
2424

25-
[General installation information](https://learn.microsoft.com/en-us/cli/azure/install-azure-cli-linux?pivots=apt) is available which covers all supported Linux distributions. Starting with version 2.46.0, Azure CLI supports Arm64 Linux distributions. The 'apt' package manager contains both x86_64 and Arm64 packages for the following linux distributions
26-
27-
```output
28-
Ubuntu 20.04, Ubuntu 22.04, Ubuntu 24.04
29-
```
25+
[General installation information](https://learn.microsoft.com/en-us/cli/azure/install-azure-cli-linux?pivots=apt) is available which covers all supported Linux distributions. Starting with version 2.46.0, Azure CLI supports Arm64 Linux distributions. The 'apt' package manager contains both x86_64 and Arm64 packages for Ubuntu 20.04, Ubuntu 22.04, and Ubuntu 24.04.
3026

3127
## How do I install the Azure CLI using the installation script?
3228

@@ -60,8 +56,8 @@ You should see an output similar to:
6056

6157
```output
6258
{
63-
"azure-cli": "2.61.0",
64-
"azure-cli-core": "2.61.0",
59+
"azure-cli": "2.75.0",
60+
"azure-cli-core": "2.75.0",
6561
"azure-cli-telemetry": "1.1.0",
6662
"extensions": {}
6763
}
@@ -98,8 +94,8 @@ You should see an output similar to:
9894

9995
```output
10096
{
101-
"azure-cli": "2.61.0",
102-
"azure-cli-core": "2.61.0",
97+
"azure-cli": "2.75.0",
98+
"azure-cli-core": "2.75.0",
10399
"azure-cli-telemetry": "1.1.0",
104100
"extensions": {}
105101
}

content/learning-paths/servers-and-cloud-computing/azure-vm/_index.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ learning_objectives:
1717

1818
prerequisites:
1919
- A [Microsoft Azure](https://azure.microsoft.com/) account with permission to create resources, including instances using Cobalt 100 processors.
20-
- A local Linux machine with [QEMU](https://www.qemu.org/download/) and the [Azure CLI](/install-guides/azure-cli/) installed and authenticated.
20+
- A Linux machine with [QEMU](https://www.qemu.org/download/) and the [Azure CLI](/install-guides/azure-cli/) installed and authenticated.
2121

2222
author: Jason Andrews
2323

content/learning-paths/servers-and-cloud-computing/azure-vm/azure-vm.md

Lines changed: 14 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ layout: learningpathall
88

99
You can view the Azure Linux 3.0 project on [GitHub](https://github.com/microsoft/azurelinux). There are links to the ISO downloads in the project README.
1010

11-
Using QEMU, you can create a raw disk image and boot a virtual machine with the ISO to install the OS onto the disk.
11+
Using QEMU, you can create a raw disk image and boot a virtual machine with the ISO to install the OS on the disk.
1212

1313
Once the installation is complete, you can convert the raw disk to a fixed-size VHD, upload it to Azure Blob Storage, and then use the Azure CLI to create a custom Arm image.
1414

@@ -20,9 +20,9 @@ Use `wget` to download the Azure Linux ISO image file.
2020
wget https://aka.ms/azurelinux-3.0-aarch64.iso
2121
```
2222

23-
Use `qemu-img` to create a 32 GB raw disk image.
23+
Use `qemu-img` to create a 32 GB empty raw disk image to install the OS.
2424

25-
This step creates a 32 GB empty raw disk image to install the OS. You can increase the disk size by modifying the value passed to `qemu-img`.
25+
You can increase the disk size by modifying the value passed to `qemu-img`.
2626

2727
```bash
2828
qemu-img create -f raw azurelinux-arm64.raw 34359738368
@@ -46,7 +46,14 @@ qemu-system-aarch64 \
4646
-device virtio-net-device,netdev=net0
4747
```
4848

49-
Once the OS boots successfully, install the Azure Linux Agent for VM provisioning, and power off the VM.
49+
Navigate through the installer by entering the hostname, username, and password for the custom image.
50+
You should use the username of `azureuser` if you want match the instructions on the following pages.
51+
52+
Be patient, it takes some time to complete the full installation.
53+
54+
At the end of installation you are prompted for confirmation to reboot the system.
55+
56+
Once the newly installed OS boots successfully, install the Azure Linux Agent for VM provisioning, and power off the VM.
5057

5158
```bash
5259
sudo dnf install WALinuxAgent -y
@@ -55,6 +62,8 @@ sudo systemctl start waagent
5562
sudo poweroff
5663
```
5764

65+
Be patient, it takes some time to install the packages and power off.
66+
5867
## Convert the raw disk to VHD Format
5968

6069
Now that the raw disk image is ready to be used, convert the image to fixed-size VHD, making it compatible with Azure.
@@ -64,7 +73,7 @@ qemu-img convert -f raw -o subformat=fixed,force_size -O vpc azurelinux-arm64.ra
6473
```
6574

6675
{{% notice Note %}}
67-
VHD files have 512 bytes of footer attached at the end. The `force_size` flag ensures that the exact virtual size specified is used for the final VHD file. Without this, QEMU may round the size or adjust for footer overhead (especially when converting from raw to VHD). The `force_size` flag forces the final image to match the original size. This flag helps make the final VHD size a clean, whole number in MB or GiB, which is required for Azure.
76+
VHD files have 512 bytes of footer attached at the end. The `force_size` flag ensures that the exact virtual size specified is used for the final VHD file. Without this, QEMU may round the size or adjust for footer overhead (especially when converting from raw to VHD). The `force_size` flag forces the final image to match the original size. This flag makes the final VHD size a whole number in MB or GB, which is required for Azure.
6877
{{% /notice %}}
6978

7079
Next, you can save the image in your Azure account.

content/learning-paths/servers-and-cloud-computing/azure-vm/background.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -36,8 +36,8 @@ You should see an output similar to:
3636

3737
```output
3838
{
39-
"azure-cli": "2.61.0",
40-
"azure-cli-core": "2.61.0",
39+
"azure-cli": "2.75.0",
40+
"azure-cli-core": "2.75.0",
4141
"azure-cli-telemetry": "1.1.0",
4242
"extensions": {}
4343
}

content/learning-paths/servers-and-cloud-computing/azure-vm/save-image.md

Lines changed: 31 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,14 @@ VM_SIZE="Standard_D4ps_v6"
3737
You can modify the environment variables such as RESOURCE_GROUP, VM_NAME, and LOCATION based on your naming preferences, region, and resource requirements.
3838
{{% /notice %}}
3939

40+
Make sure to login to Azure using the CLI.
41+
42+
```bash
43+
az login
44+
```
45+
46+
If a link is printed, open it in a browser and enter the provided code to authenticate.
47+
4048
Create a new resource group. If you are using an existing resource group for the RESOURCE_GROUP environment variable you can skip this step.
4149

4250
```bash
@@ -88,41 +96,41 @@ az sig create \
8896
Create the image definition.
8997

9098
```bash
91-
az sig image-definition create
92-
--resource-group "$RESOURCE_GROUP"
93-
--gallery-name "$GALLERY_NAME"
94-
--gallery-image-definition "$IMAGE_DEF_NAME"
95-
--publisher "$PUBLISHER"
96-
--offer "$OFFER"
97-
--sku "$SKU"
98-
--os-type "$OS_TYPE"
99-
--architecture "$ARCHITECTURE"
99+
az sig image-definition create \
100+
--resource-group "$RESOURCE_GROUP" \
101+
--gallery-name "$GALLERY_NAME" \
102+
--gallery-image-definition "$IMAGE_DEF_NAME" \
103+
--publisher "$PUBLISHER" \
104+
--offer "$OFFER" \
105+
--sku "$SKU" \
106+
--os-type "$OS_TYPE" \
107+
--architecture "$ARCHITECTURE" \
100108
--hyper-v-generation "$HYPERV_GEN"
101109
```
102110

103111
Create the image version to register the VHD as a version of the custom image.
104112

105113
```bash
106-
az sig image-version create
107-
--resource-group "$RESOURCE_GROUP"
108-
--gallery-name "$GALLERY_NAME"
109-
--gallery-image-definition "$IMAGE_DEF_NAME"
110-
--gallery-image-version "$IMAGE_VERSION"
111-
--location "$LOCATION"
112-
--os-vhd-uri "[https://${STORAGE_ACCOUNT}.blob.core.windows.net/${CONTAINER_NAME}/${VHD_NAME](https://${storage_account}.blob.core.windows.net/$%7BCONTAINER_NAME%7D/$%7BVHD_NAME)}"
113-
--os-vhd-storage-account "$STORAGE_ACCOUNT"
114+
az sig image-version create \
115+
--resource-group "$RESOURCE_GROUP" \
116+
--gallery-name "$GALLERY_NAME" \
117+
--gallery-image-definition "$IMAGE_DEF_NAME" \
118+
--gallery-image-version "$IMAGE_VERSION" \
119+
--location "$LOCATION" \
120+
--os-vhd-uri "https://${STORAGE_ACCOUNT}.blob.core.windows.net/${CONTAINER_NAME}/${VHD_NAME}" \
121+
--os-vhd-storage-account "$STORAGE_ACCOUNT" \
114122
--storage-account-type "$STORAGE_ACCOUNT_TYPE"
115123
```
116124

117125
Once the image has been versioned, you can retrieve the unique image ID for use in VM creation.
118126

119127
```bash
120-
IMAGE_ID=$(az sig image-version show
121-
--resource-group "$RESOURCE_GROUP"
122-
--gallery-name "$GALLERY_NAME"
123-
--gallery-image-definition "$IMAGE_DEF_NAME"
124-
--gallery-image-version "$IMAGE_VERSION"
128+
IMAGE_ID=$(az sig image-version show \
129+
--resource-group "$RESOURCE_GROUP" \
130+
--gallery-name "$GALLERY_NAME" \
131+
--gallery-image-definition "$IMAGE_DEF_NAME" \
132+
--gallery-image-version "$IMAGE_VERSION" \
125133
--query "id" -o tsv)
126134
```
127135

128-
Next, you can create a virtual machine with the new image using the image ID.
136+
Next, you can create a virtual machine with the new image using the image ID.

content/learning-paths/servers-and-cloud-computing/azure-vm/start-vm.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -38,4 +38,16 @@ Use the public IP address to SSH to the VM. Replace `<public-ip-address>` with t
3838
ssh azureuser@<public-ip-address>
3939
```
4040

41+
After you login, print the machine information.
42+
43+
```bash
44+
uname -a
45+
```
46+
47+
The output is similar to:
48+
49+
```output
50+
Linux MyAzureLinuxARMVM 6.6.92.2-2.azl3 #1 SMP Wed Jul 2 02:43:35 UTC 2025 aarch64 aarch64 aarch64 GNU/Linux
51+
```
52+
4153
You are ready to use your Azure Linux virtual machine.

0 commit comments

Comments
 (0)