NETWORK ADMINISTRATIONSWindows server

5. Windows Server 2019 Container Hyper-V isolation with Transparent

https://docs.microsoft.com/en-us/virtualization/windowscontainers/manage-containers/hyperv-container
Process Isolation – deesn’t support transparent network
Hyper-V isolation – requires Nested Virtualization – VT-x

Nested Virtualization
Virtual Machine in Virtual Machine

https://docs.microsoft.com/en-us/virtualization/hyper-v-on-windows/user-guide/nested-virtualization

$(Get-VMProcessor -VMName container-win).ExposeVirtualizationExtensions
Set-VMProcessor -VMName Container-Win -ExposeVirtualizationExtensions $true

docker run -it –isolation=hyperv mcr.microsoft.com/windows/nanoserver:1809 cmd
docker run -it mcr.microsoft.com/windows/nanoserver:1809 cmd

*without hyper-v, hyper-v isolation is not working
docker: Error response from daemon: hcsshim::CreateComputeSystem a1a939079332e0c5ed6a0f2ef2b1c71b8a93f03aca73fcb1fddc4ebd3d8f4e23: The request is not supported.

To crate transparent network
https://docs.microsoft.com/en-us/virtualization/windowscontainers/container-networking/advanced

docker network create -d transparent transparent

*Error response from daemon: failed during hnsCallRawResponse: hnsCall failed in Win32: An adapter was not found. (0x803b0006)

docker system prune –all
hnsdiag list networks
hnsdiag delete networks 9BDA2B13-FED4-4EF9-A271-AC689D1EC0E8

unInstall-Package -Name docker -ProviderName DockerMsftProvider
unInstall-Module -Name DockerMsftProvider -Repository PSGallery

docker run -it –network=”Microsoft Hyper-V Network Adapter – Virtual Switch” –isolation=hyperv mcr.microsoft.com/windows/nanoserver:1809 cmd

Get-VMNetworkAdapter -vmname container-win | Set-VMNetworkAdapter -MacAddressSpoofing On

source

windows server

Alice AUSTIN

Alice AUSTIN is studying Cisco Systems Engineering. He has passion with both hardware and software and writes articles and reviews for many IT websites.

Leave a Reply

Your email address will not be published. Required fields are marked *