blob: 13c941a791b5549a86dd5d31c9fe02c5f973a330 [file] [log] [blame]
tierno7edb6752016-03-21 17:37:52 +01001#!/bin/bash
2
3##
4# Copyright 2015 Telefónica Investigación y Desarrollo, S.A.U.
5# This file is part of openmano
6# All Rights Reserved.
7#
8# Licensed under the Apache License, Version 2.0 (the "License"); you may
9# not use this file except in compliance with the License. You may obtain
10# a copy of the License at
11#
12# http://www.apache.org/licenses/LICENSE-2.0
13#
14# Unless required by applicable law or agreed to in writing, software
15# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT
16# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the
17# License for the specific language governing permissions and limitations
18# under the License.
19#
20# For those usages not covered by the Apache License, Version 2.0 please
21# contact with: nfvlabs@tid.es
22##
23
24#It generates a report for debugging
25
26DIRNAME=$(readlink -f ${BASH_SOURCE[0]})
27DIRNAME=$(dirname $DIRNAME )
garciadeblas4b6216b2017-04-20 16:41:52 +020028OMCLIENT=openmano
tierno7edb6752016-03-21 17:37:52 +010029
30#get screen log files at the beginning
31echo
32echo "-------------------------------"
33echo "log files"
34echo "-------------------------------"
35echo "-------------------------------"
36echo "OPENMANO"
37echo "-------------------------------"
garciadeblas4b6216b2017-04-20 16:41:52 +020038echo "cat /var/log/osm/openmano.log*"
39cat /var/log/osm/openmano.log*
tierno7edb6752016-03-21 17:37:52 +010040echo
41echo "-------------------------------"
42echo
43
44#get version
45echo
46echo "-------------------------------"
47echo "version"
48echo "-------------------------------"
49echo "-------------------------------"
50echo "OPENMANO"
51echo "-------------------------------"
garciadeblas4b6216b2017-04-20 16:41:52 +020052echo "openmanod --version"
53openmanod --version
tierno7edb6752016-03-21 17:37:52 +010054echo
55echo "-------------------------------"
56echo
57
58#get configuration files
59echo "-------------------------------"
60echo "Configuration files"
61echo "-------------------------------"
62echo "-------------------------------"
63echo "OPENMANO"
64echo "-------------------------------"
garciadeblas4b6216b2017-04-20 16:41:52 +020065echo "cat /etc/osm/openmanod.cfg"
66cat /etc/osm/openmanod.cfg
tierno7edb6752016-03-21 17:37:52 +010067echo "-------------------------------"
68echo
69
70#get list of items
71for verbose in "" "-vvv"
72do
73 echo "-------------------------------"
74 echo "OPENMANO$verbose"
75 echo "-------------------------------"
76 echo "$OMCLIENT config $verbose"
77 $OMCLIENT config
78 echo "-------------------------------"
79 echo "$OMCLIENT tenant-list $verbose"
80 $OMCLIENT tenant-list $verbose
81 echo "-------------------------------"
82 echo "$OMCLIENT datacenter-list --all"
83 $OMCLIENT datacenter-list --all
84 echo "-------------------------------"
85 echo "$OMCLIENT datacenter-list $verbose"
86 $OMCLIENT datacenter-list $verbose
87 echo "-------------------------------"
88 dclist=`$OMCLIENT datacenter-list |awk '{print $1}'`
89 for dc in $dclist; do
90 echo "$OMCLIENT datacenter-net-list $dc $verbose"
91 $OMCLIENT datacenter-net-list $dc $verbose
92 echo "-------------------------------"
93 done
94 echo "$OMCLIENT vnf-list $verbose"
95 $OMCLIENT vnf-list $verbose
96 echo "-------------------------------"
97 vnflist=`$OMCLIENT vnf-list |awk '$1!="No" {print $1}'`
98 for vnf in $vnflist; do
99 echo "$OMCLIENT vnf-list $vnf $verbose"
100 $OMCLIENT vnf-list $vnf $verbose
101 echo "-------------------------------"
102 done
103 echo "$OMCLIENT scenario-list $verbose"
104 $OMCLIENT scenario-list $verbose
105 echo "-------------------------------"
106 scenariolist=`$OMCLIENT scenario-list |awk '$1!="No" {print $1}'`
107 for sce in $scenariolist; do
108 echo "$OMCLIENT scenario-list $sce $verbose"
109 $OMCLIENT scenario-list $sce $verbose
110 echo "-------------------------------"
111 done
112 echo "$OMCLIENT instance-scenario-list $verbose"
113 $OMCLIENT instance-scenario-list $verbose
114 echo "-------------------------------"
115 instancelist=`$OMCLIENT instance-scenario-list |awk '$1!="No" {print $1}'`
116 for i in $instancelist; do
117 echo "$OMCLIENT instance-scenario-list $i $verbose"
118 $OMCLIENT instance-scenario-list $i $verbose
119 echo "-------------------------------"
120 done
121 echo
tierno7edb6752016-03-21 17:37:52 +0100122
123done
124echo