Commit f3276962 authored by 吴洲洋's avatar 吴洲洋

update build script

parent 54339cbc
......@@ -7,12 +7,12 @@ vpp:
ueip: 192.169.0.0
ueIPPrefix: 24
snatInter: ens32
snatIP: 192.168.2.239
vppHost: ens40
gtpu_entry: ens38
gtpu_export: ens39
snatIP: 192.168.2.78
vppHost: ens35
gtpu_entry: ens33
gtpu_export: ens34
cpu: 3f
n4:
smf: 192.168.199.18
upf: 192.168.2.239
smf: 192.168.2.63
upf: 192.168.2.78
logSize: 100
No preview for this file type
......@@ -23,26 +23,10 @@ function pre_install(){
function vpp(){
echo "start build vpp"
cd $VPPPATH
clear_all
make pkg-deb-debug
make_package debug
make rebuild
echo "build vpp success"
echo "unpack buptvpp.tar.gz start..."
sudo tar -zxvf $VPPINSTALL/buptvppe.tar.gz -C $VPPINSTALL > /dev/null 2>&1;
echo "unpack buptvpp.tar.gz finished!!!"
sleep 1;
#install
echo "install buptvppe start..."
sudo dpkg -i $VPPINSTALL/build-root/*.deb
sudo systemctl disable vpp;
sudo systemctl stop vpp
#rm install package
sudo rm -rf $VPPINSTALL
clear_all
sleep 1;
echo "install buptvppe finished!!!"
cp $base/src/vppe/build-root/install-vpp_debug-native/vpp/bin/* /usr/bin
cp -r $base/src/vppe/build-root/install-vpp_debug-native/vpp/lib/vpp_plugins /usr/lib/x86_64-linux-gnu
return 0
......
......@@ -11,7 +11,7 @@ arp="$base/src/setuniarp"
config_system=""
VPPPROCESS="vpp"
VPPCMD="/usr/bin/vpp -c /etc/vpp/startup_debug.conf"
VPPCMD="/usr/bin/vpp -c /opt/5gc/startup_debug.conf"
N4PROCESS="main"
N4PATH="$base/install/n4"
......@@ -34,14 +34,13 @@ DPDK_ENTRY=""
DPDK_ENTRY_PCI=""
DPDK_EXPORT_PCI=""
DRIVE=""
CPUNUMBER=""
function init_configure(){
yaml="$1"
# vpp
mkdir -p /opt/5gc
cp -r $configure/template /opt/5gc
$base/plugin/configure -i $yaml -o /opt/5gc
cp /opt/5gc/config_system.sh /opt/5gc
cp /opt/5gc/startup_debug.conf /etc/vpp
cp $base/plugin/yq $current
# arp
UEIP=$($current/yq r $yaml vpp.ip_link.ueip)
......@@ -57,6 +56,7 @@ function init_configure(){
VPPHOST=$($current/yq r $yaml vpp.ip_link.vppHost)
DPDK_EXPORT=$($current/yq r $yaml vpp.ip_link.gtpu_export)
DPDK_ENTRY=$($current/yq r $yaml vpp.ip_link.gtpu_entry)
CPUNUMBER=$($current/yq r $yaml vpp.ip_link.cpu)
rm -rf $current/yq
}
......@@ -66,6 +66,7 @@ function start_vpp() {
install_dpdk_kmod
run_nat
$base/plugin/interreput -i $CPUNUMBER
echo Y | sudo tee /sys/module/vfio/parameters/enable_unsafe_noiommu_mode
$cmd >/dev/null 2>&1 &
sleep 1s
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment