I am using pysftp for remote execution, and the thing is that I don't want to wait for the output of the remote execution, I just want to start the execution and be done with it.
import pysftp as sftp
cnopts = sftp.CnOpts()
cnopts.hostkeys = None
handle = sftp.Connection('10.0.2.10',username='kali', password='root', cnopts=cnopts)
handle.execute('/tmp/doThis')
handle.exeute('/tmp/doThat')
Now the thing is that the script is waiting for doThis to get over and then it start with doThat. I tried using '&', but it has no affect. Is there someway of doing this, or is it not possible?
Why don't you try the threading concept?