rancher / rke2

https://docs.rke2.io/
Apache License 2.0
1.5k stars 261 forks source link

HostNetwork not working, Service IP and Port not reachable for windows Pods #6386

Open jvnvenu opened 1 month ago

jvnvenu commented 1 month ago

Environmental Info: RKE2 Version: v1.30.1

Node(s) CPU architecture, OS, and Version: Cluster 1 3 Linux nodes - master - RHEL 8 1 windows - agent - Window server 2022 Cni: flannel Cluster 2 3 Linux nodes - master - RHEL 8 2 windows - agent - Window server 2019 Cni: flannel

Describe the bug: I have a application which is hosting a WCF service on a port 9500 and it is running in a windows container. If I try to access the service from another windows container. APITest is test application to access the service. Success - PodIP - Target Port - dotnet .\APITest.dll net.tcp://10.42.16.102:9500/ Success - Node IP - Node Port - dotnet .\APITest.dll net.tcp://10.36.254.81:30815/ Fail - ServiceIP - Service Port - dotnet .\APITest.dll net.tcp://10.43.217.208:9500/

To make it more simple i have used windows PowerShell script command Success - PodIP - Target Port - Test-NetConnection 10.42.16.102 -port 9500 Success - Node IP - Node Port - Test-NetConnection 10.36.254.81 -port 30815 Fail - ServiceIP - Service Port - Test-NetConnection 10.43.217.208 -port 9500

If I do the same hosting a service in linux container and try to access from another windows container all 3 combinations succeeded.

Expected behavior: Success - Accessible

Actual behavior: Failed - Unreachable

jvnvenu commented 1 month ago

Any update on this

jvnvenu commented 1 month ago

one more information hostnetwork mode not working in windows node. it is getting virtual IP even though hostnetwork set as true.