Example #1
0
 def _telnet_connect(self):
     s.msg_out(self.message_output,
               '0. Telnet Connecting to %s ...\n' % self._host)
     self._TN_Conn = conn.HAAPConn(self._host, self._TNport, self._password,
                                   self._timeout)
     self._TN_Connect_Status = self._TN_Conn.get_connection_status()
     if self._TN_Connect_Status:
         s.msg_out(self.message_output,
                   '0. Telnet Connected to %s.\n' % self._host)
         s.chg_light_to_green(self.obj_light_telnet,
                              self.instance_light_telnet)
     else:
         s.msg_out(self.message_output,
                   '0. Telnet Connect to %s Failed!!!\n' % self._host)
Example #2
0
 def _ftp(self):
     s.msg_out(self.message_output,
               '0. FTP Connecting to %s ...\n' % self._host)
     if self._FTP_Conn:
         connFTP = self._FTP_Conn
     else:
         self._FTP_connect()
         connFTP = self._FTP_Conn
     if connFTP:
         s.msg_out(self.message_output,
                   '0. FTP Connected to %s.\n' % self._host)
         s.chg_light_to_green(self.obj_light_FTP, self.instance_light_FTP)
     else:
         s.msg_out(self.message_output,
                   '0. FTP Connect to %s Failed!!!\n' % self._host)
     return connFTP