Skip to content

Add LCOWHostNetwork annotation for host network namespace sharing - #2851

Open
takuro-sato wants to merge 3 commits into
microsoft:mainfrom
takuro-sato:hostnetwork-annotation
Open

Add LCOWHostNetwork annotation for host network namespace sharing#2851
takuro-sato wants to merge 3 commits into
microsoft:mainfrom
takuro-sato:hostnetwork-annotation

Conversation

@takuro-sato

Copy link
Copy Markdown
Contributor

This is based on the internal PR: https://msazure.visualstudio.com/ContainerPlatform/_git/Microsoft.hcsshim/pullrequest/15531697

Description

Add a new annotation io.microsoft.virtualmachine.lcow.hostnetwork that configures all containers in a pod to share the UVM's init network namespace instead of creating isolated per-container network namespaces.

Motivation

This is to support ESAN on LCOW.
ESAN sidecar need access to NETLINK_ISCSI sockets, which are network-namespace-scoped. In the default setup, containers run in isolated network namespaces where kernel netlink listeners are not available. This annotation allows the sidecar to communicate with the kernel's scsi_transport_iscsi module and establish iSCSI sessions.

Behavior with the new annotation

Annotation on pod config → all containers (sandbox + workloads) share the UVM's init netns
eth0 stays in init netns and is configured in-place (no MoveInterfaceToNS)
No change to default behavior when annotation is absent

Test

Tested locally on an Azure L1 VM to see if ESAN sidecar can connect to an ESAN instance.

Signed-off-by: Takuro Sato <takurosato@microsoft.com>
Signed-off-by: Takuro Sato <takurosato@microsoft.com>
@takuro-sato
takuro-sato requested a review from a team as a code owner August 3, 2026 17:53
Signed-off-by: Takuro Sato <takurosato@microsoft.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant