import paramiko import sys import warnings warnings.filterwarnings("ignore", category=ResourceWarning) command = 'python3 /home/realsense/test/list_users.py' ssh = paramiko.SSHClient() ssh.set_missing_host_key_policy(paramiko.AutoAddPolicy()) ssh.connect('10.8.0.2', username='realsense', password='realsense') stdin, stdout, stderr = ssh.exec_command(command) stdin.close() print(stdout.read().decode()) ssh.close()