Medium
On Medium, anyone can share insightful perspectives, useful knowledge, and life wisdom with the world.
medium.comOn Medium, anyone can share insightful perspectives, useful knowledge, and life wisdom with the world.
medium.com


Dimension gVisor (ateworker-gvisor) MicroVM (ateworker-microvm) -------------------- ------------------------------- -------------------------------------- Isolation boundary User-space Go kernel (Sentry) Hardware KVM + Cloud Hypervisor + + Gofer + seccomp-bpf dedicated guest Linux kernel /data storage tmpfs (in RAM until suspend) virtiofs (host-backed via virtiofsd) Host requirements Standard Linux (x86 or ARM64) x86 host with KVM / nested virt Snapshot contents App RAM + Sentry state Full guest Linux kernel + guest RAM Warm wake-up ~80-190 ms ~400-700 ms (Chrome p95) (120-187 ms) (664 ms on c4) Cold restore 512 MB ~3.3-4.5 s ~7.9-14.3 s Capacity / 24 GiB Up to 120 light / 30 browser / Up to 120 light / 30 browser worker pod 6 live streams tested (12-37% faster CPU at 240-agent load) ### What we tested (and deliberately left out) Our goal was narrow: benchmark GKE 1.37 and Agent Substrate v1.0.1 across both runtimes and all six fourth-generation compute families, leaving agent-framework comparisons out of scope. Quick decoder for the Google Cloud machine names in the charts below: - Prefix: n4 is general-purpose, c4 is compute-optimized. - Suffix: a is Google Axion (ARM64), d is AMD x86, and no suffix is Intel x86. - Pool shape: every test ran on two 8-vCPU / 32 GiB worker nodes in europe-west4, giving two 6 vCPU / 24 GiB worker pods per pool (up to 240 lightweight agents total; the remaining 6 to 8 GiB per node goes to GKE OS, kubelet, atelet, and the small demo proxies). To drive real traffic, we built a lightweight demo agent, an HTTP/MCP database proxy for Cloud SQL, a Vertex AI Model Garden gateway, and a small Web UI using Google Antigravity and Gemini 4 Neon. We ran two different agent harnesses (OpenCode CLI and Antigravity agy) on the same worker pool to check that the platform numbers hold regardless of which runner sits on top. As The Next Platform argued in its piece on evaluating CPU performance for agentic AI, component metrics explain why platforms diverge, while end-to-end multi-step tasks under concurrency show what an agent turn costs and feels like. The ten benchmarks below measure both: warm wakes, cross-node cold restores, end-to-end task cost, snapshot size, live browser video, packing density, harness parity, sleep/wake stability, and parallel CPU scaling. SPONSORED: How to Evaluate CPU Performance for Agentic AI ### The benchmarks #### 1. Multi-workload summary across all 9 setups To compare all five workloads on one chart, we scored each test relative to the best measured setup and combined the five scores with a geometric mean. No single setup wins every column. On gVisor, n4a leads overall (according to our geomean it scores 91 out of 100), closely followed by c4d and c4a. On MicroVM, Intel c4 leads by a wide margin (50 out of 100), while AMD n4d MicroVM sits at the bottom (32 out of 100) due to multi-browser video and cold restore bottlenecks. #### 2. Cross-node cold restore with 512 MB of active memory Warm local cache wakes look great on paper, so we stressed the harder path: forcing a live-browser session holding 512 MB of active memory to miss the local node cache and restore from GCS onto a different worker node. Each actor kept headless Chrome alive, allocated 512 MiB of incompressible random data (os.urandom, no Zstd cheating), suspended to GCS, and forced a cold restore onto a different node. All machine and runtime pairs restored intact with live Chrome surviving 🤯, though moving a heavy session across nodes changes the timing quite a bit compared to same-node hits (see the chart for exact numbers): - Staying on the same node stays fast even at 512 MB (~110 to 250ms on gVisor, ~590 ms on MicroVM). - Moving 512 MB + live Chrome across nodes from GCS takes roughly 3.3 to 4.5s on gVisor, which loads the entire memory image back upfront before answering requests. - On MicroVM, the session answers requests after about 7s, then pulls the remaining RAM in on demand. Total restore time ranges from about 8s on Intel c4 to a whopping over 14s on AMD n4d. If your agents regularly carry 512 MB or more in RAM, how often they wake on the same node versus pulling cold from GCS is what decides how fast the product feels. #### 3. End-to-end agent task cost and the restart-profile baseline This test answered two practical questions: when is restoring a live browser from a Substrate memory snapshot faster than reopening a saved Chrome profile from disk, and what does a complete multi-step agent turn cost in worker VM compute when 8 agents run at the same time? We tested the top four setups (n4a, c4d, and c4 gVisor, plus c4 MicroVM). On the left, we timed how long it takes until Chrome is interactive across four paths: a warm local memory resume, a cold cross-node GCS restore (which happens whenever an idle actor gets evicted or scheduled onto a different worker node), reopening a saved Chrome profile from disk and reloading the page, and a fresh actor boot. On the right, we ran 8 agents in parallel through a full multi-step turn: wake up, call Vertex AI Gemini 4, run a local SQLite/JSON tool, click/read a live Chrome page, and suspend back to GCS. Why bothering with full-memory snapshotting if reopening a saved profile from disk only takes around a second? Two reasons: on a warm hit, gVisor wakes in ~160 ms instead of a full second (about 5 times faster), and memory snapshotting preserves the live running browser as you left it (open tabs, in-progress forms, local app state), while reopening from disk restarts Chrome and reloads the page from scratch… The catch shows up on MicroVM when an actor moves to another node: a cold cross-node GCS restore takes ~4 s, while reopening the saved profile from disk takes ~1.3 s. TL;DR - Both gVisor and MicroVM preserve the live Chrome session in memory across sleep and wake. If an agent fills in a form and waits five minutes for a human to review it, nothing is lost when it wakes up, unlike reopening a saved profile from disk which reloads the page from scratch. - Where the two runtimes split on Chrome is speed versus isolation and heavy-load CPU: do you trust gVisor (battle-tested across Google Cloud for roughly a decade and now in the CNCF) as your sandbox boundary? If yes, full-memory snapshots are basically a free win (~160 ms warm, ~1 s cold cross-node), and gVisor handles light to moderate web apps well. If you want hardware KVM plus Chrome’s native sandbox, or if your agents drive heavy, CPU-hungry websites (see Benchmark 6 where MicroVM pulls ahead under heavy CPU load), MicroVM can be the better fit even with its slower ~4 s cold restores. For the multi-step turn test on the right, external LLM latency sits outside Agent Substrate’s control. In our short benchmark prompt, Vertex AI Gemini 4 took roughly 3 to 4 s per call (varying slightly between runs, which is why c4d shows 7.0 s despite matching n4a on every local step). In real life, a deep research turn or asking a model Generate an SVG of a pelican riding a bicycle can easily take 60 seconds or several minutes. GitHub - simonw/pelican-bicycle: LLM benchmark: Generate an SVG of a pelican riding a bicycle For short turns on MicroVM with per-turn synchronous suspend, wake-and-suspend overhead (~4.1 s, mostly the ~3.4 s suspend) can easily exceed the time spent doing actual tool and browser work (~2.3 s), which is why async or idle-timeout suspend are so important to get right. #### 4. Warm wake-up speed This benchmark measures warm node-local resume latency across all nine setups for both agent-only and live-Chrome sessions. Across all nine setups, gVisor woke live Chrome sessions roughly 3 to 5x faster than MicroVM (~100 to 195 ms vs. ~470 to 725 ms). In repeated tail-latency checks on the top four setups, n4a gVisor was the most consistent (p95 138 ms), while c4 MicroVM ran nearly 5x slower (p95 664 ms). Exact medians and tail numbers for every machine are on the chart. #### 5. Warm wake speed vs. GCS snapshot size Here we compare warm resume latency and compressed GCS snapshot size directly on identical x86 VMs (c4, n4, n4d) where both runtimes run side by side. The snapshot numbers split into two regimes depending on how much state the agent holds in RAM. When an agent is lightweight or mostly idle, gVisor resumes 3 to 5x faster on warm cache and writes roughly 6.6x smaller snapshots (~9 to 31 MB vs. ~69 to 205 MB depending on whether Chrome is open) because no matter how tightly optimized any Linux kernel is, when it’s not there, the snapshot is smaller. If your harness is lightweight, well tuned, and short-context, gVisor is clearly smaller and faster. Once real work piles up in RAM (long context, multiple tools, open files), MicroVM’s fixed guest-kernel footprint becomes a much smaller share of the pie. At 512 MB of active memory, that 6.6x gap shrinks to roughly 10%, putting MicroVM and gVisor far closer in storage size than the idle numbers imply. One detail we did not measure directly: a MicroVM’s guest Linux kernel keeps recently read files cached inside guest memory, and that cache stays warm inside the MicroVM snapshot. When gVisor checkpoints a container, host file cache is evicted. For use cases such as file-heavy coding or research projects, that difference might become greater than people think. Listen to Theo Browne (founder of T3 Code) and why certain clients cough MacOS cough are awful for real agentic workloads: https://medium.com/media/8833853a3da48ce566c39bda2dd41b5e/href #### 6. Live browser video smoothness (FPS) and heavy-load CPU This benchmark tests two active workloads: human-in-the-loop browser screen streaming (Page.startScreencast over HTTP SSE) with 1 browser versus 6 simultaneous browsers on the left, and packed CPU throughput at 240 agents on identical x86 VMs on the right. For live browser streaming, eight of the nine setups stayed smooth at 41 to 60 FPS with six browsers streaming at once. Only AMD n4d MicroVM struggled under multi-browser load, dropping from 54 FPS with one browser down to 22 FPS with six. Under heavy CPU load, the tradeoff flips. When we packed identical x86 VMs to 240 lightweight agents across two worker pods (120 each), MicroVM beat gVisor across every x86 family by 12% to 37% (peaking on n4; see the chart for exact ops/s). That result is gold. In production, everyone tries to squeeze as many active agents as possible onto as few machines as possible. Security, scarce CPU and RAM capacity, and compute spend are the three reasons Agent Substrate exists in the first place; otherwise you would just hand every agent its own dedicated GCE VM and pay the bill. At high density, nested KVM handles CPU contention far better than user-space syscall intercept. The catch, as seen in Benchmarks 2 through 5, is that MicroVM pays for that throughput with much slower resumes. We left gVisor vs. MicroVM /data disk I/O off this chart on purpose. Agent Substrate mounts gVisor's /data directory in memory (tmpfs, persisted to GCS on suspend), whereas MicroVM writes through virtiofs to host storage, so putting RAM-speed writes next to real disk writes on the same axis would be misleading. Measured on its own, MicroVM's virtiofs layer delivered ~380 to 460 MB/s sequential writes and up to ~10k SQLite ops/s. #### 7. Scaling density on one worker pod (1 to 120 agents) Here we measure how warm wake-up latency behaves as we slice the same 6 vCPU / 24 GiB worker pod into smaller and smaller agents, from 1 large agent using the whole pod all the way down to 120 tiny agents per pod (240 across our two-pod pool). The exact CPU, RAM, and actor counts for each step (Test1 through T8) are printed along the bottom of the chart. On gVisor, warm wake latency stays flat around 70 to 150 ms all the way through 30 browser-capable sessions per pod before climbing at 120 agents per pod (as low as ~190 ms on c4a and ~255 ms on n4a). MicroVM climbs much earlier and reaches ~3 to 6 s at full packing density. One hardware nuance from my G4 co-location study applies here too: these 8-vCPU VMs get dedicated CPU cores, not dedicated host cache or memory bandwidth. On larger machine shapes or whole-host nodes with dedicated memory channels, high-density packing numbers can look even better. #### 8. Platform matters more than the agent framework Across both harnesses we tested, the underlying VM family and sandbox runtime drive wake-up speed far more than which agent framework sits on top. To verify that our platform numbers hold across different runners, we ran two separate harnesses on the same worker pool: the open-source opencode CLI (headless, no browser) and Google's Antigravity (agy, keeping a live Chrome browser open), both executing live Vertex AI Gemini 4 turns with zero credentials inside the sandbox. This is not a head-to-head race between OpenCode and Antigravity: keeping live Chrome open naturally adds ~30 to 50 ms to agy wakes. All 18/18 live Gemini 4 turns succeeded with 0 errors across 90 post-turn warm wakes. #### 9. Sleep/wake stability with live Chrome To check whether repeated back-to-back sleep/wake cycles degrade wake-up speed, corrupt disk writes, drop Chrome, or leak memory, we cycled the same live-Chrome session repeatedly across all nine setups (225 cycles total), writing to SQLite and verifying Chrome on every wake. All 225 cycles passed with zero errors: Chrome never restarted, SQLite integrity passed 100%, wake latency stayed flat, and measured memory stayed flat or dipped slightly. This is not a multi-week burn-in, so I would not claim "zero memory leaks forever," yet as a repeated sleep/wake stability check it is clean. #### 10. Parallel CPU throughput and VM cost: Google Axion vs. x86 This benchmark measures sustained multi-agent CPU throughput and worker VM cost when 16 active agents saturate two 8-vCPU worker nodes. Each agent ran continuous JSON parsing and zlib compression over 16 MB of structured data in memory, large enough to spill out of CPU cache and force real memory traffic instead of synthetic micro-loops. An 8-vCPU Google Axion VM (n4a, c4a) gives you 8 physical cores with no hyperthreading, while an 8-vCPU x86 VM shares 4 physical cores across 8 hyperthreads. Going from 1 solo agent to 16 agents in parallel, Axion stayed flat per agent (within ~2 to 3% measurement noise), while every x86 setup slowed down by 1.5x to 1.7x per agent as hyperthreads competed for physical cores. As a result, n4a delivered ~29% more parallel CPU work than the fastest x86 VM (c4d) at ~35% lower worker VM cost. As in Benchmark 3, interactive agent turns spend plenty of time waiting on LLM APIs, so how much of this CPU advantage shows up on your monthly bill depends on how CPU-heavy your agent tools are. ### What about GPUs and CUDA checkpointing? In September I published The Idle Half of a GPU Pod, where we filled the idle 94% of a g4-standard-384 host's 384 vCPUs next to eight RTX PRO 6000 Blackwell GPUs with SPEC CPU 2026 and saw under 1% impact on vLLM inference. At the end of that article, I flagged the exact line where co-location breaks down: The Idle Half of a GPU Pod > Make the reclaimed workload a public Agentic sandbox, or customer containers, or public CI worker and an attacker could run code of their choosing on the same socket as your model. Nothing measured here speaks to that case. Naturally, the first thing I checked with Agent Substrate was whether we could run GPU-backed actors on G4 nodes and snapshot them the same way. Today, the answer is no, and Agent Substrate Issue #779 lays out why plainly: - On gVisor (runsc), taking a full snapshot of an actor holding a live CUDA context fails today with can't save with live nvproxy clients. Supporting GPU suspend/resume requires wiring NVIDIA's cuda-checkpoint binary (which moves GPU VRAM into host RAM and releases the GPU before checkpointing) into the Substrate checkpoint path. Issue #779 shows a manual runsc checkpoint -cuda-checkpoint-path test succeeding on an Nvidia Tesla T4. - On MicroVM, actors do not support GPUs at all yet (tracked separately in Issue #762). Until cuda-checkpoint lands upstream, fourth-generation CPU pools are where deterministic suspend/resume lives, while GPU inference stays separated behind vertex-gateway or a dedicated inference pool. ### In summary: where the edges are and how to choose If you are deciding what to run on GKE with Agent Substrate today, the tradeoffs come down to three choices: - Best all-rounder (default): n4a-standard-8 (Google Axion ARM64) + gVisor. Fast, consistent warm wakes, smooth multi-browser video, strong parallel CPU scaling with 8 physical cores, and the lowest worker VM cost across both CPU-heavy and multi-step agent workloads. - Fastest x86 wake and cold restore: c4d-standard-8 (AMD Turin) + gVisor. Pick this if your container images or tools require x86 and you want the quickest warm wakes and cross-node restores on gVisor. - Hardware KVM isolation required: c4-standard-8 (Intel Granite Rapids) + Cloud Hypervisor MicroVM. Strong packed CPU throughput under heavy multi-agent load and smooth multi-browser video, at the cost of much slower warm and cold resumes. Three practical caveats apply regardless of which VM you pick: 1. Security boundaries can make the runtime choice for you: if your organization or compliance team does not accept software-kernel isolation for untrusted code (or refuses to run Chromium with --no-sandbox), then MicroVM is the only acceptable option, even with its slower resumes. 2. Pulling large snapshots over HTTP from GCS onto a different node is always going to be slower than waking from local node storage. Larger dedicated hosts (with dedicated cache and memory bandwidth) help, and because Google Cloud’s fourth-generation shapes offer very fast ephemeral Local NVMe SSDs and Agent Substrate’s atelet already uses a node-local snapshot cache directory (--snapshot-cache-dir), backing worker nodes with local NVMe is an easy lever for faster node-local restores. Better cross-node or NVMe-tier snapshot caching upstream would help here. 3. Agent Substrate checkpoints process memory and /data on planned suspend or idle timeout; retrying an interrupted task after an unexpected node failure stays an application concern, just like any other distributed workload. ### About AI usage AI agents were used throughout this work. --- On Agent Substrate with gVisor and MicroVM was originally published in Google Cloud - Community on Medium, where people are continuing the conversation by highlighting and responding to this story.Technique ID | Technique | Tooling | Verified detection T1595 | Active Scanning | Nmap | Wazuh Rule 60100 (Level 10) T1110 | Brute Force | Hydra | Wazuh Rules 60122 and 60204 (Level 10) T1003 | OS Credential Dumping | Mimikatz | Sysmon Event ID 10 (LSASS Access, Level 12) T1059.001 | PowerShell Obfuscation | CLI | Sysmon Event ID 1 (Encoded Commands) T1565 | Data Manipulation | Manual edit | Wazuh Rule 550 (FIM integrity alert) During the T1110 test, Hydra fired 64,167 authentication failures over RDP from the Kali node. Rather than flooding analysts with 64,167 separate warnings, Wazuh correlated individual Rule 60122 failures into composite Rule 60204 (Multiple Windows Logon Failures, Level 10). In the T1059.001 test, running a Base64-encoded PowerShell payload bypassed basic signature matching. Sysmon Event ID 1 (Process Creation) captured the full command-line payload before execution completed, giving the SIEM de-obfuscated telemetry that network logs cannot see. Targeting lsass.exe with Mimikatz (T1003) triggered Sysmon Event ID 10 (Process Access) and escalated to a Level 12 Wazuh alert, the highest severity recorded during testing. Finally, modifying c:\confidential\payroll.txt (T1565) fired Wazuh File Integrity Monitoring Rule 550 within seconds, logging SHA1, SHA256, and MD5 checksums alongside file size and the modifying user account. ### Catching and verifying the NIST AC-7 lockout gap Log visibility alone does not stop an attack. Auditing the baseline Windows Server 2025 configuration alongside the 64,167 failed RDP attempts surfaced three governance, risk, and compliance (GRC) control failures: the Account Lockout Threshold was unconfigured (allowing infinite login retries), RDP ingress was open across source ranges, and Process Creation auditing was disabled by default. To close the gap against NIST SP 800–53 AC-7 (Unsuccessful Logon Attempts), I configured the Windows Local Security Policy Account Lockout Policy to trigger a 30-minute lockout after 5 invalid logon attempts, restricted RDP ingress to authorized administrative IP ranges in GCP VPC firewall rules, and locked in Sysmon Event ID 1 and Event ID 10 auditing. Re-running Hydra verified the fix immediately: the brute-force sequence halted after 5 failed attempts, and Wazuh fired Rule 60109 (Account Locked Out), turning a silent vulnerability into an auditable control check. ### Where a lab diverges from production Three architectural adjustments matter before moving this setup into production: First, expose zero public or broad-VPC RDP ingress where possible. Replace raw port 3389 firewall allowlists with Google Cloud Identity-Aware Proxy (IAP) TCP forwarding so administrative sessions require IAM and MFA evaluation before any packet reaches the VM. Second, tune the SwiftOnSecurity Sysmon baseline for your actual workload. High-churn build runners or Windows patching windows generate noisy Event ID 1 streams unless you exclude trusted installer paths. Third, pair a single Wazuh manager with high-availability indexing and a Google Cloud Logging sink so VPC Flow Logs, IAM audit logs, and endpoint telemetry correlate in one retention tier. ### Next step Check your cloud VM baselines for three settings today: verify Account Lockout Threshold enforces a hard cap (such as 5 attempts), confirm Sysmon Event IDs 1 and 10 ship off-host to your SIEM, and test a 5-attempt lockout simulation against your correlation rules to prove the alert fires. Source lab artifacts and forensic report: Cybersecurity-Research-Reports. Drafted with AI-assisted editing from verified lab records in Cybersecurity-Research-Reports. --- Detecting 64,167 Brute-Force Attempts and Living-off-the-Land Attacks in a GCP Wazuh + Sysmon Lab was originally published in Google Cloud - Community on Medium, where people are continuing the conversation by highlighting and responding to this story.