diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/_index.md b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/_index.md new file mode 100644 index 0000000000..3c16ff34ad --- /dev/null +++ b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/_index.md @@ -0,0 +1,65 @@ +--- +title: Deploy Longhorn on Azure Cobalt 100 Arm64 virtual machines for Kubernetes persistent storage + +description: Learn how to install and configure Longhorn on an Azure Cobalt 100 Arm64 virtual machine, deploy Kubernetes persistent storage using K3s, create Persistent Volumes, and benchmark storage performance for cloud-native workloads. + +minutes_to_complete: 60 + +who_is_this_for: This is an introductory topic for developers, DevOps engineers, platform engineers, and Kubernetes administrators who want to deploy persistent storage for Kubernetes workloads using Longhorn on Arm-based cloud infrastructure. + +learning_objectives: + - Install and configure K3s Kubernetes on Azure Cobalt 100 Arm64 virtual machines + - Deploy and configure Longhorn distributed block storage on Arm64 + - Create and manage Kubernetes Persistent Volumes using Longhorn + - Benchmark Kubernetes storage performance using fio + +prerequisites: + - A [Microsoft Azure account](https://azure.microsoft.com/) with access to Cobalt 100 based instances (Dpsv6) + - Basic knowledge of Linux command-line operations + - Familiarity with SSH and remote server access + - Basic understanding of Kubernetes and containerized workloads + +author: Pareena Verma + +### Tags +skilllevels: Introductory +subjects: Containers and Virtualization +cloud_service_providers: + - Microsoft Azure + +armips: + - Neoverse + +tools_software_languages: + - Longhorn + - Kubernetes + - K3s + - fio + +operatingsystems: + - Linux + +further_reading: + - resource: + title: Longhorn Official Website + link: https://longhorn.io/ + type: website + - resource: + title: Longhorn Documentation + link: https://longhorn.io/docs/ + type: documentation + - resource: + title: K3s Documentation + link: https://docs.k3s.io/ + type: documentation + - resource: + title: Azure Cobalt 100 processors + link: https://techcommunity.microsoft.com/blog/azurecompute/announcing-the-preview-of-new-azure-vms-based-on-the-azure-cobalt-100-processor/4146353 + type: documentation + +### FIXED, DO NOT MODIFY +# ================================================================================ +weight: 1 +layout: "learningpathall" +learning_path_main_page: "yes" +--- diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/_next-steps.md b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/_next-steps.md new file mode 100644 index 0000000000..c3db0de5a2 --- /dev/null +++ b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/_next-steps.md @@ -0,0 +1,8 @@ +--- +# ================================================================================ +# FIXED, DO NOT MODIFY THIS FILE +# ================================================================================ +weight: 21 # Set to always be larger than the content in this path to be at the end of the navigation. +title: "Next Steps" # Always the same, html page title. +layout: "learningpathall" # All files under learning paths have this same wrapper for Hugo processing. +--- diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/background.md b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/background.md new file mode 100644 index 0000000000..a1fd43646f --- /dev/null +++ b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/background.md @@ -0,0 +1,59 @@ +--- +title: Understand Longhorn on Azure Cobalt 100 + +weight: 2 + +layout: "learningpathall" +--- + +## Why run Longhorn on Azure Cobalt 100 + +Longhorn on Arm-based Azure Cobalt 100 processors provides lightweight, Kubernetes-native distributed storage for cloud-native workloads running on Arm64 infrastructure. + +Azure Cobalt 100 processors deliver dedicated physical cores per vCPU, providing predictable and consistent performance for Kubernetes storage workloads. This architecture complements Longhorn’s distributed block storage model and helps deliver stable storage performance for stateful applications running on Kubernetes. + +Longhorn enables persistent storage for Kubernetes workloads such as databases, analytics platforms, monitoring stacks, and stateful cloud-native applications running on Azure Cobalt 100 Arm64 virtual machines. + +## Azure Cobalt 100 Arm-based processor + +Azure’s Cobalt 100 is Microsoft’s first-generation, in-house Arm-based processor. Built on Arm Neoverse N2, Cobalt 100 is a 64-bit CPU that delivers strong performance and energy efficiency for cloud-native, scale-out Linux workloads. + +These workloads include: + +- Kubernetes platforms +- Containerized applications +- Open-source databases +- Data analytics systems +- Storage and caching platforms + +Running at 3.4 GHz, Cobalt 100 allocates a dedicated physical core for each vCPU, ensuring predictable and consistent workload performance. + +To learn more, see the Microsoft blog [Announcing the preview of new Azure VMs based on the Azure Cobalt 100 processor](https://techcommunity.microsoft.com/blog/azurecompute/announcing-the-preview-of-new-azure-vms-based-on-the-azure-cobalt-100-processor/4146353). + +## How Longhorn improves Kubernetes storage + +Longhorn is an open-source cloud-native distributed block storage platform designed specifically for Kubernetes environments. + +It provides persistent storage volumes for Kubernetes workloads and enables applications to retain data independently of container or pod lifecycle events. + +Longhorn integrates directly with Kubernetes through the Container Storage Interface (CSI) and provides dynamic volume provisioning, storage management, and persistent storage capabilities for stateful workloads. + +To learn more, see the official [Longhorn documentation](https://longhorn.io/docs/). + +Longhorn provides several important capabilities for Kubernetes storage management: + +- Persistent Volumes: Dynamically provisions Kubernetes Persistent Volumes for stateful workloads. +- Distributed Storage: Replicates and manages block storage volumes across Kubernetes nodes. +- CSI Integration: Integrates natively with Kubernetes using the Container Storage Interface. +- Snapshot and Backup Support: Supports volume snapshots and backup operations for Kubernetes workloads. +- Stateful Workload Support: Enables databases, monitoring stacks, and analytics applications to run with persistent storage. + +Longhorn is widely used in Kubernetes environments to provide lightweight and reliable storage without requiring external SAN or NAS infrastructure. + +In this Learning Path, you'll deploy Longhorn on an Azure Cobalt 100 Arm64 virtual machine using K3s Kubernetes. You'll configure Longhorn for a single-node Kubernetes cluster, create Persistent Volumes, validate storage persistence, and benchmark storage performance using fio. + +## What you've learned and what's next + +You now understand why Azure Cobalt 100 and Longhorn are a strong combination for Kubernetes-native persistent storage on Arm64 infrastructure. + +Next, you'll configure Azure networking and firewall rules, install K3s Kubernetes, deploy Longhorn, and begin creating Persistent Volumes for Kubernetes workloads. diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/firewall.md b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/firewall.md new file mode 100644 index 0000000000..8708f3274b --- /dev/null +++ b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/firewall.md @@ -0,0 +1,65 @@ +--- +title: Allow access to the Longhorn Web UI on Azure +weight: 4 + +### FIXED, DO NOT MODIFY +layout: learningpathall +--- + +## Configure external traffic for Longhorn and Kubernetes + +To allow external traffic for the Longhorn Web UI and Kubernetes services on an Azure virtual machine, open the required ports in the Network Security Group (NSG). The NSG can be attached to the virtual machine's network interface or subnet. + +{{% notice Note %}}For more information about Azure setup, see [Getting started with Microsoft Azure Platform](/learning-paths/servers-and-cloud-computing/csp/azure/).{{% /notice %}} + + +### Add inbound firewall rules in Azure + +To expose the required TCP ports for Kubernetes and Longhorn, create an inbound firewall rule. + +1. Navigate to the [Azure portal](https://portal.azure.com), go to **Virtual Machines**, and select your virtual machine. + +![Azure Portal Virtual Machines page with the target VM selected. Verify that the correct Azure Cobalt 100 virtual machine is selected before configuring network access.#center](images/virtual_machine.png "Azure Virtual Machine") + +2. In the left menu, select **Networking**, then select **Network settings**. + +![Azure Portal Networking page showing the network settings linked to the Azure virtual machine. Use this page to manage inbound firewall rules for Kubernetes and Longhorn access.#center](images/networking.png "Azure Networking Settings") + +3. Navigate to **Create port rule**, and select **Inbound port rule**. + +![Azure Portal Create port rule menu with Inbound port rule selected. Use this option to allow external traffic for Longhorn and Kubernetes services.#center](images/port_rule.png "Create Inbound Port Rule") + +4. Configure the inbound security rule with the following settings: + +- **Source:** My IP address +- **Source IP addresses:** *(auto-populated with your current public IP)* +- **Source port ranges:** * +- **Destination:** Any +- **Destination port ranges:** **80,8080,6443** +- **Protocol:** TCP +- **Action:** Allow +- **Name:** allow-longhorn-kubernetes + +This rule allows external access for: + +- Port `80` → HTTP workloads +- Port `8080` → Longhorn Web UI +- Port `6443` → Kubernetes API server + +{{% notice Note %}}Setting **Source** to **My IP address** restricts access to these ports to your current machine only. If your public IP address changes or you access the environment from another system, update the source IP in the NSG rule accordingly.{{% /notice %}} + +5. After filling in the details, select **Add** to save the rule. + +You can now access the Longhorn Web UI externally using: + +```text +http://:8080 +``` + +## What you've learned and what's next + +You've now configured the Azure Network Security Group to allow external traffic for SSH, Kubernetes API access, HTTP workloads, and the Longhorn Web UI. + +These firewall rules allow secure remote management of the Azure Cobalt 100 virtual machine and external access to the Kubernetes storage dashboard. + +Next, you'll create Persistent Volume Claims, deploy workloads using Longhorn storage, and benchmark Kubernetes storage performance on ARM64 infrastructure. diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/final-vm.png b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/final-vm.png new file mode 100644 index 0000000000..5207abfb41 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/final-vm.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/instance.png b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/instance.png new file mode 100644 index 0000000000..285cd764a5 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/instance.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/instance1.png b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/instance1.png new file mode 100644 index 0000000000..b9d22c352d Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/instance1.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/instance4.png b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/instance4.png new file mode 100644 index 0000000000..2a0ff1e3b0 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/instance4.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/longhorn-replica.png b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/longhorn-replica.png new file mode 100644 index 0000000000..ef42434b8f Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/longhorn-replica.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/longhorn-ui.png b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/longhorn-ui.png new file mode 100644 index 0000000000..49bc01ce88 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/longhorn-ui.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/networking.png b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/networking.png new file mode 100644 index 0000000000..9d6d15f8a3 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/networking.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/port_rule.png b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/port_rule.png new file mode 100644 index 0000000000..681dc71aa1 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/port_rule.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/ubuntu-pro.png b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/ubuntu-pro.png new file mode 100644 index 0000000000..d54bd75ca6 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/ubuntu-pro.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/virtual_machine.png b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/virtual_machine.png new file mode 100644 index 0000000000..cf6704fcc6 Binary files /dev/null and b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/images/virtual_machine.png differ diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/install-longhorn.md b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/install-longhorn.md new file mode 100644 index 0000000000..2cb2b2f443 --- /dev/null +++ b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/install-longhorn.md @@ -0,0 +1,268 @@ +--- +title: Deploy Longhorn on Azure Cobalt 100 Arm64 VM +weight: 5 + +### FIXED, DO NOT MODIFY +layout: learningpathall +--- + +## Deploy Longhorn on Azure Cobalt 100 Arm64 VM + +In this section, you'll learn how to install Longhorn on an Azure Cobalt 100 Arm64 virtual machine using a single-node Kubernetes cluster powered by K3s. + +Longhorn provides Kubernetes-native distributed block storage and enables persistent storage for stateful applications running on Arm64 infrastructure. + +You'll set up the Kubernetes environment, install Longhorn, access the Longhorn dashboard, and configure it for a single-node cluster. + +### Update your system + +Start by updating the package index and installing the latest available package updates on the virtual machine. + +```bash +sudo apt update && sudo apt upgrade -y +``` + +### Install required dependencies + +Longhorn requires iSCSI utilities for block storage attachment, along with common tools used for downloading files, checking services, and managing the environment. + +```bash +sudo apt install -y \ +open-iscsi \ +nfs-common \ +curl \ +wget \ +vim \ +git +``` + +### Enable iSCSI service + +Longhorn uses iSCSI to attach block volumes to Kubernetes workloads. Enable and start the iSCSI service before installing Longhorn. + +```bash +sudo systemctl enable iscsid +``` + +```bash +sudo systemctl start iscsid +``` + +Verify that the service is running: + +```bash +sudo systemctl status iscsid +``` + +The output should show that the service is active: + +```output +active (running) +``` + +### Install K3s Kubernetes + +Install K3s, a lightweight Kubernetes distribution suitable for a single-node Azure Cobalt 100 Arm64 VM. + +```bash +curl -sfL https://get.k3s.io | sh - +``` + +### Verify Kubernetes installation + +Check that the Kubernetes node is ready. + +```bash +sudo kubectl get nodes +``` + +The output is similar to: + +```output +NAME STATUS ROLES AGE VERSION +longhorn-Arm64 Ready control-plane,master 1m v1.35.5+k3s1 +``` + +### Configure kubectl access + +Create the Kubernetes configuration directory for the current user. + +```bash +mkdir -p ~/.kube +``` + +Copy the K3s kubeconfig file to your user profile. + +```bash +sudo cp /etc/rancher/k3s/k3s.yaml ~/.kube/config +``` + +Update ownership so that kubectl can access the configuration without sudo. + +```bash +sudo chown $USER:$USER ~/.kube/config +``` + +Set the Kubernetes configuration environment variable. + +```bash +export KUBECONFIG=$HOME/.kube/config +``` + +Persist the configuration for future terminal sessions. + +```bash +echo 'export KUBECONFIG=$HOME/.kube/config' >> ~/.bashrc +source ~/.bashrc +``` + +Verify kubectl access: + +```bash +kubectl get nodes +``` + +The output is similar to: + +```output +NAME STATUS ROLES AGE VERSION +longhorn-Arm64 Ready control-plane 5s v1.35.5+k3s1 +``` + +### Create Longhorn storage directory + +Create a local directory that Longhorn can use for storing volume replicas on the VM. + +```bash +sudo mkdir -p /longhorn +``` + +Set permissions for the directory: + +```bash +sudo chmod 777 /longhorn +``` + +Verify available disk space: + +```bash +df -h +``` + +This helps confirm that enough disk space is available before creating Longhorn volumes. + +### Install Longhorn + +Deploy Longhorn into the Kubernetes cluster using the official Longhorn manifest. + +```bash +kubectl apply -f https://raw.githubusercontent.com/longhorn/longhorn/v1.10.0/deploy/longhorn.yaml +``` + +### Verify Longhorn installation + +Check the Longhorn pods in the `longhorn-system` namespace. + +```bash +kubectl get pods -n longhorn-system +``` + +Wait until the pods are running. The output is similar to: + +```output +NAME READY STATUS RESTARTS AGE +csi-attacher-65c5dd9586-dplk2 1/1 Running 0 19s +csi-attacher-65c5dd9586-krglp 1/1 Running 0 19s +csi-attacher-65c5dd9586-lnt7n 1/1 Running 0 19s +csi-provisioner-c4f7f9c79-6mgtd 1/1 Running 0 19s +csi-provisioner-c4f7f9c79-jcfnq 1/1 Running 0 19s +csi-provisioner-c4f7f9c79-rbnlz 1/1 Running 0 19s +csi-resizer-d4b7d97c7-d26xx 1/1 Running 0 19s +csi-resizer-d4b7d97c7-mw44r 1/1 Running 0 19s +csi-resizer-d4b7d97c7-nvgnf 1/1 Running 0 19s +csi-snapshotter-5c96f555f9-7cmdb 1/1 Running 0 19s +csi-snapshotter-5c96f555f9-l8dzk 1/1 Running 0 19s +csi-snapshotter-5c96f555f9-wkt2g 1/1 Running 0 19s +engine-image-ei-26bab25d-9w2r2 1/1 Running 0 72s +instance-manager-949b7e7f84f3ef321c4078941b7dac4e 1/1 Running 0 42s +longhorn-driver-deployer-5889c569cf-88hwk 1/1 Running 0 94s +longhorn-manager-ptwb5 2/2 Running 0 94s +longhorn-ui-77cdc466b5-8vlrl 1/1 Running 0 94s +longhorn-ui-77cdc466b5-dbsx5 1/1 Running 0 94s +``` + +### Access the Longhorn UI + +Expose the Longhorn frontend service using port forwarding. + +```bash +kubectl -n longhorn-system port-forward --address 0.0.0.0 service/longhorn-frontend 8080:80 +``` + +Open the Longhorn Web UI in your browser. Replace `` with the public IP address of your Azure VM. + +```text +http://:8080 +``` + +![Longhorn UI Dashboard showing the cluster summary, storage schedulable capacity, volume health, and node status on the Azure Cobalt 100 Arm64 virtual machine. Verify that the Kubernetes node is schedulable, Longhorn storage is available, and the dashboard is accessible before proceeding to persistent volume configuration.#center](images/longhorn-ui.png "Longhorn UI Dashboard with storage and node summary") + +In the Longhorn dashboard, you can view the number of volumes, available schedulable storage, node status, and overall storage health. + +### Configure Longhorn for a single-node cluster + +By default, Longhorn expects multiple nodes and uses a higher replica count. Since this learning path uses a single Azure Cobalt 100 VM, configure the replica count as `1`. + +Inside the Longhorn UI, go to: + +```text +Settings +``` + +Find the following setting: + +```text +Default Replica Count +``` + +Update the values: + +```text +V1 Data Engine: 1 +V2 Data Engine: 1 +``` + +Click: + +```text +Save +``` + +![Longhorn Settings page showing the Default Replica Count configuration for single-node Kubernetes deployment on Azure Cobalt 100 Arm64 virtual machine. Ensure both V1 and V2 Data Engine replica counts are configured to 1 before creating Persistent Volumes in the single-node Longhorn environment.#center](images/longhorn-replica.png "Longhorn Replica Configuration for Single-Node Kubernetes Cluster") + +This configuration allows Longhorn volumes to be scheduled successfully on a single-node Kubernetes cluster. + +### Verify StorageClass + +Check the Kubernetes storage classes created by K3s and Longhorn. + +```bash +kubectl get storageclass +``` + +The output is similar to: + +```output +NAME PROVISIONER RECLAIMPOLICY VOLUMEBINDINGMODE ALLOWVOLUMEEXPANSION AGE +local-path (default) rancher.io/local-path Delete WaitForFirstConsumer false 8m48s +longhorn (default) driver.longhorn.io Delete Immediate true 6m29s +longhorn-static driver.longhorn.io Delete Immediate true 6m26s +``` + +The `longhorn` StorageClass confirms that Longhorn is available for dynamic Persistent Volume provisioning. + +## What you've learned and what's next + +You now have Longhorn running on an Azure Cobalt 100 Arm64 virtual machine with K3s Kubernetes. You installed the required dependencies, enabled iSCSI, deployed Longhorn, accessed the Longhorn Web UI, and configured the replica count for a single-node Kubernetes environment. + +Next, you'll create Persistent Volume Claims, deploy an application using Longhorn storage, validate data persistence, and benchmark storage performance using fio. diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/instance.md b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/instance.md new file mode 100644 index 0000000000..66fb2ab71a --- /dev/null +++ b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/instance.md @@ -0,0 +1,66 @@ +--- +title: Create an Azure Cobalt 100 Arm64 virtual machine +weight: 3 + +### FIXED, DO NOT MODIFY +layout: learningpathall +--- + +## Set up the Azure virtual machine + +In this section, you'll launch the Azure portal to create a virtual machine (VM) with the Arm-based Azure Cobalt 100 processor. + +This Learning Path focuses on general-purpose virtual machines in the Dpsv6 series. For more information, see the [Microsoft Azure guide for the Dpsv6 size series](https://learn.microsoft.com/en-us/azure/virtual-machines/sizes/general-purpose/dpsv6-series). + +While the steps to create this instance are included here for convenience, you can also see [Deploy a Cobalt 100 virtual machine on Azure Learning Path](/learning-paths/servers-and-cloud-computing/cobalt/). + +### Create an Arm-based virtual machine in the Azure portal + +To create an Azure virtual machine using the Azure portal: + +1. Launch the Azure portal and navigate to **Virtual Machines**. +2. Select **Create**, and select **Virtual Machine** from the drop-down list. +3. In the **Basic** tab, fill in the instance details such as **Virtual machine name** and **Region**. +4. Select **Ubuntu Pro 24.04 LTS** as the image for your virtual machine, and select **Arm64** as the VM architecture. +5. In the **Size** field, select **See all sizes** and select the D-Series v6 family of virtual machines. +6. Select **D4ps_v6** from the list as shown in the diagram below: + +![Azure Portal showing D-Series v6 VM size selection with D4ps_v6 highlighted#center](images/instance.png "Select D4ps_v6 from the D-Series v6 family") + +7. For **Authentication type**, select **SSH public key**. + +{{% notice Note %}} +Azure generates an SSH key pair for you and lets you save it for future use. This method is fast, secure, and easy for connecting to your virtual machine. +{{% /notice %}} + +8. Fill in the **Administrator username** for your VM. +9. Select **Generate new key pair**, and select **RSA SSH Format** as the SSH Key Type. + +{{% notice Note %}} +RSA offers better security with keys longer than 3072 bits. +{{% /notice %}} + +10. Give your SSH key a key pair name. +11. In the **Inbound port rules**, select **HTTP (80)** and **SSH (22)** as the inbound ports, as shown in the following image: + +![Azure Portal inbound port configuration showing SSH and HTTP selected. Check that the required access settings are in place before creating the virtual machine.#center](images/instance1.png "Configure inbound port rules for HTTP and SSH access") + +12. Select the **Review + Create** tab and review the configuration for your virtual machine. It should look like the following: + +![Azure Portal Review + Create tab showing VM configuration summary ready for deployment#center](images/ubuntu-pro.png "Review VM configuration before creation") + +13. When you're happy with your selection, select the **Create** button and then **Download Private key and Create Resource**. + +![Azure Portal showing Create button and SSH key download dialog#center](images/instance4.png "Download SSH key and create the virtual machine") + +Your virtual machine should be ready and running in a few minutes. You can SSH into the virtual machine using the private key, along with the public IP details. + +![Azure Portal deployment result showing that the virtual machine was created successfully. Look for the successful deployment status and the connection details you will use to access the virtual machine in the next step.#center](images/final-vm.png "Successful VM deployment confirmation") + +{{% notice Note %}}To learn more about Arm-based virtual machines in Azure, see "Getting Started with Microsoft Azure" in [Get started with Arm-based cloud instances](/learning-paths/servers-and-cloud-computing/csp/azure/).{{% /notice %}} + +## What you've accomplished and what's next + +You've created an Azure Cobalt 100 Arm64 virtual machine running Ubuntu 24.04 LTS with K3s Kubernetes installed and networking configured for Longhorn access. The Kubernetes environment is now ready for deploying and managing persistent storage workloads. + +Next, you'll install Longhorn on the Kubernetes cluster, configure the Longhorn Web UI, create Persistent Volumes, and validate Kubernetes-native storage functionality on Azure Cobalt 100 Arm64 infrastructure. diff --git a/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/longhorn-storage-validation-and-benchmark.md b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/longhorn-storage-validation-and-benchmark.md new file mode 100644 index 0000000000..56e5cc35ae --- /dev/null +++ b/content/learning-paths/servers-and-cloud-computing/longhorn-cobalt/longhorn-storage-validation-and-benchmark.md @@ -0,0 +1,261 @@ +--- +title: Validate Persistent Storage and Benchmark Longhorn +weight: 6 + +### FIXED, DO NOT MODIFY +layout: learningpathall +--- + +## Validate Persistent Storage and Benchmark Longhorn + +In this section, you'll create Kubernetes Persistent Volumes using Longhorn, deploy workloads, validate persistent storage functionality, and benchmark storage performance using fio. + +You'll create a Persistent Volume Claim (PVC), attach it to a Kubernetes workload, verify that data survives pod recreation, and run storage benchmarking tests on the Longhorn-backed volume. + +### Create Persistent Volume Claim + +Create a Kubernetes Persistent Volume Claim (PVC) using the Longhorn StorageClass. + +```bash +cat > pvc.yaml < 7s +``` + +The `Bound` status confirms that Longhorn successfully created and attached the Persistent Volume. + +### Deploy test application + +Create an NGINX pod that mounts the Longhorn-backed Persistent Volume Claim. + +```bash +cat > nginx-longhorn.yaml < /usr/share/nginx/html/index.html +``` + +Exit the container: + +```bash +exit +``` + +This creates a file directly on the Longhorn-backed Persistent Volume. + +### Validate persistent storage + +Delete the running pod. + +```bash +kubectl delete pod nginx-longhorn +``` + +Recreate the pod: + +```bash +kubectl apply -f nginx-longhorn.yaml +``` + +Verify that the data still exists after the pod recreation. + +```bash +kubectl exec -it nginx-longhorn -- cat /usr/share/nginx/html/index.html +``` + +The output is similar to: + +```output +Longhorn Storage Working on Arm64 +``` + +This confirms that the data persists independently of the Kubernetes pod lifecycle. + +### Create fio benchmark pod + +Create a benchmarking pod that mounts the Longhorn volume and installs fio for storage testing. + +```bash +cat > fio-pod.yaml <