Hey there! ๐Ÿ‘‹

Iโ€™m Daman Arora (he/him) and I enjoy building things. Read more.

Logical grammar used in linux vi editor

Vi Command Patterns Vi has a logical grammar once you see it. Let me break down the patterns: The Core Grammar: Operator + Motion Most vi commands follow this structure: [count] + operator + motion Operators (what to do): d = delete c = change (delete + enter insert mode) y = yank (copy) Motions (where/how far): w = word forward b = word backward $ = end of line 0 = beginning of line G = end of file gg = beginning of file Combine them:...

December 11, 2025 ยท 2 min ยท Daman Arora

CloudStack VM Deployment - Complete Flow

Understanding the sync and async phases of VM deployment. SYNC PHASE (~250ms) Client blocks here. Must complete before job ID is returned. โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚ SYNC PHASE (37.044 - 37.296) ~250ms โ”‚ โ”œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ค โ”‚ โ”‚ โ”‚ HTTP POST /deployVirtualMachine โ”‚ โ”‚ โ”‚ โ”‚ โ”‚ โ–ผ โ”‚ โ”‚ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚ โ”‚ โ”‚ Authentication โ”‚ 2FA check, CIDR validation โ”‚ โ”‚ โ”‚ Authorization โ”‚ Role check, resource permissions โ”‚ โ”‚ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ”‚ โ”‚ โ–ผ โ”‚ โ”‚ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚ โ”‚ โ”‚ DB Allocation โ”‚ vm_instance (Stopped), nics, volumes (Allocated) โ”‚ โ”‚ โ”‚ โ”‚ resource_count incremented โ”‚ โ”‚ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ”‚ โ”‚ โ–ผ โ”‚ โ”‚ โ”Œโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ” โ”‚ โ”‚ โ”‚ Submit Job โ”‚ AsyncJobManager creates job-43 โ”‚ โ”‚ โ””โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”ฌโ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”€โ”˜ โ”‚ โ”‚ โ–ผ โ”‚ โ”‚ Return: { jobid: "5dc96a21-....

November 29, 2025 ยท 9 min ยท Daman Arora

CloudStack Networking: VPC vs Isolated Network

Both VPCs and Isolated Networks in Apache CloudStack provide Layer-3 network isolation for user VMs, but they differ in design and use cases. Isolated Network An Isolated Network is a single, flat network with one virtual router. All VMs share the same subnet and routing domain. Key points: One subnet per network (e.g., 10.1.1.0/24). One virtual router handles NAT, DHCP, and firewall rules. No inter-tier routing; traffic is flat. Ideal for single-tier applications or quick deployments....

November 12, 2025 ยท 2 min ยท Daman Arora

CloudStack Snapshots: VM vs Volume

Snapshots in Apache CloudStack can exist at two levels โ€” VM snapshots and volume snapshots โ€” each serving different purposes and stored in different locations. VM Snapshots A VM snapshot is a hypervisor-level checkpoint of an entire virtual machine. It captures the VMโ€™s disk state and optionally its memory, allowing fast rollback to a previous state. Key points: Stored on primary storage. Created quickly without full data copy. Can include memory state for live restore....

November 12, 2025 ยท 2 min ยท Daman Arora

CloudStack Communication Ports Overview

CloudStack components communicate across multiple networks and ports. Port Summary Table Source / Target Port(s) Purpose / Description User โ†’ Management Server 8080 / 8096 CloudStack UI / API Management Server โ†” Management Server 9090 / 8250 Clustered management coordination Management Server โ†” MySQL 3306 Database connection CPVM โ†” Management Server 8250 Console proxy and control communication SSVM โ†” Management Server 8250 Secondary storage operations (template, ISO, snapshot jobs) Virtual Router โ†” Management Server 3922 SSH control and configuration SSVM โ†” Secondary Storage (NFS) 111 / 2049 NFS mount and data transfer CPVM โ†” Hypervisors 22 / 443 Console proxy, authentication, and HTTPS access SSVM โ†” HTTP File Share 80 / 443 Template and ISO downloads User Browser โ†” CPVM 443 / 80 HTTPS console access for VM consoles Management Server โ†” Xen Hosts 22 / 80 / 443 Agent management, API communication Management Server โ†” KVM Hosts 22 Agent setup via SSH Management Server โ†” vCenter (ESXi) 443 vCenter API communication Virtual Router โ†” Secondary Storage 111 / 2049 Template and snapshot copy operations Accessing System VMs (CPVM / SSVM / VR) CloudStack deploys system VMs (such as CPVM, SSVM, and Virtual Routers) with an isolated link-local IP and restricted SSH access....

November 10, 2025 ยท 2 min ยท Daman Arora