Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: nexus.onap.org to nexus3.onap.org

...

The below steps covers manual setup of DCAE VM’s and DCAE service components.

VESCollector

 


DCAE VES Collector can be configured on VM with ubuntu-16.04 image (m1.small should suffice if this is only service) and 20Gb cinder storage

...

sudo docker login -u docker -p docker nexusnexus3.onap.org:10001
       sudo docker pull nexusnexus3.onap.org:10001/onap/org.onap.dcaegen2.collectors.ves.vescollector:v1.1.0

...

sudo docker run -d --name vescollector -p 8080:8080/tcp -p 8443:8443/tcp -P -e DMAAPHOST='<dmaap IP>' nexusnexus3.onap.org:10001/onap/org.onap.dcaegen2.collectors.ves.vescollector:v1.1.10

                Note:  Change the dmaaphost to required DMAAP ip. To change the dmaap information for a running container,  stop the active container and rerun above command changing the dmaap IP.

...

Code Block
languagexml
titleinit.sh
collapsetrue
#!/bin/sh
sudo docker ps | grep "vescollector"
if [ $? -ne 0 ]; then
        sudo docker login -u docker -p docker nexusnexus3.onap.org:10001
        sudo docker pull nexusnexus3.onap.org:10001/onap/org.onap.dcaegen2.collectors.ves.vescollector:1.1
        sudo docker rm -f vescollector
        echo "Collector process not running - $(date)" >> /home/ubuntu/startuplog
        sudo docker run -d --name vescollector -p 8080:8080/tcp -p 8443:8443/tcp -P -e DMAAPHOST='10.12.25.96' nexusnexus3.onap.org:10001/onap/org.onap.dcaegen2.collectors.ves.vescollector:v1.1.10
else
        echo "Collector process running - $(date)" >> /home/ubuntu/startuplog
fi

...

	sudo  update-rc.d init.sh start 2

 


ThresholdCrossingAnalysis (TCA/CDAP)

...

Code Block
languagebash
titlereload-tca.sh
collapsetrue
#!/bin/sh
TCA_JAR=dcae-analytics-cdap-tca-2.0.10.jar
rm -f /home/ubuntu/$TCA_JAR
cd /home/ubuntu/
wget https://nexusnexus3.onap.org/service/local/repositories/stagingreleases/content/org/onap/dcaegen2/analytics/tca/dcae-analytics-cdap-tca/2.0.10/$TCA_JAR
if [ $? -eq 0 ]; then
        if [ -f /home/ubuntu/$TCA_JAR ]; then
                echo "Restarting TCA CDAP application using $TCA_JAR artifact"
        else
                echo "ERROR: $TCA_JAR missing"
                exit 1
        fi
else
        echo "ERROR: $TCA_JAR not found in nexus"
        exit 1
fi
# stop programs
curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRPublisherWorker/stop
curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRSubscriberWorker/stop
curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/flows/TCAVESCollectorFlow/stop
# delete application
curl -X DELETE http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca
# delete artifact
curl -X DELETE http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/artifacts/dcae-analytics-cdap-tca/versions/2.0.1
# load artifact
curl -X POST --data-binary @/home/ubuntu/$TCA_JAR http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/artifacts/dcae-analytics-cdap-tca
# create app
curl -X PUT -d @/home/ubuntu/tca_app_config.json http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca
# load preferences
curl -X PUT -d @/home/ubuntu/tca_app_preferences.json http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/preferences
# start programs
curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRPublisherWorker/start
curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRSubscriberWorker/start
curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/flows/TCAVESCollectorFlow/start
echo
# get status of programs
curl http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRPublisherWorker/status
curl http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRSubscriberWorker/status
curl http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/flows/TCAVESCollectorFlow/status
echo

...

Code Block
languagebash
titleinit.sh
collapsetrue
#!/bin/sh
#docker run -d --name cdap-sdk -p 11011:11011 -p 11015:11015 caskdata/cdap-standalone:4.1.2
sudo docker restart cdap-sdk-2
sleep 30
# start program
curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRPublisherWorker/start
curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/workers/TCADMaaPMRSubscriberWorker/start
curl -X POST http://localhost:11015/v3/namespaces/cdap_tca_hi_lo/apps/dcae-tca/flows/TCAVESCollectorFlow/start

...


This script was invoked via VM init script (rc.d).

...