Closed Thanasislt closed 3 months ago
Hi @Thanasislt
The entrypoint of the UPF container has these two instructions:
Can you check if both are properly configured?
BR, Álvaro
This produces the UPF entry point configmap, right? I think it is properly configured:
echo "Executing k8s customized entrypoint.sh"
echo "Creating net device ogstun"
if grep "ogstun" /proc/net/dev > /dev/null; then
echo "Warnin: Net device ogstun already exists! may you need to set createDev: false";
exit 1
fi
ip tuntap add name ogstun mode tun
ip link set ogstun up
echo "Setting IP 10.45.0.1/16 to device ogstun"
ip addr add 10.45.0.1/16 dev ogstun;
sysctl -w net.ipv4.ip_forward=1;
echo "Enable NAT for 10.45.0.0/16 and device ogstun"
iptables -t nat -A POSTROUTING -s 10.45.0.0/16 ! -o ogstun -j MASQUERADE;
Mmm, I think so.
Have you tried to capture traffic in ogstun and eth0 interfaces? This can be helpful for debugging what is happening. If you want, you can attach the pcaps, and I'll try to look at them.
BR, Álvaro
Hello, I have attached the UPf pcap files here: upf-eth0_ogstun.zip. Seems like SNAT is not working between ogstun and eth0. I expected traffic to be NAT-ed by ogstun and send via eth0 to the internet. I pinged 192.168.50.1 (Lab gateway) and curl google from eth0 and ogstun.
Well, I believe the problem is not related with the Helm Charts directly. Could be a problem with Cilium and NAT? On the other hand, I would suggest you overriding the UPF entrypoint, test every single line and see if everything is working properly.
BR, Álvaro
Steps to reproduce
We have set up Open5GS in our Kubernetes cluster, but we are encountering an issue where the UPF pod is unable to ping from the
ogstun
interface to the internet. When attempting to ping through interfaceeth0
traffic is forwarded with no issues and ping works as expected. We have followed the documentation and setup guides, but the connectivity issue persists. Please note that in our case we increased the O5GS version from 2.7.0 to 2.7.1, though this caused no crashes to the pods. We have validated the pod interfaces through theip command
. Environment:ip a output:
ip route output:
iptables -S output:
Logs
No response
Expected behaviour
ping -I eth0 x.y.z.w
andping -I ogstun x.y.z.w
should ping the IP address succesfully.successfullyObserved Behaviour
eth0
forwards packets correctly, thoughogstun
does not.