aboutsummaryrefslogtreecommitdiffstats
path: root/vnfs/VESreporting_vFW5.0
diff options
context:
space:
mode:
authorgp2421 <gp2421@att.com>2018-11-16 11:20:14 -0500
committergp2421 <gp2421@att.com>2018-11-30 11:15:54 -0500
commit06c467f6db1b1bd3505c8dbdf36ff0aae4beab7e (patch)
tree28baa04ca78435f9036d19854cd1ed2c7aac2187 /vnfs/VESreporting_vFW5.0
parentb19a7a7cae93ade0a9ebe23a638e42948b740ac3 (diff)
resubmit - 2 collector support-include readme ..
Issue-ID: CERT-16 Change-Id: If75efb06b6722ea26319e892bf1449207048ec9c Signed-off-by: gp2421 <gp2421@att.com>
Diffstat (limited to 'vnfs/VESreporting_vFW5.0')
-rwxr-xr-xvnfs/VESreporting_vFW5.0/go-client.sh1
-rw-r--r--vnfs/VESreporting_vFW5.0/vpp_measurement_reporter.c30
2 files changed, 22 insertions, 9 deletions
diff --git a/vnfs/VESreporting_vFW5.0/go-client.sh b/vnfs/VESreporting_vFW5.0/go-client.sh
index 116f8905..3b4b49d3 100755
--- a/vnfs/VESreporting_vFW5.0/go-client.sh
+++ b/vnfs/VESreporting_vFW5.0/go-client.sh
@@ -4,3 +4,4 @@ export LD_LIBRARY_PATH="/opt/VES/evel/evel-library/libs/x86_64/"
DCAE_COLLECTOR_IP=$(cat /opt/config/dcae_collector_ip.txt)
DCAE_COLLECTOR_PORT=$(cat /opt/config/dcae_collector_port.txt)
./vpp_measurement_reporter $DCAE_COLLECTOR_IP $DCAE_COLLECTOR_PORT eth1
+#./vpp_measurement_reporter 127.0.0.1 30000 127.0.0.1 31000 eth1
diff --git a/vnfs/VESreporting_vFW5.0/vpp_measurement_reporter.c b/vnfs/VESreporting_vFW5.0/vpp_measurement_reporter.c
index 6f6a7c04..7cf0414d 100644
--- a/vnfs/VESreporting_vFW5.0/vpp_measurement_reporter.c
+++ b/vnfs/VESreporting_vFW5.0/vpp_measurement_reporter.c
@@ -171,17 +171,30 @@ int main(int argc, char** argv)
char* fqdn = argv[1];
int port = atoi(argv[2]);
char* vnic = argv[3];
+ char* fqdn2 = NULL;
+ int port2 = 0;
+
MEASUREMENT_VNIC_PERFORMANCE * vnic_performance = NULL;
//struct timeval tv_start;
+ if(argc == 6)
+ {
+ fqdn2 = argv[3];
+ port2 = atoi(argv[4]);
+ vnic = argv[5];
+ }
+
printf("\nVector Packet Processing (VPP) measurement collection\n");
fflush(stdout);
- if (argc != 4)
+ if (!((argc == 6) || (argc == 4)))
{
- fprintf(stderr, "Usage: %s <FQDN>|<IP address> <port> <interface>\n", argv[0]);
+ fprintf(stderr, "Usage: %s <FQDN>|<IP address> <port> <FQDN>|<IP address> <port> <interface> \n", argv[0]);
+ fprintf(stderr, "OR\n");
+ fprintf(stderr, "Usage: %s <FQDN>|<IP address> <port> <interface> \n", argv[0]);
exit(-1);
}
+
srand(time(NULL));
/**************************************************************************/
@@ -189,23 +202,22 @@ int main(int argc, char** argv)
/**************************************************************************/
if(evel_initialize(fqdn, /* FQDN */
port, /* Port */
- "", /* Backup FQDN */
- 5555, /* Backup Port */
+ fqdn2, /* Backup FQDN */
+ port2, /* Backup port */
NULL, /* optional path */
NULL, /* optional topic */
100, /* Ring Buffer size */
0, /* HTTPS? */
- 0, /* Active mode */
NULL, /* cert file */
NULL, /* key file */
NULL, /* ca info */
NULL, /* ca file */
0, /* verify peer */
0, /* verify host */
- "", /* Username */
- "", /* Password */
- "", /* Backup Username */
- "", /* Backup Password */
+ "sample1", /* Username */
+ "sample1", /* Password */
+ "sample1", /* Username2 */
+ "sample1", /* Password2 */
NULL, /* Source ip */
NULL, /* Backup Source IP */
EVEL_SOURCE_VIRTUAL_MACHINE, /* Source type */