ffdc: Add code to handle OEM OSes
- Set 1: Initial code to handle OEM OSes.
- Set 2: Modify commit message.
- Set 3: Flag error when user input OS type is not described in config file.
Test:
- Set 1: Regressing tests to OpenBmc, RHEL, Ubuntu, AIX, OEM
Signed-off-by: Peter D Phan <peterp@us.ibm.com>
Change-Id: Id5410d21c7e4f8f5e74f1dded212b935075f7bea
diff --git a/ffdc/ssh_utility.py b/ffdc/ssh_utility.py
index 2110b74..44a76ff 100644
--- a/ffdc/ssh_utility.py
+++ b/ffdc/ssh_utility.py
@@ -70,7 +70,7 @@
if self.scpclient:
self.scpclient.close()
- def execute_command(self, command):
+ def execute_command(self, command, default_timeout=60):
"""
Execute command on the remote host.
@@ -80,7 +80,7 @@
"""
try:
- stdin, stdout, stderr = self.sshclient.exec_command(command)
+ stdin, stdout, stderr = self.sshclient.exec_command(command, timeout=default_timeout)
stdout.channel.recv_exit_status()
response = stdout.readlines()
return response