travelping / vpp

5G User Plane Function (UPF) based on VPP

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

vpp crashing with worker configuration

michaelraskansky opened this issue · comments

Hello,
on branch feature/2005/upf when starting VPP with the cpu section configured i.e

cpu { workers 1 }

The node crashes right after it is started.
The crash seams to be caused by upf_proxy.c initialization called by upf_init function in upf.c.
I worked around this by explicitly enabling upf proxy via a vli cli command after the vpp instance was started in init.conf.

I have a couple of questions:

  1. What exactly does the upf_proxy do?
  2. Must it be active for the UPF to work correctly?

Best regards

We have not really tested the current version with multiple CPUs/threads. Out focus is mostly on getting the functionality working first.

I have a couple of questions:

  1. What exactly does the upf_proxy do?

When doing ADF on connection content (HTTP URL or TLS SNI) we need to first accept the connection from the UE and later build a connection to final destination. upf_proxy is doing that.

  1. Must it be active for the UPF to work correctly?

Only when you need content based ADF rules.

Thanks.

should i create a pull request with the workaround I implemented?

should i create a pull request with the workaround I implemented?

Yes, please!

Contributions are always welcome.

Could you also share the full config (init.conf and startup.conf) that causes the crash, please?

Hello, the only section that was added was in startup.conf
the cpu section

startup.conf

unix {
  nodaemon
  log /tmp/vpp.log
  full-coredump
  gid vpp
  interactive
  cli-listen localhost:5002
  exec init.conf
}

api-trace {
  on
}

api-segment {
  gid vpp
}
cpu {
  workers 1
}
plugins {
    path /usr/src/vpp/build-root/install-vpp-native/vpp/lib/vpp_plugins/
    plugin dpdk_plugin.so { disable }
    plugin gtpu_plugin.so { disable }
    plugin upf_plugin.so { enable }
}

init.conf is the same

ip table add 1
ip table add 2
ip6 table add 1
ip6 table add 2

create host-interface name ens224
set interface mac address host-ens224 00:0c:29:46:1f:53
set interface mtu 1500 host-ens224
set interface ip table host-ens224 1
set interface ip6 table host-ens224 1
set interface ip address host-ens224 172.20.16.105/24
set interface state host-ens224 up

create host-interface name ens161
set interface mac address host-ens161 00:50:56:86:ed:f9
set interface mtu 1500 host-ens161
set interface ip table host-ens161 2
set interface ip6 table host-ens161 2
set interface ip address host-ens161 172.20.16.106/24
set interface state host-ens161 up

create host-interface name sxb-u
set interface mac address host-sxb-u 02:fe:f5:6f:45:72
set int ip address host-sxb-u 172.21.16.1/24
set int state host-sxb-u up

ip route add 0.0.0.0/0 table 2 via 172.20.16.1 host-ens161

upf pfcp endpoint ip 172.21.16.1 vrf 0

upf nwi name cp vrf 0
upf nwi name epc vrf 1
upf nwi name sgi vrf 2

upf gtpu endpoint ip 172.21.16.1 nwi cp teid 0x80000000/2
upf gtpu endpoint ip 172.20.16.105 nwi epc teid 0x80000000/2

create upf application proxy name Gold
upf application Gold rule 1 add l7 regex ^http://172.20.16.75/Gold/.*$
upf application Gold rule 2 add l7 regex ^https://dmock/.*$
upf application Gold rule 3 add l7 regex ^http://172.20.16.75/Both/.*$

create upf application proxy name Silver
upf application Silver rule 1 add l7 regex ^http://web_server/Silver/.*$
upf application Silver rule 2 add l7 regex ^http://172.20.16.75/Both/.*$

# trace add af-packet-input 100

created a PR with the workaround

#73