Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Bug] UPF not working in Kubernetes Cluster #551

Closed
Shashank-Girish opened this issue Mar 31, 2024 · 5 comments
Closed

[Bug] UPF not working in Kubernetes Cluster #551

Shashank-Girish opened this issue Mar 31, 2024 · 5 comments

Comments

@Shashank-Girish
Copy link

Shashank-Girish commented Mar 31, 2024

Describe the bug

While trying to replicate the kubernetes cluster to setup 5g core, the upf is stuck on Container Creating for days.

free5gc-v1-free5gc-upf-upf-848cc8fb48-gzhgx             0/1     ContainerCreating   0          20h

I have gpt5g module installed.

To Reproduce

Steps to reproduce the behavior:

kubectl create ns free5gc
git clone https://github.com/Orange-OpenSource/towards5gs-helm.git
cd towards5gs-helm/charts/
helm -n free5gc install free5gc-v1 ./free5gc/
helm -n free5gc install ueransim-v1 ./ueransim/
watch kubectl get pods -n free5gc

Expected behavior

A clear and concise description of what you expected to happen.
The upf pod to run properly.

Environment (please complete the following information):

  • free5GC Version: v3.0.1
  • OS: Ubuntu 20.04
  • Kernel version: [e.g. 5.200.0-0-generic]
  • go version: 1.18.0 linux/amd64

Log File

kubectl describe pods -n free5gc gives the following for upf

Events:
  Type     Reason                  Age                    From               Message
  ----     ------                  ----                   ----               -------
  Normal   Scheduled               12m                    default-scheduler  Successfully assigned free5gc/free5gc-v1-free5gc-upf-upf-848cc8fb48-gzhgx to minikube
  Normal   AddedInterface          11m                    multus             Add eth0 [10.244.120.97/32] from k8s-pod-network
  Normal   AddedInterface          11m                    multus             Add n3 [10.100.50.233/29] from free5gc/n3network-free5gc-v1-free5gc-upf
  Warning  FailedCreatePodSandBox  11m                    kubelet            Failed to create pod sandbox: rpc error: code = Unknown desc = failed to set up sandbox container "9ae74f3a589ba771246a3c5bde9c1a7d3e3ee230f31dcc7eef02d4fbecfbac95" network for pod "free5gc-v1-free5gc-upf-upf-848cc8fb48-gzhgx": networkPlugin cni failed to set up pod "free5gc-v1-free5gc-upf-upf-848cc8fb48-gzhgx_free5gc" network: plugin type="multus" name="multus-cni-network" failed (add): [free5gc/free5gc-v1-free5gc-upf-upf-848cc8fb48-gzhgx/:n6network-free5gc-v1-free5gc-upf]: error adding container to network "n6network-free5gc-v1-free5gc-upf": plugin type="ipvlan" failed (add): failed to lookup master "eth1": Link not found
  Normal   AddedInterface          11m                    multus             Add eth0 [10.244.120.89/32] from k8s-pod-network
  Normal   AddedInterface          11m                    multus             Add n3 [10.100.50.233/29] from free5gc/n3network-free5gc-v1-free5gc-upf

Why is eth1 not found?

@Shashank-Girish Shashank-Girish changed the title [Bugs] [Bug] UPF not working in Kubernetes Cluster Mar 31, 2024
@yccodr
Copy link

yccodr commented Apr 1, 2024

@Shashank-Girish Could you show all the network interfaces on the host?

@Shashank-Girish
Copy link
Author


1: lo: <LOOPBACK,UP,LOWER_UP> mtu 65536 qdisc noqueue state UNKNOWN group default qlen 1000
    link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00
    inet 127.0.0.1/8 scope host lo
       valid_lft forever preferred_lft forever
    inet6 ::1/128 scope host
       valid_lft forever preferred_lft forever
2: eno1: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc fq_codel state UP group default qlen 1000
    link/ether 8c:dc:d4:26:c3:ad brd ff:ff:ff:ff:ff:ff
    altname enp0s25
    inet 10.100.15.92/22 brd 10.100.15.255 scope global dynamic noprefixroute eno1
       valid_lft 12377sec preferred_lft 12377sec
    inet6 fe80::1293:7ee0:4e8d:7e8a/64 scope link noprefixroute
       valid_lft forever preferred_lft forever
4: docker0: <NO-CARRIER,BROADCAST,MULTICAST,UP> mtu 1500 qdisc noqueue state DOWN group default
    link/ether 02:42:23:3a:e7:61 brd ff:ff:ff:ff:ff:ff
    inet 172.17.0.1/16 brd 172.17.255.255 scope global docker0
       valid_lft forever preferred_lft forever
    inet6 fe80::42:23ff:fe3a:e761/64 scope link
       valid_lft forever preferred_lft forever
7: tunl0@NONE: <NOARP> mtu 1480 qdisc noop state DOWN group default qlen 1000
    link/ipip 0.0.0.0 brd 0.0.0.0
22: br-d83832f9db8b: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue state UP group default
    link/ether 02:42:92:f0:e7:52 brd ff:ff:ff:ff:ff:ff
    inet 192.168.49.1/24 brd 192.168.49.255 scope global br-d83832f9db8b
       valid_lft forever preferred_lft forever
    inet6 fe80::42:92ff:fef0:e752/64 scope link
       valid_lft forever preferred_lft forever
28: veth373c929@if27: <BROADCAST,MULTICAST,UP,LOWER_UP> mtu 1500 qdisc noqueue master br-d83832f9db8b state UP group default
    link/ether 1e:ad:01:03:23:e3 brd ff:ff:ff:ff:ff:ff link-netnsid 0
    inet6 fe80::1cad:1ff:fe03:23e3/64 scope link
       valid_lft forever preferred_lft forever
       ```

@lyz508
Copy link

lyz508 commented Apr 1, 2024

Hi, @Shashank-Girish

  • It appears that the eth1 interface is not available on your machine.
  • Please refer to this guide and ensure that the following configurations are properly set:
    1. global.n2network.masterIf
    2. global.n3network.masterIf
    3. global.n4network.masterIf
    4. global.n6network.masterIf
    5. global.n9network.masterIf
    6. global.n6network.subnetIP
    7. global.n6network.gatewayIP
    8. free5gc-upf.upf.n6if.ipAddress

Regards,

@Shashank-Girish
Copy link
Author

Yeah, I had seen this before and tried all combinations of interfaces. However, I don't have a eth0 interface, that seems to work, but eth1 is giving an error.

@yccodr
Copy link

yccodr commented Apr 24, 2024

@Shashank-Girish
Does it goes right? If not, please provides your values.yaml to help us reproduce your problem ;)

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

No branches or pull requests

4 participants