Skip to content

feat: add hyperv-guest-agent extension#1126

Merged
talos-bot merged 1 commit into
siderolabs:mainfrom
rmvangun:feat/hyperv-guest-agent
Jul 10, 2026
Merged

feat: add hyperv-guest-agent extension#1126
talos-bot merged 1 commit into
siderolabs:mainfrom
rmvangun:feat/hyperv-guest-agent

Conversation

@rmvangun

Copy link
Copy Markdown
Contributor

Adds a Hyper-V guest integration extension under guest-agents/. Talos already ships the kernel side (hv_vmbus built in, hv_utils as a module) but nothing runs the user-space daemons, so the Hyper-V host can't see the guest IP and checkpoints come out crash-consistent only. This came up in siderolabs/talos#6435 and discussion siderolabs/talos#12721.

It packages the in-tree Linux tools/hv daemons as two extension services:

  • ext-hyperv-kvp (hv_kvp_daemon) reports the guest IP, hostname and OS to the host, so Get-VMNetworkAdapter gets populated.
  • ext-hyperv-vss (hv_vss_daemon) freezes the /var data partition for application-consistent checkpoints.

A few notes on the build:

  • Compiled statically from the kernel tree at a pinned, checksummed tag, tracked by Renovate in guest-agents/vars.yaml. Same approach as qemu-guest-agent/xen-guest-agent.
  • VSS uses the same host-mount pattern as the zfs extension (rootfsPropagation: shared) so the FIFREEZE lands on the real data partition.
  • Tier extra; I've added myself to MAINTAINERS.md.

One thing documented in the README: KVP's DNS/DHCP reporting and host-to-guest IP injection rely on the distro helper scripts (hv_get_dns_info and friends) that this extension doesn't ship, so those stay empty. IP/hostname/OS reporting doesn't need them.

@talos-bot talos-bot moved this to In Review in Planning Jun 19, 2026
@rmvangun

Copy link
Copy Markdown
Contributor Author

Confirmed working on real Hyper-V — fully validated on a Talos node.

@smira smira left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm, @frezbo your thoughts?

Comment thread guest-agents/hyperv-guest-agent/hyperv-kvp.yaml Outdated
Comment thread guest-agents/hyperv-guest-agent/hyperv-vss.yaml Outdated
Comment thread guest-agents/vars.yaml Outdated
Comment thread guest-agents/hyperv-guest-agent/pkg.yaml Outdated

@frezbo frezbo left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🆒

@github-project-automation github-project-automation Bot moved this from In Review to Approved in Planning Jun 23, 2026
@rmvangun

rmvangun commented Jun 23, 2026

Copy link
Copy Markdown
Contributor Author

Addressed those comments and tested it again on a hyperv workbench.

Comment thread guest-agents/vars.yaml Outdated
TALOS_METAL_AGENT_VERSION: v0.1.5
# hyperv-guest-agent builds hv_kvp_daemon and hv_vss_daemon from the in-tree
# kernel tools/hv sources extracted from the official kernel.org release tarball.
# renovate: datasource=git-tags extractVersion=^v(?<version>.*)$ depName=https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

notes to self:

before merge use the same rule for kernel we use in pkgs and add the renovate lock, so we don't get anything above 6.18

@frezbo frezbo force-pushed the feat/hyperv-guest-agent branch 3 times, most recently from f8085d9 to 5a2fc5a Compare July 10, 2026 06:50
Add a Hyper-V guest integration extension under guest-agents/, providing the
in-tree Linux tools/hv daemons as Talos extension services:

- ext-hyperv-kvp (hv_kvp_daemon): report the guest IP, hostname, and OS to the
  host so Get-VMNetworkAdapter is populated.
- ext-hyperv-vss (hv_vss_daemon): take application-consistent checkpoints by
  freezing the data partition.

The daemons are built statically from the kernel tree, modeled on the
xen-guest-agent extension; VSS reuses the zfs host-mount pattern. Tier extra.

See siderolabs/talos#6435 and siderolabs/talos discussion #12721.

Signed-off-by: Ryan VanGundy <ryan@copia.io>
Signed-off-by: Noel Georgi <git@frezbo.dev>
@frezbo frezbo force-pushed the feat/hyperv-guest-agent branch from 5a2fc5a to 5817a73 Compare July 10, 2026 06:51
@frezbo

frezbo commented Jul 10, 2026

Copy link
Copy Markdown
Member

/m

@talos-bot talos-bot merged commit 5817a73 into siderolabs:main Jul 10, 2026
14 checks passed
@github-project-automation github-project-automation Bot moved this from Approved to Done in Planning Jul 10, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

4 participants