From 4ac61b5a3b75195f534a1405b0697d2cdccfb797 Mon Sep 17 00:00:00 2001 From: Frederik Kriewitz Date: Wed, 4 Jun 2014 14:02:42 +0000 Subject: [PATCH 3/3] BIRD: Fix timeout in case ip/subnet is not in the routing table Fixes exceptions like this: ERROR: Exception occured while running a command:Traceback (most recent call last): File "/var/www/html/ulg.py", line 498, in commandThreadBody session.getRouter().runAsyncCommand(session.getCommand(),session.getParameters(),FakeSessionFile(session)) File "/var/www/html/ulgmodel.py", line 463, in runAsyncCommand return self.runRawCommand(c,outfile) File "/var/www/html/ulgbird.py", line 544, in runRawCommand l = sf.readline() File "/usr/lib/python2.7/socket.py", line 447, in readline data = self._sock.recv(self._rbufsize) timeout: timed out --- ulgbird.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/ulgbird.py b/ulgbird.py index a1096fe..44c2f80 100644 --- a/ulgbird.py +++ b/ulgbird.py @@ -517,6 +517,9 @@ class BirdRouterLocal(ulgmodel.LocalRouter,BirdRouter): elif(code == 13): # show status last line return True + elif(code == 8001): + # network not in table end + return True elif(code >= 9000): # probably error return True -- 1.9.1