]> git.puffer.fish Git - mirror/frr.git/commitdiff
topogen: save zebra version output
authorRafael Zalamena <rzalamena@opensourcerouting.org>
Wed, 13 Sep 2017 15:07:35 +0000 (12:07 -0300)
committerDonald Sharp <sharpd@cumulusnetworks.com>
Wed, 28 Nov 2018 01:22:12 +0000 (20:22 -0500)
Keep the zebra version output for later problem diagnostics.

tests/topotests/lib/topogen.py

index e39803420b32dedf15e697e451fcb47914867bd4..eda4e3128bb36028ee20d36b0a12f9aaf7d661a1 100644 (file)
@@ -955,6 +955,13 @@ def diagnose_env():
 
                 logger.warning('could not find {} in {}'.format(fname, frrdir))
                 ret = False
+            else:
+                if fname != 'zebra':
+                    continue
+
+                os.system(
+                    '{} -v 2>&1 >/tmp/topotests/frr_zebra.txt'.format(path)
+                )
 
     # Assert that Quagga utilities exist
     quaggadir = config.get('topogen', 'quaggadir')
@@ -987,6 +994,13 @@ def diagnose_env():
             if not os.path.isfile(path):
                 logger.warning('could not find {} in {}'.format(fname, quaggadir))
                 ret = False
+            else:
+                if fname != 'zebra':
+                    continue
+
+                os.system(
+                    '{} -v 2>&1 >/tmp/topotests/quagga_zebra.txt'.format(path)
+                )
 
     if not os.path.isdir('/tmp'):
         logger.warning('could not find /tmp for logs')