Commit 6e058cea authored by Tomas Hlavacek's avatar Tomas Hlavacek

Add timeout adjustment to Cisco pexpect handler.

parent b45d1f91
......@@ -803,7 +803,8 @@ class CiscoRouter(ulgmodel.RemoteRouter):
def runRawCommand(self,command,outfile):
# connect
p=pexpect.spawn(defaults.bin_ssh+' -p'+str(self.getPort())+' '+str(self.getUser())+'@'+self.getHost())
c=defaults.bin_ssh+' -p'+str(self.getPort())+' '+str(self.getUser())+'@'+self.getHost()
p=pexpect.spawn(c,timeout=defaults.timeout)
# handle ssh
i=p.expect([STRING_EXPECT_SSH_NEWKEY,STRING_EXPECT_PASSWORD,pexpect.EOF])
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment