diff options
Diffstat (limited to 'vnfs/vLB')
-rw-r--r-- | vnfs/vLB/scripts/add_dns.sh | 2 | ||||
-rw-r--r-- | vnfs/vLB/scripts/remove_dns.sh | 2 | ||||
-rw-r--r-- | vnfs/vLB/scripts/v_dns_install.sh | 5 | ||||
-rwxr-xr-x | vnfs/vLB/scripts/v_lb_init.sh | 2 | ||||
-rw-r--r-- | vnfs/vLB/scripts/v_lb_install.sh | 19 | ||||
-rw-r--r-- | vnfs/vLB/scripts/v_packetgen_install.sh | 11 | ||||
-rw-r--r-- | vnfs/vLB/scripts/vdnspacketgen_change_streams_ports.sh | 2 |
7 files changed, 24 insertions, 19 deletions
diff --git a/vnfs/vLB/scripts/add_dns.sh b/vnfs/vLB/scripts/add_dns.sh index 3574e085..342679d0 100644 --- a/vnfs/vLB/scripts/add_dns.sh +++ b/vnfs/vLB/scripts/add_dns.sh @@ -17,7 +17,7 @@ vppctl set int ip address $GRE $GRE_IPADDR"/32" vppctl set int state $GRE up # Update the number of vDNSs currently active -FD="/opt/VES/code/evel_training/VESreporting/active_dns.txt" +FD="/opt/VES/evel/evel-library/code/VESreporting/active_dns.txt" CURR_DNS=$(cat $FD) let CURR_DNS=$CURR_DNS+1 echo $CURR_DNS > $FD
\ No newline at end of file diff --git a/vnfs/vLB/scripts/remove_dns.sh b/vnfs/vLB/scripts/remove_dns.sh index f400aa0f..33d43a6b 100644 --- a/vnfs/vLB/scripts/remove_dns.sh +++ b/vnfs/vLB/scripts/remove_dns.sh @@ -14,7 +14,7 @@ vppctl lb as $IP_TO_PKTGEN_NET"/32" $DNS_IPADDR del vppctl create gre tunnel src $IP_TO_DNS_NET dst $DNS_IPADDR del # Update the number of vDNSs currently active -FD="/opt/VES/code/evel_training/VESreporting/active_dns.txt" +FD="/opt/VES/evel/evel-library/code/VESreporting/active_dns.txt" CURR_DNS=$(cat $FD) let CURR_DNS=$CURR_DNS-1 if [[ $CURR_DNS -lt 0 ]] diff --git a/vnfs/vLB/scripts/v_dns_install.sh b/vnfs/vLB/scripts/v_dns_install.sh index 84d7a017..91cce8ab 100644 --- a/vnfs/vLB/scripts/v_dns_install.sh +++ b/vnfs/vLB/scripts/v_dns_install.sh @@ -45,9 +45,10 @@ then fi # Download required dependencies -add-apt-repository -y ppa:openjdk-r/ppa +echo "deb http://ppa.launchpad.net/openjdk-r/ppa/ubuntu $(lsb_release -c -s) main" >> /etc/apt/sources.list.d/java.list +echo "deb-src http://ppa.launchpad.net/openjdk-r/ppa/ubuntu $(lsb_release -c -s) main" >> /etc/apt/sources.list.d/java.list apt-get update -apt-get install -y wget openjdk-8-jdk bind9 bind9utils bind9-doc apt-transport-https ca-certificates +apt-get install --allow-unauthenticated -y wget openjdk-8-jdk bind9 bind9utils bind9-doc apt-transport-https ca-certificates sleep 1 # Download vDNS demo code for DNS Server diff --git a/vnfs/vLB/scripts/v_lb_init.sh b/vnfs/vLB/scripts/v_lb_init.sh index 9223e043..1bad1722 100755 --- a/vnfs/vLB/scripts/v_lb_init.sh +++ b/vnfs/vLB/scripts/v_lb_init.sh @@ -79,6 +79,6 @@ cd /opt/FDserver ./dnsmembership.sh &>/dev/null &disown # Start VES client -cd /opt/VES/code/evel_training/VESreporting/ +cd /opt/VES/evel/evel-library/code/VESreporting/ echo 0 > active_dns.txt ./go-client.sh &>/dev/null &disown
\ No newline at end of file diff --git a/vnfs/vLB/scripts/v_lb_install.sh b/vnfs/vLB/scripts/v_lb_install.sh index 89869a0a..052ebb6e 100644 --- a/vnfs/vLB/scripts/v_lb_install.sh +++ b/vnfs/vLB/scripts/v_lb_install.sh @@ -54,9 +54,10 @@ then fi # Download required dependencies -add-apt-repository -y ppa:openjdk-r/ppa +echo "deb http://ppa.launchpad.net/openjdk-r/ppa/ubuntu $(lsb_release -c -s) main" >> /etc/apt/sources.list.d/java.list +echo "deb-src http://ppa.launchpad.net/openjdk-r/ppa/ubuntu $(lsb_release -c -s) main" >> /etc/apt/sources.list.d/java.list apt-get update -apt-get install -y make gcc wget openjdk-8-jdk bridge-utils libcurl4-openssl-dev apt-transport-https ca-certificates +apt-get install --allow-unauthenticated -y make gcc wget openjdk-8-jdk bridge-utils libcurl4-openssl-dev apt-transport-https ca-certificates sleep 1 # Download vLB demo code for load balancer @@ -69,15 +70,15 @@ wget $REPO_URL_BLOB/org.onap.demo/vnfs/vlb/$INSTALL_SCRIPT_VERSION/dnsmembership wget $REPO_URL_BLOB/org.onap.demo/vnfs/vlb/$INSTALL_SCRIPT_VERSION/add_dns.sh wget $REPO_URL_BLOB/org.onap.demo/vnfs/vlb/$INSTALL_SCRIPT_VERSION/remove_dns.sh wget $REPO_URL_ARTIFACTS/org/onap/demo/vnf/vlb/dns-manager/$DEMO_ARTIFACTS_VERSION/dns-manager-$DEMO_ARTIFACTS_VERSION.jar -wget $REPO_URL_ARTIFACTS/org/onap/demo/vnf/ves/ves/$DEMO_ARTIFACTS_VERSION/ves-$DEMO_ARTIFACTS_VERSION-demo.tar.gz -wget $REPO_URL_ARTIFACTS/org/onap/demo/vnf/ves/ves_vlb_reporting/$DEMO_ARTIFACTS_VERSION/ves_vlb_reporting-$DEMO_ARTIFACTS_VERSION-demo.tar.gz +wget $REPO_URL_ARTIFACTS/org/onap/demo/vnf/ves5/ves/$DEMO_ARTIFACTS_VERSION/ves-$DEMO_ARTIFACTS_VERSION-demo.tar.gz +wget $REPO_URL_ARTIFACTS/org/onap/demo/vnf/ves5/ves_vlb_reporting/$DEMO_ARTIFACTS_VERSION/ves_vlb_reporting-$DEMO_ARTIFACTS_VERSION-demo.tar.gz -tar -zxvf ves-$DEMO_ARTIFACTS_VERSION-demo.tar.gz +tar -zmxvf ves-$DEMO_ARTIFACTS_VERSION-demo.tar.gz mv ves-$DEMO_ARTIFACTS_VERSION VES -tar -zxvf ves_vlb_reporting-$DEMO_ARTIFACTS_VERSION-demo.tar.gz +tar -zmxvf ves_vlb_reporting-$DEMO_ARTIFACTS_VERSION-demo.tar.gz mv ves_vlb_reporting-$DEMO_ARTIFACTS_VERSION VESreporting_vLB -mv VESreporting_vLB /opt/VES/code/evel_training/VESreporting +mv VESreporting_vLB /opt/VES/evel/evel-library/code/VESreporting mv dns-manager-$DEMO_ARTIFACTS_VERSION.jar /opt/FDserver/dns-manager-$DEMO_ARTIFACTS_VERSION.jar mv dnsmembership.sh /opt/FDserver/dnsmembership.sh mv add_dns.sh /opt/FDserver/add_dns.sh @@ -86,7 +87,7 @@ rm *.tar.gz chmod +x v_lb_init.sh chmod +x vlb.sh -chmod +x /opt/VES/code/evel_training/VESreporting/go-client.sh +chmod +x /opt/VES/evel/evel-library/code/VESreporting/go-client.sh chmod +x /opt/FDserver/dnsmembership.sh chmod +x /opt/FDserver/add_dns.sh chmod +x /opt/FDserver/remove_dns.sh @@ -101,7 +102,7 @@ apt-get install -y vpp vpp-dpdk-dkms vpp-lib vpp-dbg vpp-plugins vpp-dev sleep 1 # Install VES -cd /opt/VES/bldjobs/ +cd /opt/VES/evel/evel-library/bldjobs/ make clean make sleep 1 diff --git a/vnfs/vLB/scripts/v_packetgen_install.sh b/vnfs/vLB/scripts/v_packetgen_install.sh index 6ac62737..ca2957a7 100644 --- a/vnfs/vLB/scripts/v_packetgen_install.sh +++ b/vnfs/vLB/scripts/v_packetgen_install.sh @@ -45,9 +45,10 @@ then fi # Download required dependencies -add-apt-repository -y ppa:openjdk-r/ppa +echo "deb http://ppa.launchpad.net/openjdk-r/ppa/ubuntu $(lsb_release -c -s) main" >> /etc/apt/sources.list.d/java.list +echo "deb-src http://ppa.launchpad.net/openjdk-r/ppa/ubuntu $(lsb_release -c -s) main" >> /etc/apt/sources.list.d/java.list apt-get update -apt-get install -y make wget openjdk-8-jdk gcc libcurl4-openssl-dev python-pip bridge-utils apt-transport-https ca-certificates +apt-get install --allow-unauthenticated -y make wget openjdk-8-jdk gcc libcurl4-openssl-dev python-pip bridge-utils apt-transport-https ca-certificates pip install jsonschema # Download vFirewall demo code for packet generator @@ -58,8 +59,7 @@ wget $REPO_URL_BLOB/org.onap.demo/vnfs/vlb/$INSTALL_SCRIPT_VERSION/run_streams_d wget $REPO_URL_BLOB/org.onap.demo/vnfs/vlb/$INSTALL_SCRIPT_VERSION/vdnspacketgen_change_streams_ports.sh wget $REPO_URL_ARTIFACTS/org/onap/demo/vnf/vlb/vlb_dns_streams/$DEMO_ARTIFACTS_VERSION/vlb_dns_streams-$DEMO_ARTIFACTS_VERSION-demo.tar.gz -tar -zxvf vpp.tar.gz -tar -zxvf vlb_dns_streams-$DEMO_ARTIFACTS_VERSION-demo.tar.gz +tar -zmxvf vlb_dns_streams-$DEMO_ARTIFACTS_VERSION-demo.tar.gz mv vlb_dns_streams-$DEMO_ARTIFACTS_VERSION dns_streams rm *.tar.gz chmod +x v_packetgen_init.sh @@ -93,4 +93,7 @@ then reboot fi +# Install a cron job that restart streams every minute. This allows to map streams to different vDNSs when we scale out the VNF +echo "* * * * * /opt/vdnspacketgen_change_streams_ports.sh" | crontab + ./v_packetgen_init.sh diff --git a/vnfs/vLB/scripts/vdnspacketgen_change_streams_ports.sh b/vnfs/vLB/scripts/vdnspacketgen_change_streams_ports.sh index adfc1f1e..e4723880 100644 --- a/vnfs/vLB/scripts/vdnspacketgen_change_streams_ports.sh +++ b/vnfs/vLB/scripts/vdnspacketgen_change_streams_ports.sh @@ -16,7 +16,7 @@ vppctl pac del dns10 #Update destination (vLB) IP VLB_IPADDR=$(cat /opt/config/vlb_ipaddr.txt) -IPADDR1=$(ifconfig br0 | grep "inet addr" | tr -s ' ' | cut -d' ' -f3 | cut -d':' -f2) +IPADDR1=$(cat /opt/config/local_private_ipaddr.txt) sed -i -e "0,/UDP/ s/UDP:.*/UDP: "$IPADDR1" -> "$VLB_IPADDR"/" /opt/dns_streams/stream_dns1 sed -i -e "0,/UDP/ s/UDP:.*/UDP: "$IPADDR1" -> "$VLB_IPADDR"/" /opt/dns_streams/stream_dns2 sed -i -e "0,/UDP/ s/UDP:.*/UDP: "$IPADDR1" -> "$VLB_IPADDR"/" /opt/dns_streams/stream_dns3 |